shiplane_bootstrappers_chef 0.1.18 → 0.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 1451a74466fca827914195ec0d3cc14ae82beeceb548bd4e1d99c2092c035446
|
|
4
|
+
data.tar.gz: d81665d8edd1ddd696c2991776a53a3b89abf0ba55b2571dbba5148d6f61c711
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: d7da41d8aa8cc3c65fdb5b9f7b79420b4a6bcca1e17466719e090acc8810881e64c6ab0296f4b56d07b5b7d5bb84cfa4390f24cae0ac119109b09e178fb83047
|
|
7
|
+
data.tar.gz: 65dd0b85a3db69e5ee288b7695bd0275579c04df3384c7daacc505be0a700b7caa4f4253116005a453846cceb5ea0fc82d8d9b1cdf303485711ed91ef1f2bafa
|
data/cookbooks.tar.gz
CHANGED
|
Binary file
|
data/lib/capistrano/chef_host.rb
CHANGED
|
@@ -28,6 +28,8 @@ module Shiplane
|
|
|
28
28
|
end
|
|
29
29
|
|
|
30
30
|
unless install_finished
|
|
31
|
+
execute :sudo, :sysctl, "-w", "net.ipv6.conf.all.disable_ipv6=1", interaction_handler: context_variables[:interaction_handler]
|
|
32
|
+
execute :sudo, :sysctl, "-w", "net.ipv6.conf.default.disable_ipv6=1", interaction_handler: context_variables[:interaction_handler]
|
|
31
33
|
execute :sudo, :mkdir, '-m', '2777', '-p', Shiplane::ChefHost::REMOTE_CHEF_FOLDER_PATH, interaction_handler: context_variables[:interaction_handler]
|
|
32
34
|
execute :sudo, :touch, File.join(Shiplane::ChefHost::REMOTE_CHEF_FOLDER_PATH, '.install-started'), interaction_handler: context_variables[:interaction_handler]
|
|
33
35
|
execute :sudo, 'apt-get', 'update', interaction_handler: context_variables[:interaction_handler]
|
|
@@ -36,6 +38,20 @@ module Shiplane
|
|
|
36
38
|
execute :sudo, :dpkg, '-i', Shiplane::ChefHost::CHEF_PACKAGE_NAME, interaction_handler: context_variables[:interaction_handler]
|
|
37
39
|
execute :sudo, :ls, '-al', Shiplane::ChefHost::REMOTE_CHEF_FOLDER_PATH, interaction_handler: context_variables[:interaction_handler]
|
|
38
40
|
execute :sudo, :touch, File.join(Shiplane::ChefHost::REMOTE_CHEF_FOLDER_PATH, '.install'), interaction_handler: context_variables[:interaction_handler]
|
|
41
|
+
execute :sudo, :sysctl, "-w", "net.ipv6.conf.all.disable_ipv6=0", interaction_handler: context_variables[:interaction_handler]
|
|
42
|
+
execute :sudo, :sysctl, "-w", "net.ipv6.conf.default.disable_ipv6=0", interaction_handler: context_variables[:interaction_handler]
|
|
43
|
+
end
|
|
44
|
+
end
|
|
45
|
+
end
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
def reinstall
|
|
49
|
+
with_context do
|
|
50
|
+
SSHKit::Coordinator.new(host).each in: :parallel do
|
|
51
|
+
context_variables = fetch(:shiplane_sshkit_values)
|
|
52
|
+
|
|
53
|
+
if(test("[ -f #{File.join(Shiplane::ChefHost::REMOTE_CHEF_FOLDER_PATH, '.install')} ]"))
|
|
54
|
+
execute :sudo, :rm, File.join(Shiplane::ChefHost::REMOTE_CHEF_FOLDER_PATH, '.install'), interaction_handler: context_variables[:interaction_handler]
|
|
39
55
|
end
|
|
40
56
|
end
|
|
41
57
|
end
|
|
@@ -48,7 +64,7 @@ module Shiplane
|
|
|
48
64
|
context_variables = fetch(:shiplane_sshkit_values)
|
|
49
65
|
|
|
50
66
|
begin
|
|
51
|
-
execute :sudo, 'chef-solo', '-c', "#{Shiplane::ChefHost::REMOTE_CHEF_FOLDER_PATH}/solo.rb", interaction_handler: context_variables[:interaction_handler]
|
|
67
|
+
execute :sudo, 'chef-solo', '-c', "#{Shiplane::ChefHost::REMOTE_CHEF_FOLDER_PATH}/solo.rb", "--chef-license", "accept", interaction_handler: context_variables[:interaction_handler]
|
|
52
68
|
rescue => e
|
|
53
69
|
errors["#{h}"] = Shiplane::ChefErrorParser.parse(e)
|
|
54
70
|
end
|
|
@@ -3,14 +3,16 @@ namespace :shiplane do
|
|
|
3
3
|
task :bootstrap, [:role] => ['bootstrap:default']
|
|
4
4
|
|
|
5
5
|
namespace :bootstrap do
|
|
6
|
-
task :
|
|
6
|
+
task :setup, [:role] do |task, args|
|
|
7
7
|
filter = args.fetch('role', 'all')
|
|
8
8
|
hosts = roles(filter).map do |host|
|
|
9
9
|
Shiplane::ChefHost.new(host, env)
|
|
10
10
|
end
|
|
11
11
|
|
|
12
12
|
set :shiplane_hosts, hosts
|
|
13
|
+
end
|
|
13
14
|
|
|
15
|
+
task :default, [:role] => :setup do |task, args|
|
|
14
16
|
%w{ prepare install configure cleanup }.each do |task|
|
|
15
17
|
invoke "shiplane:bootstrap:#{task}"
|
|
16
18
|
end
|
|
@@ -22,6 +24,12 @@ namespace :shiplane do
|
|
|
22
24
|
task :install do
|
|
23
25
|
end
|
|
24
26
|
|
|
27
|
+
task reinstall: :setup do
|
|
28
|
+
%w{ prepare reinstall install configure cleanup }.each do |task|
|
|
29
|
+
invoke "shiplane:bootstrap:#{task}"
|
|
30
|
+
end
|
|
31
|
+
end
|
|
32
|
+
|
|
25
33
|
task :configure do
|
|
26
34
|
end
|
|
27
35
|
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: shiplane_bootstrappers_chef
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.2.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- John Epperson
|
|
8
|
-
autorequire:
|
|
8
|
+
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2021-
|
|
11
|
+
date: 2021-04-18 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: capistrano
|
|
@@ -142,7 +142,7 @@ homepage: https://github.com/kirillian/shiplane
|
|
|
142
142
|
licenses:
|
|
143
143
|
- MIT
|
|
144
144
|
metadata: {}
|
|
145
|
-
post_install_message:
|
|
145
|
+
post_install_message:
|
|
146
146
|
rdoc_options: []
|
|
147
147
|
require_paths:
|
|
148
148
|
- lib
|
|
@@ -158,7 +158,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
158
158
|
version: '0'
|
|
159
159
|
requirements: []
|
|
160
160
|
rubygems_version: 3.0.3
|
|
161
|
-
signing_key:
|
|
161
|
+
signing_key:
|
|
162
162
|
specification_version: 4
|
|
163
163
|
summary: A toolbox for converting developer docker-compose files into production-ready
|
|
164
164
|
images.
|