From 95f9e94bea64dda76a839d2257017ca146cfbf5a Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 17 Aug 2020 15:27:34 -0700 Subject: [PATCH] autocert: fix bootstrapped cache store path (#1283) (#1291) Signed-off-by: Bobby DeSimone Co-authored-by: bobby <1544881+desimone@users.noreply.github.com> --- internal/autocert/manager.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/internal/autocert/manager.go b/internal/autocert/manager.go index 9be7ccb2c..467b92ff6 100644 --- a/internal/autocert/manager.go +++ b/internal/autocert/manager.go @@ -30,6 +30,12 @@ type Manager struct { // New creates a new autocert manager. func New(src config.Source) (*Manager, error) { + // set certmagic default storage cache, otherwise cert renewal loop will be based off + // certmagic's own default location + certmagic.Default.Storage = &certmagic.FileStorage{ + Path: src.GetConfig().Options.AutocertOptions.Folder, + } + mgr := &Manager{ src: src, certmagic: certmagic.NewDefault(),