Skip to content

Instantly share code, notes, and snippets.

@willie
Created June 18, 2016 15:19
Show Gist options
  • Save willie/769c5ae6479c56ee35e280a380bd8bde to your computer and use it in GitHub Desktop.
Save willie/769c5ae6479c56ee35e280a380bd8bde to your computer and use it in GitHub Desktop.
getting error: "cannot create storage without CA URL"
package main
import (
"github.com/mholt/caddy"
// plug in the server
_ "github.com/mholt/caddy/caddyhttp"
"log"
)
func main() {
caddy.AppName = "Sprocket"
caddy.AppVersion = "1.2.3"
// pass in the name of the server type this Caddyfile is for (like "http")
caddyfile, err := caddy.LoadCaddyfile("http")
if err != nil {
log.Fatal(err)
}
instance, err := caddy.Start(caddyfile)
if err != nil {
log.Fatal(err)
}
// Start() only blocks until the servers have started.
// Wait() blocks until the servers have stopped.
instance.Wait()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment