Method: Azuki::Command::Certs#add

Defined in:
lib/azuki/command/certs.rb

#addObject

certs:add CRT KEY

Add an ssl endpoint to an app.

--bypass  # bypass the trust chain completion step


71
72
73
74
75
76
77
78
79
80
# File 'lib/azuki/command/certs.rb', line 71

def add
  crt, key = read_crt_and_key
  endpoint = action("Adding SSL Endpoint to #{app}") { azuki.ssl_endpoint_add(app, crt, key) }
  display_warnings(endpoint)
  display "#{app} now served by #{endpoint['cname']}"
  display "Certificate details:"
  display_certificate_info(endpoint)
rescue UsageError
  fail("Usage: azuki certs:add CRT KEY\nMust specify CRT and KEY to add cert.")
end