Sha256: cb1793e0cc4b6483a89e7a3c1a5d646576f6b30799fbc96d342c737ab94919f8
Contents?: true
Size: 1.13 KB
Versions: 1
Compression:
Stored size: 1.13 KB
Contents
require 'json' require 'commands/add-env' require 'plan-step-class' class ApplyConfig def initialize () @log = Logger.new(Canzea::config[:logging_root] + '/plans.log') end def do (gitRoot, test = false, stepNum = nil, task = nil) ps = PlanStep.new # Read the configuration file and make calls out to run @log.info("Processing #{gitRoot}/configure.json") puts "Processing #{gitRoot}/configure.json" steps = JSON.parse(File.read("#{gitRoot}/configure.json")) index = 1 steps["steps"].each { | step | AddEnv.new.injectEnvironmentVariables() role = step['role'] solution = step['solution'] puts "#{stepNum} and #{index}" if (stepNum == nil or index >= Integer(stepNum)) @log.info "[#{index}] Configure for #{role} and #{solution}" ps.runPhaseConfigure role, solution, test, (task == nil ? 1:task) task = 1 else @log.info "[#{index}] Configure for #{role} and #{solution} SKIP" end index = index + 1 } end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
canzea-0.1.57 | lib/commands/apply-config.rb |