Skip to content

Commit

Permalink
Merge pull request #10 from Roblox/update_attributes_golang
Browse files Browse the repository at this point in the history
update golang version & attributes
  • Loading branch information
shivdudhani authored Feb 4, 2021
2 parents 850e6d3 + c26803f commit 85f886a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
12 changes: 6 additions & 6 deletions libraries/vault_installation_git.rb
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,14 @@ def self.default_inversion_options(node, new_resource)
super.merge(
version: new_resource.version,
git_url: 'https://github.com/hashicorp/vault',
git_path: "#{node['go']['gopath']}/src/github.com/hashicorp/vault"
git_path: "#{node['golang']['gopath']}/src/github.com/hashicorp/vault"
)
end

def action_create
notifying_block do
# Require Go 1.6.1 as Vault depends on new functionality in net/http
node.default['go']['version'] = '1.6.1'
node.default['golang']['version'] = '1.6.1'
include_recipe 'golang::default', 'build-essential::default'
# Install required go packages for building Vault
golang_package 'github.com/mitchellh/gox'
Expand All @@ -63,15 +63,15 @@ def action_create
if new_resource.version < '0.6.0'
execute('godep restore') do
cwd options[:git_path]
environment(PATH: "#{node['go']['install_dir']}/go/bin:#{node['go']['gobin']}:/usr/bin:/bin",
GOPATH: node['go']['gopath'])
environment(PATH: "#{node['golang']['install_dir']}/go/bin:#{node['golang']['gobin']}:/usr/bin:/bin",
GOPATH: node['golang']['gopath'])
end
end

execute 'make dev' do
cwd options[:git_path]
environment(PATH: "#{node['go']['install_dir']}/go/bin:#{node['go']['gobin']}:/usr/bin:/bin",
GOPATH: node['go']['gopath'])
environment(PATH: "#{node['golang']['install_dir']}/go/bin:#{node['golang']['gobin']}:/usr/bin:/bin",
GOPATH: node['golang']['gopath'])
end
end
end
Expand Down
2 changes: 1 addition & 1 deletion metadata.rb
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
supports 'freebsd'

depends 'build-essential'
depends 'golang', '>= 0.0.0'
depends 'golang', '~> 4.1.0'
depends 'poise', '~> 2.6'
depends 'poise-service', '~> 1.1'
depends 'rubyzip', '~> 1.0'

0 comments on commit 85f886a

Please sign in to comment.