From: Fabian Grünbichler Date: Thu, 16 Apr 2020 18:45:04 +0000 (+0200) Subject: dns plugin: make data optional X-Git-Url: https://git.proxmox.com/?p=proxmox-acme.git;a=commitdiff_plain;h=13b638827a062c00bb0be7950d408fe097060630 dns plugin: make data optional it might be hard-coded in a (modified) plugin, or not needed Signed-off-by: Fabian Grünbichler --- diff --git a/src/PVE/ACME/DNSChallenge.pm b/src/PVE/ACME/DNSChallenge.pm index f62333b..107163a 100644 --- a/src/PVE/ACME/DNSChallenge.pm +++ b/src/PVE/ACME/DNSChallenge.pm @@ -137,7 +137,7 @@ sub properties { sub options { return { api => {}, - data => {}, + data => { optional => 1 }, nodes => { optional => 1 }, disable => { optional => 1 }, }; diff --git a/src/proxmox-acme b/src/proxmox-acme index 566588f..29deba4 100644 --- a/src/proxmox-acme +++ b/src/proxmox-acme @@ -617,7 +617,9 @@ setup() { plugin_conf_string=$4 DEBUG=$5 - _load_plugin_config + if [ -n "$plugin_conf_string" ]; then + _load_plugin_config + fi if ! . "$dns_plugin_path"; then _err "Load file $dns_plugin error." @@ -644,7 +646,9 @@ teardown() { plugin_conf_string=$4 DEBUG=$5 - _load_plugin_config + if [ -n "$plugin_conf_string" ]; then + _load_plugin_config + fi if ! . "$dns_plugin_path"; then _err "Load file $dns_plugin error."