Class: Ruby::Nginx::Commands::CreateMkcertCertificate

Inherits:
TerminalCommand show all
Defined in:
lib/ruby/nginx/commands/create_mkcert_certificate.rb

Instance Attribute Summary

Attributes inherited from TerminalCommand

#cmd, #error_type, #printer, #result, #user

Instance Method Summary collapse

Methods inherited from TerminalCommand

#run

Methods included from Helpers::SudoHelper

#sudoify

Methods included from Helpers::PromptHelper

#yes?

Constructor Details

#initialize(domain, cert_file_path, key_file_path) ⇒ CreateMkcertCertificate

Returns a new instance of CreateMkcertCertificate.



9
10
11
12
13
14
# File 'lib/ruby/nginx/commands/create_mkcert_certificate.rb', line 9

def initialize(domain, cert_file_path, key_file_path)
  super(
    cmd: "mkcert -cert-file #{cert_file_path} -key-file #{key_file_path} #{domain}",
    raise: Ruby::Nginx::CreateError
  )
end