kitchen-habitat 0.11.1 → 0.11.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +3 -0
- data/lib/kitchen-habitat/version.rb +1 -1
- data/lib/kitchen/provisioner/habitat.rb +10 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2f0dff2a5f968980869f7997e70646b270bb317dd75fb7728826f0a71be9d94b
|
4
|
+
data.tar.gz: 97695db2914a4b22dcc172323fa2d73679ac1e629d226868191f0889bf3f7642
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3f2aa27e5149b48e593eee823b9bc3743e463733f2a22dfd5781ee6bf98becb769dcf46aa00bc177e6ac4a119c8e120120f674cbe103ae0fb8bcb71159817a6a
|
7
|
+
data.tar.gz: e226dca41ef127b60d02430b571189c845d642a747fe207a6e9fbc83b78b2c4dc1213111a6924bb0595e7f69ab72b27ed013d39385322cf477c2d3b83e598931
|
data/README.md
CHANGED
@@ -11,6 +11,9 @@ You'll need the test-kitchen & kitchen-habitat gems installed in your system, al
|
|
11
11
|
|
12
12
|
## Configuration Settings
|
13
13
|
|
14
|
+
* `hab_license`: Habitat license acceptance type (for more information please read the [chef license documentation](https://docs.chef.io/chef_license_accept.html#habitat)).
|
15
|
+
* `hab_version`: The version of habitat to be used in test kitchen.
|
16
|
+
|
14
17
|
### Depot settings
|
15
18
|
|
16
19
|
* `depot_url`
|
@@ -17,6 +17,7 @@ module Kitchen
|
|
17
17
|
kitchen_provisioner_api_version 2
|
18
18
|
|
19
19
|
default_config :depot_url, nil
|
20
|
+
default_config :hab_license, nil
|
20
21
|
default_config :hab_version, "latest"
|
21
22
|
default_config :hab_sup_origin, "core"
|
22
23
|
default_config :hab_sup_name, "hab-sup"
|
@@ -84,6 +85,7 @@ module Kitchen
|
|
84
85
|
|
85
86
|
wrap_shell_code <<-BASH
|
86
87
|
#{export_hab_bldr_url}
|
88
|
+
#{export_hab_license}
|
87
89
|
if command -v hab >/dev/null 2>&1
|
88
90
|
then
|
89
91
|
echo "Habitat CLI already installed."
|
@@ -113,6 +115,7 @@ module Kitchen
|
|
113
115
|
def prepare_command
|
114
116
|
wrap_shell_code <<-EOH
|
115
117
|
#{export_hab_bldr_url}
|
118
|
+
#{export_hab_license}
|
116
119
|
#{install_supervisor_command}
|
117
120
|
#{binlink_supervisor_command}
|
118
121
|
#{install_service_package}
|
@@ -124,6 +127,7 @@ module Kitchen
|
|
124
127
|
def run_command
|
125
128
|
run = <<-RUN
|
126
129
|
#{export_hab_bldr_url}
|
130
|
+
#{export_hab_license}
|
127
131
|
#{clean_up_screen_sessions}
|
128
132
|
#{clean_up_previous_supervisor}
|
129
133
|
echo "Running #{package_ident}."
|
@@ -320,6 +324,12 @@ module Kitchen
|
|
320
324
|
"export HAB_BLDR_URL=#{config[:depot_url]}"
|
321
325
|
end
|
322
326
|
|
327
|
+
def export_hab_license
|
328
|
+
return if config[:hab_license].nil?
|
329
|
+
|
330
|
+
"export HAB_LICENSE=#{config[:hab_license]}"
|
331
|
+
end
|
332
|
+
|
323
333
|
def install_supervisor_command
|
324
334
|
"sudo -E hab pkg install #{hab_sup_ident}"
|
325
335
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: kitchen-habitat
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.11.
|
4
|
+
version: 0.11.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Steven Murawski
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-12-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: test-kitchen
|