cloud-mu 2.0.0.pre.alpha9 → 2.0.0.pre.beta1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Berksfile.lock +1 -1
- data/README.md +2 -0
- data/bin/mu-configure +2 -58
- data/bin/mu-gen-docs +29 -4
- data/bin/mu-load-config.rb +0 -1
- data/bin/mu-user-manage +4 -0
- data/cloud-mu.gemspec +2 -2
- data/cookbooks/mu-master/recipes/default.rb +3 -4
- data/cookbooks/mu-master/recipes/init.rb +3 -3
- data/cookbooks/mu-tools/files/default/Mu_CA.pem +15 -15
- data/cookbooks/mu-tools/libraries/helper.rb +1 -1
- data/cookbooks/mu-tools/recipes/eks.rb +3 -3
- data/cookbooks/mu-tools/recipes/set_local_fw.rb +1 -1
- data/cookbooks/mu-utility/recipes/remi.rb +1 -1
- data/cookbooks/nagios/libraries/base.rb +4 -4
- data/cookbooks/nagios/libraries/contact.rb +1 -1
- data/cookbooks/nagios/libraries/contactgroup.rb +1 -1
- data/cookbooks/nagios/libraries/host.rb +2 -2
- data/cookbooks/nagios/libraries/hostdependency.rb +3 -3
- data/cookbooks/nagios/libraries/hostescalation.rb +3 -3
- data/cookbooks/nagios/libraries/hostgroup.rb +2 -2
- data/cookbooks/nagios/libraries/nagios.rb +5 -5
- data/cookbooks/nagios/libraries/service.rb +3 -3
- data/cookbooks/nagios/libraries/servicedependency.rb +2 -2
- data/cookbooks/nagios/libraries/serviceescalation.rb +2 -2
- data/cookbooks/nagios/libraries/servicegroup.rb +2 -2
- data/cookbooks/nagios/libraries/timeperiod.rb +1 -1
- data/install/installer +1 -1
- data/modules/mu/cleanup.rb +1 -1
- data/modules/mu/cloud.rb +43 -1
- data/modules/mu/clouds/aws.rb +55 -35
- data/modules/mu/clouds/aws/bucket.rb +287 -0
- data/modules/mu/clouds/aws/database.rb +65 -11
- data/modules/mu/clouds/aws/endpoint.rb +592 -0
- data/modules/mu/clouds/aws/firewall_rule.rb +4 -0
- data/modules/mu/clouds/aws/function.rb +138 -93
- data/modules/mu/clouds/aws/nosqldb.rb +387 -0
- data/modules/mu/clouds/aws/role.rb +1 -1
- data/modules/mu/clouds/aws/server.rb +5 -5
- data/modules/mu/clouds/aws/server_pool.rb +60 -3
- data/modules/mu/clouds/azure.rb +0 -1
- data/modules/mu/clouds/google.rb +34 -12
- data/modules/mu/clouds/google/bucket.rb +179 -0
- data/modules/mu/config.rb +1 -1
- data/modules/mu/config/bucket.rb +69 -0
- data/modules/mu/config/bucket.yml +10 -0
- data/modules/mu/config/database.rb +1 -1
- data/modules/mu/config/endpoint.rb +71 -0
- data/modules/mu/config/function.rb +6 -0
- data/modules/mu/config/nosqldb.rb +49 -0
- data/modules/mu/config/nosqldb.yml +44 -0
- data/modules/mu/config/notifier.yml +2 -2
- data/modules/mu/config/vpc.rb +0 -1
- data/modules/mu/defaults/amazon_images.yaml +32 -30
- data/modules/mu/groomers/chef.rb +1 -1
- data/modules/mu/kittens.rb +2430 -1511
- data/modules/mu/master/ldap.rb +1 -1
- data/modules/tests/super_complex_bok.yml +7 -0
- data/modules/tests/super_simple_bok.yml +7 -0
- metadata +11 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 27ff913665cbcb6838ce2e1b2b521307b1cc5061daf2ac576a240aca3eb29b19
|
4
|
+
data.tar.gz: 8ab03cef1d7c16b43f9c609b7789801b5e27ac4cc48ae3f53e603d530bbe7016
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3df2ed93f9f72ed6afae31023d0e06123705628b46f25e59cf9a7958ed398deb014470ecc9a0947b109b3b5c112fed2bdd1932568e488751cede8703ff0f8408
|
7
|
+
data.tar.gz: b075b39cc903276cee6e27d2d3969072d743a96f39e9bd77b3130e91cc19f822de5399e8b164dc84ebeebc47a87b67586bc2c4de92cc18d99d2b0aa5a6af1c56
|
data/Berksfile.lock
CHANGED
data/README.md
CHANGED
@@ -1,7 +1,9 @@
|
|
1
1
|
mu -- Cloudamatic Automation Tooling
|
2
2
|
===
|
3
3
|
[![pipeline status](https://gitlab.com/cloudamatic/mu/badges/master/pipeline.svg)](https://gitlab.com/cloudamatic/mu/commits/master)
|
4
|
+
[![Gem Version](https://badge.fury.io/rb/cloud-mu.svg)](https://badge.fury.io/rb/cloud-mu)
|
4
5
|
[![Maintainability](https://api.codeclimate.com/v1/badges/dd4e5d867890336accd1/maintainability)](https://codeclimate.com/github/cloudamatic/mu/maintainability)
|
6
|
+
[![Inline docs](http://inch-ci.org/github/cloudamatic/mu.svg?branch=master)](http://inch-ci.org/github/cloudamatic/mu)
|
5
7
|
[![coverage report](https://gitlab.com/cloudamatic/mu/badges/master/coverage.svg)](https://gitlab.com/cloudamatic/mu/commits/master)
|
6
8
|
|
7
9
|
# About mu
|
data/bin/mu-configure
CHANGED
@@ -105,31 +105,6 @@ $CONFIGURABLES = {
|
|
105
105
|
"desc" => "If set to true, Mu will be allowed to modify routing and peering behavior of VPCs which it did not create, but for which it has permissions.",
|
106
106
|
"boolean" => true
|
107
107
|
},
|
108
|
-
"jenkins" => {
|
109
|
-
"title" => "Jenkins Continuous Integration",
|
110
|
-
"rootonly" => true,
|
111
|
-
"subtree" => {
|
112
|
-
"enable" => {
|
113
|
-
"title" => "Enable Jenkins",
|
114
|
-
"desc" => "Enable Jenkins, with UI web-accessible at /jenkins.",
|
115
|
-
"default" => false,
|
116
|
-
"boolean" => true,
|
117
|
-
"changes" => ["chefrun"]
|
118
|
-
},
|
119
|
-
"admin_email" => {
|
120
|
-
"title" => "Jenkins Admin Email",
|
121
|
-
"desc" => "Administative contact email for Jenkins",
|
122
|
-
"pattern" => /\A([\w+\-].?)+@[a-z\d\-]+(\.[a-z]+)*\.[a-z]+\z/i,
|
123
|
-
"changes" => ["chefrun"]
|
124
|
-
},
|
125
|
-
"admin_user" => {
|
126
|
-
"title" => "Jenkins admin username",
|
127
|
-
"desc" => "The name of a Mu user who will serve as the Jenkins admin.",
|
128
|
-
"default" => "jenkins",
|
129
|
-
"changes" => ["chefrun"]
|
130
|
-
}
|
131
|
-
}
|
132
|
-
},
|
133
108
|
"aws" => {
|
134
109
|
"title" => "Amazon Web Services",
|
135
110
|
"named_subentries" => true,
|
@@ -589,9 +564,6 @@ def setDefaults
|
|
589
564
|
$CONFIGURABLES["public_address"]["default"] = ips.first
|
590
565
|
$CONFIGURABLES["hostname"]["default"] = Socket.gethostname
|
591
566
|
$CONFIGURABLES["banner"]["default"] = "Mu Master at #{$CONFIGURABLES["public_address"]["default"]}"
|
592
|
-
if $CONFIGURABLES["mu_admin_email"]["value"]
|
593
|
-
$CONFIGURABLES["jenkins"]["subtree"]["admin_email"]["default"] = $CONFIGURABLES["mu_admin_email"]["value"]
|
594
|
-
end
|
595
567
|
if $IN_AWS
|
596
568
|
# XXX move this crap to a callback hook for puttering around in the AWS submenu
|
597
569
|
aws = JSON.parse(open("http://169.254.169.254/latest/dynamic/instance-identity/document").read)
|
@@ -977,8 +949,6 @@ def menu(tree = $CONFIGURABLES, map = $MENU_MAP, submenu_name = nil, in_use_name
|
|
977
949
|
# $CONFIGURABLES["google"]["subtree"]["log_bucket_name"]["default"] = newval
|
978
950
|
elsif map[answer]['title'] == "Public Address"
|
979
951
|
$CONFIGURABLES["banner"]["default"] = "Mu Master at #{newval}"
|
980
|
-
elsif map[answer]['title'] == "Mu Admin Email"
|
981
|
-
$CONFIGURABLES["jenkins"]["subtree"]["admin_email"]["default"] = newval
|
982
952
|
end
|
983
953
|
changed = true
|
984
954
|
puts ""
|
@@ -1006,8 +976,8 @@ else
|
|
1006
976
|
end
|
1007
977
|
|
1008
978
|
if AMROOT
|
1009
|
-
require File.realpath(File.expand_path(File.dirname(__FILE__)+"/mu-load-config.rb"))
|
1010
979
|
newcfg = cloneHash($MU_CFG)
|
980
|
+
require File.realpath(File.expand_path(File.dirname(__FILE__)+"/mu-load-config.rb"))
|
1011
981
|
newcfg['multiuser'] = true
|
1012
982
|
saveMuConfig(newcfg)
|
1013
983
|
$MU_CFG = loadMuConfig($MU_SET_DEFAULTS)
|
@@ -1293,37 +1263,11 @@ if $MU_CFG['ldap']['type'] == "389 Directory Services"
|
|
1293
1263
|
end
|
1294
1264
|
end
|
1295
1265
|
|
1296
|
-
if $MU_CFG['jenkins'] and $MU_CFG['jenkins']['enable']
|
1297
|
-
MU::Groomer::Chef.loadChefLib
|
1298
|
-
chef_node = ::Chef::Node.load("MU-MASTER")
|
1299
|
-
begin
|
1300
|
-
data = MU::Groomer::Chef.getSecret(vault: "jenkins", item: "admin")
|
1301
|
-
MU::Groomer::Chef.grantSecretAccess("MU-MASTER", "jenkins", "admin")
|
1302
|
-
rescue MU::Groomer::Chef::MuNoSuchSecret
|
1303
|
-
MU.log "Saving keys for Jenkins admin user '#{$MU_CFG['jenkins']['admin_user']}' into Vault jenkins:admin", MU::NOTICE
|
1304
|
-
if !File.exists?("#{HOMEDIR}/.ssh/mu-jenkins-admin.pub") and !File.exists?("#{HOMEDIR}/.ssh/mu-jenkins-admin.pub")
|
1305
|
-
system("/usr/bin/ssh-keygen -N '' -f #{HOMEDIR}/.ssh/mu-jenkins-admin")
|
1306
|
-
end
|
1307
|
-
public_key = File.read("#{HOMEDIR}/.ssh/mu-jenkins-admin.pub").chomp
|
1308
|
-
private_key = File.read("#{HOMEDIR}/.ssh/mu-jenkins-admin").chomp
|
1309
|
-
MU::Groomer::Chef.saveSecret(
|
1310
|
-
vault: "jenkins",
|
1311
|
-
item: "admin",
|
1312
|
-
data: {
|
1313
|
-
"username": $MU_CFG['jenkins']['admin_user'],
|
1314
|
-
"private_key": private_key,
|
1315
|
-
"public_key": public_key
|
1316
|
-
}
|
1317
|
-
)
|
1318
|
-
end
|
1319
|
-
end
|
1320
|
-
|
1321
1266
|
# Figure out if our run list is dumb
|
1322
1267
|
MU.log "Verifying MU-MASTER's Chef run list", MU::NOTICE
|
1323
1268
|
MU::Groomer::Chef.loadChefLib
|
1324
1269
|
chef_node = ::Chef::Node.load("MU-MASTER")
|
1325
1270
|
run_list = ["role[mu-master]"]
|
1326
|
-
run_list << "role[mu-master-jenkins]" if $MU_CFG['jenkins'] and $MU_CFG['jenkins']['enable']
|
1327
1271
|
run_list.concat($MU_CFG['master_runlist_extras']) if $MU_CFG['master_runlist_extras'].is_a?(Array)
|
1328
1272
|
set_runlist = false
|
1329
1273
|
run_list.each { |rl|
|
@@ -1382,7 +1326,7 @@ MU.log "Regenerating documentation in /var/www/html/docs"
|
|
1382
1326
|
|
1383
1327
|
if $INITIALIZE
|
1384
1328
|
MU.log "Setting initial password for admin user 'mu', for logging into Nagios and other built-in services.", MU::NOTICE
|
1385
|
-
puts %x{#{MU_BASE}/lib/bin/mu-user-manage -g mu}
|
1329
|
+
puts %x{#{MU_BASE}/lib/bin/mu-user-manage -g mu -n "#{$MU_CFG['mu_admin_name']}"}
|
1386
1330
|
MU.log "If Scratchpad web interface is not accessible, try the following:", MU::NOTICE
|
1387
1331
|
puts "#{MU_BASE}/lib/bin/mu-user-manage -g --no-scratchpad mu".bold
|
1388
1332
|
end
|
data/bin/mu-gen-docs
CHANGED
@@ -26,11 +26,36 @@ require 'optimist'
|
|
26
26
|
require 'json-schema'
|
27
27
|
require File.realpath(File.expand_path(File.dirname(__FILE__)+"/mu-load-config.rb"))
|
28
28
|
require 'mu'
|
29
|
-
require 'yard'
|
30
29
|
|
31
|
-
|
30
|
+
ENV['PATH'] += ":"+File.dirname(Gem.ruby)
|
31
|
+
|
32
|
+
begin
|
33
|
+
MU.log "Looking up the system YARD"
|
34
|
+
yard = `which yard 2>&1`.chomp
|
35
|
+
|
36
|
+
if yard.include? "no yard in"
|
37
|
+
MU.log "No system YARD found. Trying YARD gem"
|
38
|
+
yard = File.dirname(Gem.ruby)+'/yard'
|
39
|
+
end
|
40
|
+
|
41
|
+
rescue
|
42
|
+
MU.log "Using the YARD gem"
|
43
|
+
yard = File.dirname(Gem.ruby)+'/yard'
|
44
|
+
end
|
45
|
+
|
46
|
+
|
32
47
|
|
33
48
|
MU::Config.emitSchemaAsRuby
|
34
49
|
MU.log "Generating YARD documentation in /var/www/html/docs (see http://#{$MU_CFG['public_address']}/docs/frames.html)"
|
35
|
-
|
36
|
-
|
50
|
+
|
51
|
+
File.umask 0022
|
52
|
+
|
53
|
+
Dir.chdir(MU.myRoot) do
|
54
|
+
#exec "env -i PATH=#{ENV['PATH']} HOME=#{ENV['HOME']} #{yard} doc modules -m markdown -o /var/www/html/docs" THIS DOESNT WORK IN CICD
|
55
|
+
|
56
|
+
system(%Q{#{yard} doc modules -m markdown -o /var/www/html/docs})
|
57
|
+
|
58
|
+
system(%Q{chcon -R -h -t httpd_sys_script_exec_t /var/www/html/})
|
59
|
+
|
60
|
+
system(%Q{#{yard} stats --list-undoc modules})
|
61
|
+
end
|
data/bin/mu-load-config.rb
CHANGED
@@ -75,7 +75,6 @@ def loadMuConfig(default_cfg_overrides = nil)
|
|
75
75
|
"chain" => "/opt/mu/var/ssl/Mu_CA.pem"
|
76
76
|
},
|
77
77
|
"mu_admin_email" => "root@localhost",
|
78
|
-
"jenkins_admin_email" => "root@localhost",
|
79
78
|
"allow_invade_foreign_vpcs" => false,
|
80
79
|
"mu_repo" => "cloudamatic/mu.git",
|
81
80
|
"public_address" => Socket.gethostname || "localhost",
|
data/bin/mu-user-manage
CHANGED
@@ -245,6 +245,10 @@ else
|
|
245
245
|
exit 1 if bail
|
246
246
|
end
|
247
247
|
|
248
|
+
if !$cur_users[$username]['realname'] or $cur_users[$username]['realname'].empty?
|
249
|
+
$cur_users[$username]['realname'] = $username
|
250
|
+
end
|
251
|
+
|
248
252
|
if !MU::Master.manageUser(
|
249
253
|
$username,
|
250
254
|
chef_username: $cur_users[$username]['chef_user'],
|
data/cloud-mu.gemspec
CHANGED
@@ -17,8 +17,8 @@ end
|
|
17
17
|
|
18
18
|
Gem::Specification.new do |s|
|
19
19
|
s.name = 'cloud-mu'
|
20
|
-
s.version = '2.0.0-
|
21
|
-
s.date = '2019-02-
|
20
|
+
s.version = '2.0.0-beta1'
|
21
|
+
s.date = '2019-02-18'
|
22
22
|
s.require_paths = ['modules']
|
23
23
|
s.required_ruby_version = '>= 2.4'
|
24
24
|
s.summary = "The eGTLabs Mu toolkit for unified cloud deployments"
|
@@ -239,6 +239,7 @@ if !node['update_nagios_only']
|
|
239
239
|
node.normal['postfix']['main']['inet_interfaces'] = "all"
|
240
240
|
node.save
|
241
241
|
|
242
|
+
mubranch=`cd #{MU_BASE}/lib && git rev-parse --abbrev-ref HEAD` # ~FC048
|
242
243
|
|
243
244
|
file "/var/www/html/index.html" do
|
244
245
|
owner "apache"
|
@@ -254,7 +255,7 @@ if !node['update_nagios_only']
|
|
254
255
|
<a href='https://#{MU.mu_public_addr}/jenkins/'>Jenkins interface GUI</a>
|
255
256
|
</p>
|
256
257
|
<p>
|
257
|
-
<a href='http
|
258
|
+
<a href='#{(mubranch.nil? or mubranch == "master" or mubranch.match(/detached from/)) ? "https://cloudamatic.gitlab.io/mu/" : "http://"+MU.mu_public_addr+"/docs"}'>Mu API documentation</a>
|
258
259
|
</p>
|
259
260
|
"
|
260
261
|
end
|
@@ -430,9 +431,7 @@ if !node['update_nagios_only']
|
|
430
431
|
|
431
432
|
Nagios monitoring GUI: https://#{MU.mu_public_addr}/nagios/
|
432
433
|
|
433
|
-
|
434
|
-
|
435
|
-
Mu API documentation: http://#{MU.mu_public_addr}/docs/frames.html
|
434
|
+
Mu API documentation: #{(mubranch.nil? or mubranch == "master" or mubranch.match(/detached from/)) ? "https://cloudamatic.gitlab.io/mu/" : "http://"+MU.mu_public_addr+"/docs"}
|
436
435
|
|
437
436
|
Mu metadata are stored in #{MU.mainDataDir}
|
438
437
|
|
@@ -39,7 +39,7 @@ CHEF_SERVER_VERSION="12.17.15-1"
|
|
39
39
|
CHEF_CLIENT_VERSION="14.4.56"
|
40
40
|
KNIFE_WINDOWS="1.9.0"
|
41
41
|
MU_BASE="/opt/mu"
|
42
|
-
MU_BRANCH="
|
42
|
+
MU_BRANCH="master" # GIT HOOK EDITABLE DO NOT TOUCH
|
43
43
|
realbranch=`cd #{MU_BASE}/lib && git rev-parse --abbrev-ref HEAD` # ~FC048
|
44
44
|
|
45
45
|
if ENV.key?('MU_BRANCH')
|
@@ -174,7 +174,7 @@ if platform_family?("rhel")
|
|
174
174
|
|
175
175
|
|
176
176
|
if elversion < 6 or elversion >= 8
|
177
|
-
raise "Mu Masters on RHEL-family hosts must be equivalent to RHEL6 or RHEL7 (got #{elversion
|
177
|
+
raise "Mu Masters on RHEL-family hosts must be equivalent to RHEL6 or RHEL7 (got #{elversion})"
|
178
178
|
|
179
179
|
# RHEL6, CentOS6, Amazon Linux
|
180
180
|
elsif elversion < 7
|
@@ -185,7 +185,7 @@ if platform_family?("rhel")
|
|
185
185
|
|
186
186
|
# RHEL7, CentOS7
|
187
187
|
elsif elversion < 8
|
188
|
-
basepackages.concat(["libX11", "tcl", "tk", "mariadb-devel"])
|
188
|
+
basepackages.concat(["libX11", "tcl", "tk", "mariadb-devel", "cryptsetup"])
|
189
189
|
rpms["ruby25"] = "https://s3.amazonaws.com/cloudamatic/muby-2.5.3-1.el7.x86_64.rpm"
|
190
190
|
removepackages = ["nagios", "firewalld"]
|
191
191
|
end
|
@@ -1,8 +1,8 @@
|
|
1
1
|
-----BEGIN CERTIFICATE-----
|
2
|
-
|
2
|
+
MIIF2zCCA8OgAwIBAgIJAOx2Krw2HGFkMA0GCSqGSIb3DQEBDQUAMF0xFjAUBgNV
|
3
3
|
BAMMDTU0LjE3NS44Ni4xOTQxIDAeBgNVBAsMF011IFNlcnZlciA1NC4xNzUuODYu
|
4
|
-
|
5
|
-
|
4
|
+
MTk0MRQwEgYDVQQKDAtlR2xvYmFsVGVjaDELMAkGA1UEBhMCVVMwHhcNMTkwMjI3
|
5
|
+
MTQ0ODA2WhcNMjExMjE3MTQ0ODA2WjBdMRYwFAYDVQQDDA01NC4xNzUuODYuMTk0
|
6
6
|
MSAwHgYDVQQLDBdNdSBTZXJ2ZXIgNTQuMTc1Ljg2LjE5NDEUMBIGA1UECgwLZUds
|
7
7
|
b2JhbFRlY2gxCzAJBgNVBAYTAlVTMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIIC
|
8
8
|
CgKCAgEAo7rntOFj/WPNvh00SN55aJBusppsY9arq7QF5gt/9+cBPsjcXn7jJMu0
|
@@ -19,16 +19,16 @@ e4Q3VnxhRfmkS1NqEzIvPabVLg9qvN419cubpE6HAtBJw/f3ocUCAwEAAaOBnTCB
|
|
19
19
|
mjBKBgNVHREEQzBBhwQ2r1bCgglsb2NhbGhvc3SHBH8AAAGCGXN0YW5nZS1tdS1k
|
20
20
|
ZXYucGxhdGZvcm0tbXWCDXN0YW5nZS1tdS1kZXYwHQYDVR0OBBYEFK/EmtGebCwd
|
21
21
|
5QpM8y/3EKdYNVbcMB8GA1UdIwQYMBaAFK/EmtGebCwd5QpM8y/3EKdYNVbcMAwG
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
22
|
+
A1UdEwQFMAMBAf8wDQYJKoZIhvcNAQENBQADggIBACrhE0wT4DBanIUiWNU74e5k
|
23
|
+
tH4DC2vOfdPuF7AOFpDDmvR7HHoztWMyV7+KjrsQy/khAWNDq+JJ9Ya1E7mo9Jhy
|
24
|
+
w3Ty9xM1FfA39D1dXoGFhfG++HbQSqVXvVWmwa4M/9VmL5YgqCkeEiRf8WQ7TpjT
|
25
|
+
ldQUovcIICRAkeZG/lqjHJ/jAADIepCbsOeP0Gs2T0jdLmN2jKkcwFZkqpEi8PQB
|
26
|
+
wyhtJvUyU/B7xVBI5etrqmwxApg5RmkmnnsBXAxtSnJP1SvLv0o1IQZfOKzR9Ivn
|
27
|
+
IAJaXAp9q2AecHMQhu6TMpNCgifLKcwsGBlmrL+6wgU6+AedWYl80iewzk2kYrEw
|
28
|
+
MpIRETKBEOOsIo0jaNzdK/SyxdBtol7T9s6cwGXSr2n06Vtqvwc5d94gqgZyGBgg
|
29
|
+
GYnBVfVvRTxGP+2rHry1DRPLlr4/pwzo1XkCPb4QViaYL3jtuQUrj3a6EZZJnS4V
|
30
|
+
c9U7RFY8t9uGuIhHN8ZzeZyF0TaAwsMJtkvriRt2rK5BoBn5n6273QOey1YmqnfW
|
31
|
+
Xh919XQbuEha1XMG0xRD2RYURJjfSFV81humvQ2vSfZZqZplieXI98TOStRN6cmn
|
32
|
+
RE0Zx1kpQ5VVsukYCvQYZ1FzR2PmtOum4IrWQJRWdK8k7hrW+b9YzFDlcimf4Yiv
|
33
|
+
uaxTeq345Wu1zn+Pj9AI
|
34
34
|
-----END CERTIFICATE-----
|
@@ -242,7 +242,7 @@ module Mutools
|
|
242
242
|
http.verify_mode = OpenSSL::SSL::VERIFY_NONE # XXX this sucks
|
243
243
|
response = http.request(req)
|
244
244
|
if response.code != "200"
|
245
|
-
Chef::Log.error("Got #{response.code
|
245
|
+
Chef::Log.error("Got #{response.code} back from #{uri} on #{action} => #{arg}")
|
246
246
|
end
|
247
247
|
rescue EOFError => e
|
248
248
|
# Sometimes deployment metadata is incomplete and missing a
|
@@ -66,7 +66,7 @@ EOH
|
|
66
66
|
package "kubelet"
|
67
67
|
package "kubectl"
|
68
68
|
else
|
69
|
-
Chef::Log.info("I don't know how to turn this #{node['platform']} AMI (#{node['platform_version']
|
69
|
+
Chef::Log.info("I don't know how to turn this #{node['platform']} AMI (#{node['platform_version']}) into a Kubernetes worker, hopefully it's the official, pre-configured AMI")
|
70
70
|
end
|
71
71
|
|
72
72
|
service "docker" do
|
@@ -137,8 +137,8 @@ EOH
|
|
137
137
|
|
138
138
|
opento.uniq.each { |src|
|
139
139
|
[:tcp, :udp, :icmp].each { |proto|
|
140
|
-
execute "iptables -I INPUT -p #{proto
|
141
|
-
not_if "iptables -L -n | tr -s ' ' | grep -- '#{proto
|
140
|
+
execute "iptables -I INPUT -p #{proto} -s #{src}" do
|
141
|
+
not_if "iptables -L -n | tr -s ' ' | grep -- '#{proto} -- #{src.sub(/\/32$/, "")}' > /dev/null"
|
142
142
|
end
|
143
143
|
}
|
144
144
|
}
|
@@ -26,7 +26,7 @@ case node['platform']
|
|
26
26
|
|
27
27
|
remirepo=yum_repository "remi" do
|
28
28
|
description "Les RPM de Remi"
|
29
|
-
mirrorlist "http://rpms.famillecollet.com/enterprise/#{node['platform_version'].to_i
|
29
|
+
mirrorlist "http://rpms.famillecollet.com/enterprise/#{node['platform_version'].to_i}/remi/mirror"
|
30
30
|
enabled false
|
31
31
|
gpgkey "http://rpms.famillecollet.com/RPM-GPG-KEY-remi"
|
32
32
|
if node[['cap_global_compile_run']] then
|
@@ -127,7 +127,7 @@ class Nagios
|
|
127
127
|
check_use_and_name(Nagios.instance.default_timeperiod)
|
128
128
|
end
|
129
129
|
end
|
130
|
-
|
130
|
+
|
131
131
|
|
132
132
|
def get_commands(obj)
|
133
133
|
obj.map(&:to_s).join(',')
|
@@ -197,7 +197,7 @@ class Nagios
|
|
197
197
|
end
|
198
198
|
members
|
199
199
|
end
|
200
|
-
|
200
|
+
|
201
201
|
|
202
202
|
def get_timeperiod(obj)
|
203
203
|
return nil if obj.nil?
|
@@ -263,7 +263,7 @@ class Nagios
|
|
263
263
|
end
|
264
264
|
commands
|
265
265
|
end
|
266
|
-
|
266
|
+
|
267
267
|
|
268
268
|
def hostname(name)
|
269
269
|
if Nagios.instance.normalize_hostname
|
@@ -302,7 +302,7 @@ class Nagios
|
|
302
302
|
n.push(self) if remote
|
303
303
|
end
|
304
304
|
end
|
305
|
-
|
305
|
+
|
306
306
|
|
307
307
|
def update_dependency_members(hash, option, object)
|
308
308
|
return if blank?(hash) || hash[option].nil?
|
@@ -207,7 +207,7 @@ class Nagios
|
|
207
207
|
end
|
208
208
|
end
|
209
209
|
end
|
210
|
-
|
210
|
+
|
211
211
|
|
212
212
|
def self.create(name)
|
213
213
|
Nagios.instance.find(Nagios::Host.new(name))
|
@@ -399,7 +399,7 @@ class Nagios
|
|
399
399
|
'register' => 'register',
|
400
400
|
}
|
401
401
|
end
|
402
|
-
|
402
|
+
|
403
403
|
|
404
404
|
def merge_members(obj)
|
405
405
|
obj.parents.each { |m| push(m) }
|
@@ -126,7 +126,7 @@ class Nagios
|
|
126
126
|
end
|
127
127
|
end
|
128
128
|
end
|
129
|
-
|
129
|
+
|
130
130
|
|
131
131
|
def self.create(name)
|
132
132
|
Nagios.instance.find(Nagios::Hostdependency.new(name))
|
@@ -168,7 +168,7 @@ class Nagios
|
|
168
168
|
'notification_failure_criteria' => 'notification_failure_criteria',
|
169
169
|
}
|
170
170
|
end
|
171
|
-
|
171
|
+
|
172
172
|
|
173
173
|
def merge_members(obj)
|
174
174
|
obj.host_name.each { |m| push(m) }
|
@@ -178,4 +178,4 @@ class Nagios
|
|
178
178
|
end
|
179
179
|
end
|
180
180
|
end
|
181
|
-
|
181
|
+
|