Getting started

Getting started #

This guide will walk you through serving static files.

Configuration #

The following is a minimal configuration built into fasthttpd.

host: localhost
listen: ':8080'
root: ./public
log:
  output: stderr

handlers:
  'static':
    type: fs
    indexNames: [index.html]

routes:
  - path: /
    handler: static

Start fasthttpd #

Start fasthttpd with a partial overwrite of the built-in configuration. Then you can hit http://localhost:8080/ in your browser.

fashttpd -e root=.

Or specify your configuration file.

fashttpd -f config.yaml