diff options
author | Tim Smith <tsmith@chef.io> | 2018-08-16 14:29:44 -0700 |
---|---|---|
committer | Tim Smith <tsmith@chef.io> | 2018-08-16 14:29:44 -0700 |
commit | 567b82e91cb4ae1b72eec8632d1712dd8608ebcc (patch) | |
tree | 0b49021c2a03239e023c47cc946ab7fabfb0728e /lib/chef/resource/openssl_x509_certificate.rb | |
parent | d1461202273c319966a1cc3dd6872bb56582db39 (diff) | |
download | chef-567b82e91cb4ae1b72eec8632d1712dd8608ebcc.tar.gz |
Add specs for the x509_cert and x509_request resourcesopenssl_new_stuff
Fix the defaults that should be lazied and fix the duplicate class name I was using.
Signed-off-by: Tim Smith <tsmith@chef.io>
Diffstat (limited to 'lib/chef/resource/openssl_x509_certificate.rb')
-rw-r--r-- | lib/chef/resource/openssl_x509_certificate.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/chef/resource/openssl_x509_certificate.rb b/lib/chef/resource/openssl_x509_certificate.rb index 7c354588af..04641e877b 100644 --- a/lib/chef/resource/openssl_x509_certificate.rb +++ b/lib/chef/resource/openssl_x509_certificate.rb @@ -70,11 +70,11 @@ class Chef property :extensions, Hash, description: "Hash of X509 Extensions entries, in format { 'keyUsage' => { 'values' => %w( keyEncipherment digitalSignature), 'critical' => true } }.", - default: {} + default: lazy { Hash.new } property :subject_alt_name, Array, description: "Array of Subject Alternative Name entries, in format DNS:example.com or IP:1.2.3.4.", - default: [] + default: lazy { [] } property :key_file, String, description: "The path to a certificate key file on the filesystem. If the key_file attribute is specified, the resource will attempt to source a key from this location. If no key file is found, the resource will generate a new key file at this location. If the key_file attribute is not specified, the resource will generate a key file in the same directory as the generated certificate, with the same name as the generated certificate." |