Rename caddy2 -> caddy

Removes the version from the package name
This commit is contained in:
Matthew Holt 2019-06-14 11:58:28 -06:00
parent b8e7453fef
commit 5137859e47
48 changed files with 199 additions and 193 deletions

View file

@ -1,23 +1,23 @@
package main
import (
caddycmd "github.com/caddyserver/caddy2/cmd"
caddycmd "github.com/caddyserver/caddy/cmd"
// this is where modules get plugged in
_ "github.com/caddyserver/caddy2/modules/caddyhttp"
_ "github.com/caddyserver/caddy2/modules/caddyhttp/caddylog"
_ "github.com/caddyserver/caddy2/modules/caddyhttp/encode"
_ "github.com/caddyserver/caddy2/modules/caddyhttp/encode/brotli"
_ "github.com/caddyserver/caddy2/modules/caddyhttp/encode/gzip"
_ "github.com/caddyserver/caddy2/modules/caddyhttp/encode/zstd"
_ "github.com/caddyserver/caddy2/modules/caddyhttp/fileserver"
_ "github.com/caddyserver/caddy2/modules/caddyhttp/headers"
_ "github.com/caddyserver/caddy2/modules/caddyhttp/markdown"
_ "github.com/caddyserver/caddy2/modules/caddyhttp/requestbody"
_ "github.com/caddyserver/caddy2/modules/caddyhttp/reverseproxy"
_ "github.com/caddyserver/caddy2/modules/caddyhttp/rewrite"
_ "github.com/caddyserver/caddy2/modules/caddytls"
_ "github.com/caddyserver/caddy2/modules/caddytls/standardstek"
_ "github.com/caddyserver/caddy/modules/caddyhttp"
_ "github.com/caddyserver/caddy/modules/caddyhttp/caddylog"
_ "github.com/caddyserver/caddy/modules/caddyhttp/encode"
_ "github.com/caddyserver/caddy/modules/caddyhttp/encode/brotli"
_ "github.com/caddyserver/caddy/modules/caddyhttp/encode/gzip"
_ "github.com/caddyserver/caddy/modules/caddyhttp/encode/zstd"
_ "github.com/caddyserver/caddy/modules/caddyhttp/fileserver"
_ "github.com/caddyserver/caddy/modules/caddyhttp/headers"
_ "github.com/caddyserver/caddy/modules/caddyhttp/markdown"
_ "github.com/caddyserver/caddy/modules/caddyhttp/requestbody"
_ "github.com/caddyserver/caddy/modules/caddyhttp/reverseproxy"
_ "github.com/caddyserver/caddy/modules/caddyhttp/rewrite"
_ "github.com/caddyserver/caddy/modules/caddytls"
_ "github.com/caddyserver/caddy/modules/caddytls/standardstek"
)
func main() {

View file

@ -4,18 +4,18 @@ import (
"flag"
"log"
"github.com/caddyserver/caddy2"
"github.com/caddyserver/caddy"
)
// Main executes the main function of the caddy command.
func Main() {
flag.Parse()
err := caddy2.StartAdmin(*listenAddr)
err := caddy.StartAdmin(*listenAddr)
if err != nil {
log.Fatal(err)
}
defer caddy2.StopAdmin()
defer caddy.StopAdmin()
log.Println("Caddy 2 admin endpoint listening on", *listenAddr)