From a8e4aa454c784238ce51f5e9114f0d6261702b81 Mon Sep 17 00:00:00 2001 From: crapStone Date: Wed, 27 Nov 2024 23:08:17 +0100 Subject: [PATCH] again --- server/acme/client.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/acme/client.go b/server/acme/client.go index 3f62647..8aa05d6 100644 --- a/server/acme/client.go +++ b/server/acme/client.go @@ -14,7 +14,7 @@ var ErrAcmeMissConfig = errors.New("ACME client has wrong config") func CreateAcmeClient(cfg config.ACMEConfig, enableHTTPServer bool, challengeCache cache.ICache) (*certificates.AcmeClient, error) { // check config - if (!cfg.AcceptTerms || (cfg.DNSProvider == "" && !cfg.NoDNS01)) && (cfg.APIEndpoint != "https://acme.mock.directory" || strings.HasPrefix(cfg.APIEndpoint, "https://localhost")) { + if (!cfg.AcceptTerms || (cfg.DNSProvider == "" && !cfg.NoDNS01)) && (cfg.APIEndpoint != "https://acme.mock.directory" || !strings.HasPrefix(cfg.APIEndpoint, "https://localhost")) { return nil, fmt.Errorf("%w: you must set $ACME_ACCEPT_TERMS and $DNS_PROVIDER or $NO_DNS_01, unless $ACME_API is set to https://acme.mock.directory or starts with https://localhost", ErrAcmeMissConfig) } if cfg.EAB_HMAC != "" && cfg.EAB_KID == "" {