mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
ipatests: configure MDStoreDir for mod_md ACME test
This directory defines the location for ACME-related files used by mod_md. Specify and create it rather than relying on defaults to both fix a test failure and to make the files accessable for debugging purposes. https://pagure.io/freeipa/issue/8581 Signed-off-by: Rob Crittenden <rcritten@redhat.com> Reviewed-By: Mohammad Rizwan <myusuf@redhat.com> Reviewed-By: Florence Blanc-Renaud <frenaud@redhat.com> Reviewed-By: Armando Neto <abiagion@redhat.com>
This commit is contained in:
parent
70306515f7
commit
3a9fc01156
@ -291,11 +291,13 @@ class TestACME(CALessBase):
|
|||||||
def test_mod_md(self):
|
def test_mod_md(self):
|
||||||
# write config
|
# write config
|
||||||
self.clients[0].run_command(['mkdir', '-p', '/etc/httpd/conf.d'])
|
self.clients[0].run_command(['mkdir', '-p', '/etc/httpd/conf.d'])
|
||||||
|
self.clients[0].run_command(['mkdir', '-p', '/etc/httpd/md'])
|
||||||
self.clients[0].put_file_contents(
|
self.clients[0].put_file_contents(
|
||||||
'/etc/httpd/conf.d/md.conf',
|
'/etc/httpd/conf.d/md.conf',
|
||||||
'\n'.join([
|
'\n'.join([
|
||||||
f'MDCertificateAuthority {self.acme_server}',
|
f'MDCertificateAuthority {self.acme_server}',
|
||||||
'MDCertificateAgreement accepted',
|
'MDCertificateAgreement accepted',
|
||||||
|
'MDStoreDir /etc/httpd/md',
|
||||||
f'MDomain {self.clients[0].hostname}',
|
f'MDomain {self.clients[0].hostname}',
|
||||||
'<VirtualHost *:443>',
|
'<VirtualHost *:443>',
|
||||||
f' ServerName {self.clients[0].hostname}',
|
f' ServerName {self.clients[0].hostname}',
|
||||||
@ -325,6 +327,10 @@ class TestACME(CALessBase):
|
|||||||
self.master.run_command(
|
self.master.run_command(
|
||||||
['curl', f'https://{self.clients[0].hostname}'])
|
['curl', f'https://{self.clients[0].hostname}'])
|
||||||
|
|
||||||
|
# clean-up
|
||||||
|
self.clients[0].run_command(['rm', '-rf', '/etc/httpd/md'])
|
||||||
|
self.clients[0].run_command(['rm', '-f', '/etc/httpd/conf.d/md.conf'])
|
||||||
|
|
||||||
######################
|
######################
|
||||||
# Disable ACME service
|
# Disable ACME service
|
||||||
######################
|
######################
|
||||||
|
Loading…
Reference in New Issue
Block a user