MCPcopy Index your code
hub / github.com/eliben/static-server

github.com/eliben/static-server @v1.4.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release v1.4.0 ↗ · + Follow
14 symbols 37 edges 3 files 6 documented · 43% 5 cross-repo links
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Go


static-server

Simple static file server, with support of HTTP and HTTPS. Useful for local testing of web applications.

There are no configuration files and no dependencies (except one for testing). Serving the current directory on HTTP port 8080 is as simple as invoking:

$ go run github.com/eliben/static-server@latest
<timestamp> Serving directory "." on http://127.0.0.1:8080

If you want to install static-server locally first, you can run:

$ go install github.com/eliben/static-server@latest

And then invoke static-server as needed. Command-line flags can be used to configure the behavior of the server:

$ static-server -h
Usage: ./static-server [dir]

  [dir] is optional; if not passed, '.' is used.

  By default, the server listens on localhost:8080. Both the
  host and the port are configurable with flags. Set the host
  to something else if you want the server to listen on a
  specific network interface. Setting the port to 0 will
  instruct the server to pick a random available port.

  -addr string
        full address (host:port) to listen on; don't use this if 'port' or 'host' are set (default "localhost:8080")
  -certfile string
        TLS certificate file to use with -tls (default "cert.pem")
  -cors
        enable CORS by returning Access-Control-Allow-Origin header
  -host string
        specific host to listen on (default "localhost")
  -keyfile string
        TLS key file to use with -tls (default "key.pem")
  -port string
        port to listen on; if 0, a random available port will be used (default "8080")
  -silent
        suppress messages from output (reporting only errors)
  -tls
        enable HTTPS serving with TLS
  -version
        print version and exit

Core symbols most depended-on inside this repo

Main
called by 1
internal/server/server.go
flagsSet
called by 1
internal/server/server.go
serveLogger
called by 1
internal/server/server.go
enableCORS
called by 1
internal/server/server.go
enableCOOP
called by 1
internal/server/server.go
main
called by 0
main.go

Shape

Function 14

Languages

Go100%

Modules by API surface

main_test.go8 symbols
internal/server/server.go5 symbols
main.go1 symbols

For agents

$ claude mcp add static-server \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact