Sign inSign up

leafsoar/http

By leafsoar

Updated almost 10 years ago

http file server by golang

Image
0

371

leafsoar/http repository overview

default port: 8000 default path: /pub

docker run --rm -v $PWD:/pub -p 8000:8000 leafsoar/http

package main

import "net/http"

func main() {
	http.Handle("/", http.FileServer(http.Dir("/pub")))
	err := http.ListenAndServe(":8000", nil)
	if err != nil {
		panic("Error: " + err.Error())
	}
}

Tag summary

Content type

Image

Digest

sha256:4b3dd0cfa

Size

1.4 MB

Last updated

almost 10 years ago

docker pull leafsoar/http