bin/forj in forj-0.0.19 vs bin/forj in forj-0.0.20
- old
+ new
@@ -1,6 +1,7 @@
#!/usr/bin/env ruby
+# encoding: UTF-8
# (c) Copyright 2014 Hewlett-Packard Development Company, L.P.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -59,41 +60,47 @@
puts ' openstack_auth_url: your openstack identity endpoint'
puts ''
end
desc 'boot', 'boot a Maestro box and instruct it to provision the blueprint'
- method_option :build_conf_dir, :aliases => '-c', :desc => 'build config dir to use'
- method_option :branch, :aliases => '-b', :desc => 'branch to use'
- method_option :test_box, :aliases => '-t', :desc => 'test box'
- def boot(blueprint, on, cloud_provider, as, name, test=false)
+
+ method_option :build_conf_dir, :aliases => '-bcd', :desc => 'Defines the build configuration directory to load the build configuration file. You can set FORJ_BLD_CONF_DIR. By default, it will look in your current directory.'
+ method_option :build_conf, :aliases => '-bc', :desc => 'The build config file to load <confdir>/<BoxName>.<Config>.env. By default, uses "master" as Config.'
+ method_option :branch, :aliases => '-gb', :desc => 'The build will extract from git branch name. It sets the configuration build <config> to the branch name <branch>.'
+ method_option :test_box, :aliases => '-tb', :desc => 'Create test-box meta from the repository path provided.'
+ method_option :git_repo, :aliases => '-gr', :desc => 'The box built will use a different git repository sent out to <user_data>. This repository needs to be read only. No keys are sent.'
+ method_option :boothook, :aliases => '-b', :desc => 'By default, boothook file used is build/bin/build-tools/boothook.sh. Use this option to set another one.'
+ method_option :box_name, :aliases => '-bn', :desc => 'Defines the name of the box or box image to build.'
+
+ def boot(blueprint, on, cloud_provider, as, name, test = false)
build_conf_dir = options[:build_conf_dir]
branch = options[:branch]
unless branch
branch = 'master'
end
if options[:build_conf_dir]
- Boot.boot(blueprint, cloud_provider, name, build_conf_dir, branch, test)
+ Boot::boot(blueprint, cloud_provider, name, build_conf_dir, branch, test)
else
- Boot.boot(blueprint, cloud_provider, name, nil, nil, test)
+ Boot::boot(blueprint, cloud_provider, name, nil, nil, test)
end
end
desc 'down', 'delete the Maestro box and all systems installed by the blueprint'
def down(name)
- Down.down(name)
+ Down::down(name)
end
- desc 'ssh', ''
+ desc 'ssh', 'connect to your forge thru ssh'
def ssh
puts 'ssh'
end
desc 'setup', 'set the credentials for forj cli'
def setup
- Setup.setup
+ Setup::setup
end
end
-Forj.start
\ No newline at end of file
+Forj.start