cem_acpt 0.9.0 → 0.9.2
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 95508415e2d43c47c4bbd08963e688133e693c395ed646c8d9d6e62f3cab04af
|
4
|
+
data.tar.gz: 9b4618f3f1a544e35f00b88ff28efd755637db91d7e042c1e526e5720e6ecec2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9ea28e2bb50d55cc24b96235360498cd0b76104bf48586bb9432e2d3b4e614b5d5e7a516b5587a77ff514629db897cc988e4cf4a084eb56d314b54a24d954661
|
7
|
+
data.tar.gz: e95003005da232f68c058ca492e30bf4eb5f4539772494e6e733da2ecad26e740b1d560bc46ef3dc3916ffbd9449a2b0e02636d5d9554613ee7cee6c317820e7
|
data/Gemfile.lock
CHANGED
@@ -74,6 +74,48 @@ module CemAcpt
|
|
74
74
|
alias to_a provision_commands
|
75
75
|
end
|
76
76
|
|
77
|
+
class DebianFamily
|
78
|
+
def initialize(config, image_name, base_image, os_major_version, puppet_version)
|
79
|
+
@config = config
|
80
|
+
@image_name = image_name
|
81
|
+
@base_image = base_image
|
82
|
+
@os_major_version = os_major_version
|
83
|
+
@puppet_version = puppet_version
|
84
|
+
end
|
85
|
+
|
86
|
+
def default_provision_commands
|
87
|
+
[install_curl_command, enable_puppet_repository_command, upgrade_packages_command, install_puppet_agent_command]
|
88
|
+
end
|
89
|
+
|
90
|
+
def provision_commands
|
91
|
+
commands_from_config = @config.get("images.#{@image_name}.provision_commands") || []
|
92
|
+
(default_provision_commands + commands_from_config).compact
|
93
|
+
end
|
94
|
+
alias to_a provision_commands
|
95
|
+
|
96
|
+
private
|
97
|
+
|
98
|
+
def upgrade_packages_command
|
99
|
+
'sudo apt-get update && sudo apt-get upgrade -y'
|
100
|
+
end
|
101
|
+
|
102
|
+
def puppet_platform_repository_url
|
103
|
+
"https://apt.puppet.com/puppet#{@puppet_version}-release-focal.deb"
|
104
|
+
end
|
105
|
+
|
106
|
+
def enable_puppet_repository_command
|
107
|
+
"wget #{puppet_platform_repository_url} && sudo dpkg -i puppet#{@puppet_version}-release-focal.deb"
|
108
|
+
end
|
109
|
+
|
110
|
+
def install_puppet_agent_command
|
111
|
+
'sudo apt-get install -y puppet-agent'
|
112
|
+
end
|
113
|
+
|
114
|
+
# The latest Google-provided Ubuntu images do not have curl installed by default
|
115
|
+
def install_curl_command
|
116
|
+
'sudo apt-get install -y curl'
|
117
|
+
end
|
118
|
+
end
|
77
119
|
class << self
|
78
120
|
# Map of OS to class that holds the provision commands for that OS
|
79
121
|
OS_CLASS_MAP = {
|
@@ -82,6 +124,7 @@ module CemAcpt
|
|
82
124
|
'alma' => 'EnterpriseLinuxFamily',
|
83
125
|
'oel' => 'EnterpriseLinuxFamily',
|
84
126
|
'rocky' => 'EnterpriseLinuxFamily',
|
127
|
+
'ubuntu' => 'DebianFamily',
|
85
128
|
'windows' => 'WindowsFamily',
|
86
129
|
}.freeze
|
87
130
|
|
@@ -7,11 +7,11 @@ module CemAcpt
|
|
7
7
|
# Class provides methods for gathering provision data for Linux nodes
|
8
8
|
class Linux < OsData
|
9
9
|
def self.valid_names
|
10
|
-
%w[centos rhel oel alma rocky]
|
10
|
+
%w[centos rhel oel alma rocky ubuntu]
|
11
11
|
end
|
12
12
|
|
13
13
|
def self.valid_versions
|
14
|
-
%w[7 8 9]
|
14
|
+
%w[7 8 9 2004]
|
15
15
|
end
|
16
16
|
|
17
17
|
def systemd_files
|
data/lib/cem_acpt/test_runner.rb
CHANGED
@@ -197,7 +197,7 @@ module CemAcpt
|
|
197
197
|
@bolt_test_runner.setup!
|
198
198
|
return unless @bolt_test_runner.tests.to_a.empty?
|
199
199
|
|
200
|
-
if !
|
200
|
+
if !CemAcpt::Actions.config.only.empty? && CemAcpt::Actions.config.only.include?('bolt')
|
201
201
|
raise 'No Bolt tests to run and only bolt action was specified'
|
202
202
|
end
|
203
203
|
|
data/lib/cem_acpt/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cem_acpt
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- puppetlabs
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-03-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: async-http
|