summaryrefslogtreecommitdiff
path: root/modules/caddytls/tls.go
diff options
context:
space:
mode:
authorMatthew Holt <mholt@users.noreply.github.com>2019-06-14 11:58:28 -0600
committerMatthew Holt <mholt@users.noreply.github.com>2019-06-14 11:58:28 -0600
commit5137859e47678aae81e178ca7d164f9e2b4e3121 (patch)
treef0e5cb9b9a4ad5dc03b53127fcea2a536bd6ee27 /modules/caddytls/tls.go
parentb8e7453fef3dac6036403bc384eec96becff5114 (diff)
Rename caddy2 -> caddy
Removes the version from the package name
Diffstat (limited to 'modules/caddytls/tls.go')
-rw-r--r--modules/caddytls/tls.go10
1 files changed, 5 insertions, 5 deletions
diff --git a/modules/caddytls/tls.go b/modules/caddytls/tls.go
index 22749ae..0614d24 100644
--- a/modules/caddytls/tls.go
+++ b/modules/caddytls/tls.go
@@ -6,13 +6,13 @@ import (
"fmt"
"net/http"
- "github.com/caddyserver/caddy2"
+ "github.com/caddyserver/caddy"
"github.com/go-acme/lego/challenge"
"github.com/mholt/certmagic"
)
func init() {
- caddy2.RegisterModule(caddy2.Module{
+ caddy.RegisterModule(caddy.Module{
Name: "tls",
New: func() interface{} { return new(TLS) },
})
@@ -26,11 +26,11 @@ type TLS struct {
certificateLoaders []CertificateLoader
certCache *certmagic.Cache
- ctx caddy2.Context
+ ctx caddy.Context
}
// Provision sets up the configuration for the TLS app.
-func (t *TLS) Provision(ctx caddy2.Context) error {
+func (t *TLS) Provision(ctx caddy.Context) error {
t.ctx = ctx
// set up the certificate cache
@@ -189,7 +189,7 @@ type AutomationPolicy struct {
Management managerMaker `json:"-"`
}
-func (ap AutomationPolicy) makeCertMagicConfig(ctx caddy2.Context) certmagic.Config {
+func (ap AutomationPolicy) makeCertMagicConfig(ctx caddy.Context) certmagic.Config {
// default manager (ACME) is a special case because of how CertMagic is designed
// TODO: refactor certmagic so that ACME manager is not a special case by extracting
// its config fields out of the certmagic.Config struct, or something...