5
6
7
8
9
10
11
12
13
14
15
16
|
# File 'lib/sambot/domain/session.rb', line 5
def self.start(username, password)
UI.debug("Opening a tunnel to the Rackspace DEV/QE environment...")
bastion = BastionHost.new.connect(username, password)
bastion.forwards.each do |forward|
UI.debug(" -- #{forward} will be forwarded to #{forward}")
end
UI.debug("Authenticating with Hashicorp Vault in Rackspace DEV/QE...")
token = Vault.authenticate(username, password)
UI.debug("Saving your Vault authentication token to ~/.vault-token...")
Vault.save_token(token)
UI.info("Your session has now started. Run `sambot session stop` to close it.")
end
|