mirror of
https://github.com/certbot/certbot.git
synced 2026-07-26 16:19:36 +02:00
Move Nginx TLS configuration files into a specific folder (#7300)
Following discussions in #7298. This PR moves the three Nginx TLS configuration files into a specific folder, tls_configs, update the MANIFEST to include this folder and its content into the certbot-nginx package, and update tests accordingly. * Move tls configuration files in a specific folder * Move new file
This commit is contained in:
committed by
Brad Warren
parent
14e10f40e5
commit
8bcb04af4a
@@ -2,5 +2,4 @@ include LICENSE.txt
|
||||
include README.rst
|
||||
recursive-include docs *
|
||||
recursive-include certbot_nginx/tests/testdata *
|
||||
include certbot_nginx/options-ssl-nginx.conf
|
||||
include certbot_nginx/options-ssl-nginx-old.conf
|
||||
recursive-include certbot_nginx/tls_configs *.conf
|
||||
|
||||
@@ -129,7 +129,8 @@ class NginxConfigurator(common.Installer):
|
||||
config_filename = "options-ssl-nginx-old.conf"
|
||||
elif self.version < (1, 13, 0):
|
||||
config_filename = "options-ssl-nginx-tls12-only.conf"
|
||||
return pkg_resources.resource_filename("certbot_nginx", config_filename)
|
||||
return pkg_resources.resource_filename(
|
||||
"certbot_nginx", os.path.join("tls_configs", config_filename))
|
||||
|
||||
@property
|
||||
def mod_ssl_conf(self):
|
||||
|
||||
@@ -972,11 +972,12 @@ class InstallSslOptionsConfTest(util.NginxTest):
|
||||
"""
|
||||
from certbot_nginx.constants import ALL_SSL_OPTIONS_HASHES
|
||||
import pkg_resources
|
||||
all_files = [pkg_resources.resource_filename("certbot_nginx", x) for x in (
|
||||
"options-ssl-nginx.conf",
|
||||
"options-ssl-nginx-old.conf",
|
||||
"options-ssl-nginx-tls12-only.conf"
|
||||
)]
|
||||
all_files = [
|
||||
pkg_resources.resource_filename("certbot_nginx", os.path.join("tls_configs", x))
|
||||
for x in ("options-ssl-nginx.conf",
|
||||
"options-ssl-nginx-old.conf",
|
||||
"options-ssl-nginx-tls12-only.conf")
|
||||
]
|
||||
self.assertTrue(all_files)
|
||||
for one_file in all_files:
|
||||
file_hash = crypto_util.sha256sum(one_file)
|
||||
|
||||
Reference in New Issue
Block a user