Module: Kontena::Cli::Certificate::Common
- Included in:
- ImportCommand, ShowCommand
- Defined in:
- lib/kontena/cli/certificate/common.rb
Instance Method Summary collapse
Instance Method Details
#show_certificate(cert) ⇒ Object
3 4 5 6 7 8 9 10 11 12 13 14 |
# File 'lib/kontena/cli/certificate/common.rb', line 3 def show_certificate(cert) puts "#{cert['id']}:" puts " subject: #{cert['subject']}" puts " valid until: #{Time.parse(cert['valid_until']).utc.strftime("%FT%TZ")}" if cert['alt_names'] && !cert['alt_names'].empty? puts " alt names:" cert['alt_names'].each do |alt_name| puts " - #{alt_name}" end end puts " auto renewable: #{cert['auto_renewable']}" end |