From 2eb35933271d5b2ef1ca29aaa8f00f6748c56424 Mon Sep 17 00:00:00 2001 From: Matthew Holt Date: Sat, 4 May 2019 13:21:20 -0600 Subject: Begin implementing HTTP replacer and static responder --- cmd/caddy2/main.go | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) (limited to 'cmd/caddy2') diff --git a/cmd/caddy2/main.go b/cmd/caddy2/main.go index 4be632c..5a09d87 100644 --- a/cmd/caddy2/main.go +++ b/cmd/caddy2/main.go @@ -1,28 +1,18 @@ package main import ( - "log" - - _ "net/http/pprof" - - "bitbucket.org/lightcodelabs/caddy2" + caddycmd "bitbucket.org/lightcodelabs/caddy2/cmd" // this is where modules get plugged in _ "bitbucket.org/lightcodelabs/caddy2/modules/caddyhttp" _ "bitbucket.org/lightcodelabs/caddy2/modules/caddyhttp/caddylog" + _ "bitbucket.org/lightcodelabs/caddy2/modules/caddyhttp/reverseproxy" _ "bitbucket.org/lightcodelabs/caddy2/modules/caddyhttp/staticfiles" + _ "bitbucket.org/lightcodelabs/caddy2/modules/caddyhttp/staticresp" _ "bitbucket.org/lightcodelabs/caddy2/modules/caddytls" - _ "bitbucket.org/lightcodelabs/dynamicconfig" - _ "bitbucket.org/lightcodelabs/proxy" ) func main() { - err := caddy2.StartAdmin("127.0.0.1:1234") - if err != nil { - log.Fatal(err) - } - defer caddy2.StopAdmin() - - select {} + caddycmd.Main() } -- cgit v1.2.3