summaryrefslogtreecommitdiff
path: root/modules/caddyhttp/autohttps.go
diff options
context:
space:
mode:
authorMatthew Holt <mholt@users.noreply.github.com>2020-03-15 21:22:26 -0600
committerMatthew Holt <mholt@users.noreply.github.com>2020-03-15 21:22:26 -0600
commit0433f9d075452d78ac93c72bad37856dc1b5b6f7 (patch)
treed76f628e98bceff36b59897dafabe2c2b515bfe5 /modules/caddyhttp/autohttps.go
parentc67c8e60ccba736ed06f6a86c1fa2922e81a285f (diff)
caddytls: Clean up some code related to automation
Diffstat (limited to 'modules/caddyhttp/autohttps.go')
-rw-r--r--modules/caddyhttp/autohttps.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/modules/caddyhttp/autohttps.go b/modules/caddyhttp/autohttps.go
index 2c35da8..dfd659f 100644
--- a/modules/caddyhttp/autohttps.go
+++ b/modules/caddyhttp/autohttps.go
@@ -235,7 +235,7 @@ uniqueDomainsLoop:
// one automation policy would be confusing and an error
if app.tlsApp.Automation != nil {
for _, ap := range app.tlsApp.Automation.Policies {
- for _, apHost := range ap.Hosts {
+ for _, apHost := range ap.Subjects {
if apHost == d {
continue uniqueDomainsLoop
}
@@ -424,7 +424,7 @@ func (app *App) createAutomationPolicies(ctx caddy.Context, publicNames, interna
// custom CA endpoint, for example - whichever one we choose must
// have a host list that is a superset of the policy we make...
// the policy with no host filter is guaranteed to qualify
- if len(ap.Hosts) == 0 {
+ if len(ap.Subjects) == 0 {
basePolicy = ap
break
}
@@ -451,7 +451,7 @@ func (app *App) createAutomationPolicies(ctx caddy.Context, publicNames, interna
}
}
newPolicy.Issuer = issuer
- newPolicy.Hosts = hosts
+ newPolicy.Subjects = hosts
return app.tlsApp.AddAutomationPolicy(newPolicy)
}