kameleon-builder 2.1.1 → 2.1.3
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG.rst +10 -0
- data/docs/source/_static/centos.png +0 -0
- data/docs/source/_static/debian.png +0 -0
- data/docs/source/_static/ubuntu.png +0 -0
- data/docs/source/_themes/sphinx_rtd_theme/__init__.py +17 -0
- data/docs/source/_themes/sphinx_rtd_theme/breadcrumbs.html +19 -0
- data/docs/source/_themes/sphinx_rtd_theme/footer.html +32 -0
- data/docs/source/_themes/sphinx_rtd_theme/layout.html +160 -0
- data/docs/source/_themes/sphinx_rtd_theme/layout_old.html +205 -0
- data/docs/source/_themes/sphinx_rtd_theme/search.html +50 -0
- data/docs/source/_themes/sphinx_rtd_theme/searchbox.html +7 -0
- data/docs/source/_themes/sphinx_rtd_theme/static/css/badge_only.css +1 -0
- data/docs/source/_themes/sphinx_rtd_theme/static/css/theme.css +4 -0
- data/docs/source/_themes/sphinx_rtd_theme/static/fonts/FontAwesome.otf +0 -0
- data/docs/source/_themes/sphinx_rtd_theme/static/fonts/fontawesome-webfont.eot +0 -0
- data/docs/source/_themes/sphinx_rtd_theme/static/fonts/fontawesome-webfont.svg +414 -0
- data/docs/source/_themes/sphinx_rtd_theme/static/fonts/fontawesome-webfont.ttf +0 -0
- data/docs/source/_themes/sphinx_rtd_theme/static/fonts/fontawesome-webfont.woff +0 -0
- data/docs/source/_themes/sphinx_rtd_theme/static/js/theme.js +47 -0
- data/docs/source/_themes/sphinx_rtd_theme/theme.conf +8 -0
- data/docs/source/_themes/sphinx_rtd_theme/versions.html +37 -0
- data/docs/source/aliases.rst +2 -2
- data/docs/source/atlas_debian_g5k.yaml +36 -0
- data/docs/source/checkpoint.rst +1 -1
- data/docs/source/conf.py +4 -6
- data/docs/source/debian7.yaml +2 -2
- data/docs/source/getting_started.rst +132 -104
- data/docs/source/grid5000_tutorial.rst +36 -24
- data/docs/source/install_atlas.yaml +25 -0
- data/docs/source/install_hpl.yaml +24 -0
- data/docs/source/installation.rst +30 -16
- data/docs/source/persistent_cache.rst +3 -3
- data/docs/source/recipe.rst +6 -92
- data/docs/source/tau_install.yaml +19 -0
- data/docs/source/tau_install_g5k.yaml +13 -12
- data/docs/source/workspace.rst +2 -2
- data/lib/kameleon/cli.rb +3 -3
- data/lib/kameleon/recipe.rb +5 -6
- data/lib/kameleon/utils.rb +3 -4
- data/templates/{old-debian7.yaml → debian7-chroot.yaml} +1 -1
- data/version.txt +1 -1
- metadata +27 -3
data/lib/kameleon/recipe.rb
CHANGED
@@ -14,9 +14,9 @@ module Kameleon
|
|
14
14
|
attr_accessor :checkpoint_path
|
15
15
|
attr_accessor :metainfo
|
16
16
|
|
17
|
-
def initialize(path)
|
17
|
+
def initialize(path, kwargs = {})
|
18
18
|
@logger = Log4r::Logger.new("kameleon::[kameleon]")
|
19
|
-
@path = Pathname.new(path)
|
19
|
+
@path = Pathname.new(File.expand_path(path))
|
20
20
|
@name = (@path.basename ".yaml").to_s
|
21
21
|
@recipe_content = File.open(@path, 'r') { |f| f.read }
|
22
22
|
@sections = {
|
@@ -39,10 +39,10 @@ module Kameleon
|
|
39
39
|
@files = []
|
40
40
|
@logger.debug("Initialize new recipe (#{path})")
|
41
41
|
@base_recipes_files = [@path]
|
42
|
-
load!
|
42
|
+
load! kwargs
|
43
43
|
end
|
44
44
|
|
45
|
-
def load!
|
45
|
+
def load!(kwargs = {})
|
46
46
|
# Find recipe path
|
47
47
|
@logger.debug("Loading #{@path}")
|
48
48
|
fail RecipeError, "Could not find this following recipe : #{@path}" \
|
@@ -58,9 +58,8 @@ module Kameleon
|
|
58
58
|
# Load Global variables
|
59
59
|
@global.merge!(yaml_recipe.fetch("global", {}))
|
60
60
|
# Resolve dynamically-defined variables !!
|
61
|
-
resolved_global = Utils.resolve_vars(@global.to_yaml, @path, @global,
|
61
|
+
resolved_global = Utils.resolve_vars(@global.to_yaml, @path, @global, kwargs)
|
62
62
|
@global.merge! YAML.load(resolved_global)
|
63
|
-
|
64
63
|
# Loads aliases
|
65
64
|
load_aliases(yaml_recipe)
|
66
65
|
# Loads checkpoint configuration
|
data/lib/kameleon/utils.rb
CHANGED
@@ -2,7 +2,6 @@ module Kameleon
|
|
2
2
|
module Utils
|
3
3
|
|
4
4
|
def self.resolve_vars(raw, yaml_path, initial_variables, kwargs = {})
|
5
|
-
strict = kwargs.fetch('strict', true)
|
6
5
|
raw.to_s.gsub(/\$\$\{[a-zA-Z0-9\-_]+\}|\$\$[a-zA-Z0-9\-_]+/) do |var|
|
7
6
|
# remove the dollars
|
8
7
|
if var.include? "{"
|
@@ -14,11 +13,11 @@ module Kameleon
|
|
14
13
|
if initial_variables.has_key? strip_var
|
15
14
|
value = initial_variables[strip_var]
|
16
15
|
else
|
17
|
-
if strict
|
18
|
-
fail RecipeError, "#{yaml_path}: variable #{var} not found in local or global"
|
16
|
+
if kwargs.fetch(:strict, true)
|
17
|
+
fail RecipeError, "#{yaml_path}: variable #{var} not found in local or global"
|
19
18
|
end
|
20
19
|
end
|
21
|
-
return $` + resolve_vars(value.to_s + $', yaml_path, initial_variables)
|
20
|
+
return $` + resolve_vars(value.to_s + $', yaml_path, initial_variables, kwargs)
|
22
21
|
end
|
23
22
|
end
|
24
23
|
|
@@ -2,7 +2,7 @@
|
|
2
2
|
# vim: softtabstop=2 shiftwidth=2 expandtab fenc=utf-8 cc=81 tw=80
|
3
3
|
#==============================================================================
|
4
4
|
#
|
5
|
-
# DESCRIPTION:
|
5
|
+
# DESCRIPTION: Build a debian wheezy appliance using chroot and qemu-nbd.
|
6
6
|
#
|
7
7
|
#==============================================================================
|
8
8
|
|
data/version.txt
CHANGED
@@ -1 +1 @@
|
|
1
|
-
2.1.
|
1
|
+
2.1.3
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: kameleon-builder
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.1.
|
4
|
+
version: 2.1.3
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -12,7 +12,7 @@ authors:
|
|
12
12
|
autorequire:
|
13
13
|
bindir: bin
|
14
14
|
cert_chain: []
|
15
|
-
date: 2014-06-
|
15
|
+
date: 2014-06-18 00:00:00.000000000 Z
|
16
16
|
dependencies:
|
17
17
|
- !ruby/object:Gem::Dependency
|
18
18
|
name: childprocess
|
@@ -227,10 +227,31 @@ files:
|
|
227
227
|
- docs/README.md
|
228
228
|
- docs/make.bat
|
229
229
|
- docs/source/_static/.gitignore
|
230
|
+
- docs/source/_static/centos.png
|
231
|
+
- docs/source/_static/debian.png
|
230
232
|
- docs/source/_static/kameleon-logo.png
|
231
233
|
- docs/source/_static/kameleon-logo.xcf
|
232
234
|
- docs/source/_static/kameleon-long.png
|
235
|
+
- docs/source/_static/ubuntu.png
|
236
|
+
- docs/source/_themes/sphinx_rtd_theme/__init__.py
|
237
|
+
- docs/source/_themes/sphinx_rtd_theme/breadcrumbs.html
|
238
|
+
- docs/source/_themes/sphinx_rtd_theme/footer.html
|
239
|
+
- docs/source/_themes/sphinx_rtd_theme/layout.html
|
240
|
+
- docs/source/_themes/sphinx_rtd_theme/layout_old.html
|
241
|
+
- docs/source/_themes/sphinx_rtd_theme/search.html
|
242
|
+
- docs/source/_themes/sphinx_rtd_theme/searchbox.html
|
243
|
+
- docs/source/_themes/sphinx_rtd_theme/static/css/badge_only.css
|
244
|
+
- docs/source/_themes/sphinx_rtd_theme/static/css/theme.css
|
245
|
+
- docs/source/_themes/sphinx_rtd_theme/static/fonts/FontAwesome.otf
|
246
|
+
- docs/source/_themes/sphinx_rtd_theme/static/fonts/fontawesome-webfont.eot
|
247
|
+
- docs/source/_themes/sphinx_rtd_theme/static/fonts/fontawesome-webfont.svg
|
248
|
+
- docs/source/_themes/sphinx_rtd_theme/static/fonts/fontawesome-webfont.ttf
|
249
|
+
- docs/source/_themes/sphinx_rtd_theme/static/fonts/fontawesome-webfont.woff
|
250
|
+
- docs/source/_themes/sphinx_rtd_theme/static/js/theme.js
|
251
|
+
- docs/source/_themes/sphinx_rtd_theme/theme.conf
|
252
|
+
- docs/source/_themes/sphinx_rtd_theme/versions.html
|
233
253
|
- docs/source/aliases.rst
|
254
|
+
- docs/source/atlas_debian_g5k.yaml
|
234
255
|
- docs/source/checkpoint.rst
|
235
256
|
- docs/source/commands.rst
|
236
257
|
- docs/source/conf.py
|
@@ -242,9 +263,12 @@ files:
|
|
242
263
|
- docs/source/getting_started.rst
|
243
264
|
- docs/source/grid5000_tutorial.rst
|
244
265
|
- docs/source/index.rst
|
266
|
+
- docs/source/install_atlas.yaml
|
267
|
+
- docs/source/install_hpl.yaml
|
245
268
|
- docs/source/installation.rst
|
246
269
|
- docs/source/persistent_cache.rst
|
247
270
|
- docs/source/recipe.rst
|
271
|
+
- docs/source/tau_install.yaml
|
248
272
|
- docs/source/tau_install_g5k.yaml
|
249
273
|
- docs/source/use_cases.rst
|
250
274
|
- docs/source/workspace.rst
|
@@ -286,6 +310,7 @@ files:
|
|
286
310
|
- templates/archlinux-desktop.yaml
|
287
311
|
- templates/archlinux.yaml
|
288
312
|
- templates/debian-testing.yaml
|
313
|
+
- templates/debian7-chroot.yaml
|
289
314
|
- templates/debian7-desktop.yaml
|
290
315
|
- templates/debian7-g5k.yaml
|
291
316
|
- templates/debian7-kameleon.yaml
|
@@ -296,7 +321,6 @@ files:
|
|
296
321
|
- templates/fedora-rawhide.yaml
|
297
322
|
- templates/fedora20-desktop.yaml
|
298
323
|
- templates/fedora20.yaml
|
299
|
-
- templates/old-debian7.yaml
|
300
324
|
- templates/steps/aliases/defaults.yaml
|
301
325
|
- templates/steps/bootstrap/archlinux/arch_bootstrap.yaml
|
302
326
|
- templates/steps/bootstrap/archlinux/install_bootloader.yaml
|