acme-common: export main_domain
authorSergey Ponomarev <stokito@gmail.com>
Sat, 1 Jun 2024 11:23:04 +0000 (14:23 +0300)
committerToke Høiland-Jørgensen <toke@toke.dk>
Mon, 3 Jun 2024 08:09:09 +0000 (10:09 +0200)
To avoid confusion, first create the main_domain var and only then export it.

Signed-off-by: Sergey Ponomarev <stokito@gmail.com>
net/acme-common/files/acme.init

index 4d1efb1dc5da6925ed57fc6d557ef9c14677c79f..ba5d04165fc138c19d26a67877cf8aa0cb49ec19 100644 (file)
@@ -37,8 +37,8 @@ load_options() {
        export dalias
        config_get domains "$section" domains
        export domains
-       export main_domain
        main_domain="$(first_arg $domains)"
+       export main_domain
        config_get keylength "$section" keylength
        if [ "$keylength" ]; then
                log warn "Option \"keylength\" is deprecated, please use key_type (e.g., ec256, rsa2048) instead."