generated from genaumann/salt-formula-template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
40 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
# frozen_string_literal: true | ||
|
||
control "Cert x509 #{os.name}" do | ||
title 'Test x509 cert files' | ||
|
||
dir = '/home/vagrant/crt/acmeshtest.gn98.de' | ||
|
||
describe x509_certificate("#{dir}/fullchain.cer") do | ||
it { should be_certificate } | ||
its('key_length') { should be 4096 } | ||
its('subject.CN') { should eq 'acmeshtest.gn98.de' } | ||
its('validity_in_days') { should be > 30 } | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# frozen_string_literal: true | ||
|
||
control "Cert files #{os.name}" do | ||
title 'Test cert files' | ||
|
||
dir = '/home/vagrant/crt/acmeshtest.gn98.de' | ||
|
||
describe directory(dir) do | ||
it { should exist } | ||
end | ||
|
||
describe file("#{dir}/fullchain.cer") do | ||
it { should exist } | ||
end | ||
|
||
describe file("#{dir}/acmeshtest.gn98.de.key") do | ||
it { should exist } | ||
end | ||
end |