Skip to content

josephlaw/simplehttp2server

 
 

Repository files navigation

simplehttp2server serves the current directory on an HTTP/2.0 capable server. This server is for development purposes only.

Push Manifest

simplehttp2server supports the push manifest. All requests will be looked up in a file named push.json. If there is a key for the request path, all resources under that key will be pushed.

Example push.json:

{
  "index.html": {
    "/css/app.css": {
      "type": "style",
      "weight": 1
    },
    // ...
  },
  "page.html": {
    "/css/page.css": {
      "type": "style",
      "weight": 1
    },
    // ...
  }
}

Support for weighting those pushes is not yet implemented.

TLS Certificate

Since HTTP/2 requires TLS, simplehttp2server checks if cert.pem and key.pem are present. If not, a self-signed certificate will be generated.

Download

simplehttp2server is go get-able:

$ go get github.com/GoogleChrome/simplehttp2server

Precompiled binaries can be found in the release section.

License

Apache 2.

About

A simple HTTP/2 server for development

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Go 99.8%
  • Other 0.2%