[pmg-devel] [PATCH api] rearrange acme files

Wolfgang Bumiller w.bumiller at proxmox.com
Thu Mar 18 09:51:58 CET 2021


Old layout:
  /etc/pmg/acme-plugins.conf
  /etc/pmg/acme/<account_name>

New layout:
  /etc/pmg/acme/plugins.conf
  /etc/pmg/acme/accounts/<account_name>

Signed-off-by: Wolfgang Bumiller <w.bumiller at proxmox.com>
---
Since this hasn't been packaged yet this should be fine.

 src/PMG/API2/ACMEPlugin.pm | 2 +-
 src/PMG/CertHelpers.pm     | 2 +-
 src/PMG/Cluster.pm         | 1 -
 3 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/src/PMG/API2/ACMEPlugin.pm b/src/PMG/API2/ACMEPlugin.pm
index 0842966..4f18e0c 100644
--- a/src/PMG/API2/ACMEPlugin.pm
+++ b/src/PMG/API2/ACMEPlugin.pm
@@ -15,7 +15,7 @@ use PVE::Tools qw(extract_param);
 use base qw(PVE::RESTHandler);
 
 my $inotify_file_id = 'pmg-acme-plugins-config.conf';
-my $config_filename = '/etc/pmg/acme-plugins.conf';
+my $config_filename = '/etc/pmg/acme/plugins.conf';
 my $lockfile = "/var/lock/pmg-acme-plugins-config.lck";
 
 PVE::ACME::DNSChallenge->register();
diff --git a/src/PMG/CertHelpers.pm b/src/PMG/CertHelpers.pm
index 56b25f7..5122f71 100644
--- a/src/PMG/CertHelpers.pm
+++ b/src/PMG/CertHelpers.pm
@@ -12,7 +12,7 @@ use constant {
     SMTP_CERT => '/etc/pmg/pmg-tls.pem',
 };
 
-my $account_prefix = '/etc/pmg/acme';
+my $account_prefix = '/etc/pmg/acme/accounts';
 
 # TODO: Move `pve-acme-account-name` to common and reuse instead of this.
 PVE::JSONSchema::register_standard_option('pmg-acme-account-name', {
diff --git a/src/PMG/Cluster.pm b/src/PMG/Cluster.pm
index 0c35d87..e7bf266 100644
--- a/src/PMG/Cluster.pm
+++ b/src/PMG/Cluster.pm
@@ -458,7 +458,6 @@ sub sync_config_from_master {
 	'transport',
 	'tls_policy',
 	'fetchmailrc',
-	'acme-plugins.conf',
 	];
 
     foreach my $filename (@$files) {
-- 
2.20.1





More information about the pmg-devel mailing list