Class: Salt::Matrix::Cli

Inherits:
Thor
  • Object
show all
Defined in:
lib/salt/matrix/cli.rb,
lib/salt/matrix/cli/deploy.rb

Defined Under Namespace

Classes: Deploy

Instance Method Summary collapse

Instance Method Details

#deployObject



39
40
41
42
43
44
45
46
47
48
49
50
# File 'lib/salt/matrix/cli.rb', line 39

def deploy 
  if options['debug']
    Salt::Master.set_debug
  end
  deploy_dir = File.expand_path options['dir']
  Salt::Matrix.debug "Deployment directory set to #{deploy_dir}"
  saltfile = Salt::Saltfile.new deploy_dir
  saltfile.load
  saltfile.formulas.each do |f| 
    f.sync
  end
end

#fooObject

Raises:

  • (RuntimeError)


54
55
56
# File 'lib/salt/matrix/cli.rb', line 54

def foo
  raise RuntimeError, 'This is foo'
end

#versionObject



16
17
18
# File 'lib/salt/matrix/cli.rb', line 16

def version
  puts Salt::Matrix::VERSION
end