Currently the server can host static websites without a backend and I may update the project to add backend support and some other features listed in todo.txt.
The project is programmed purely in C and natively supports Linux, no external libraries have been used and only require C standard libraries and Linux headers. It uses the HTTP 1.1 specification.
It can be used cross-platform using Docker.
First clone the repository and compile using the Makefile. Run the generated server binary, you can optionally specifiy the directory to host as a command line argument otherwise it hosts the directory the binary is inside. By default the server binds to 0.0.0.0 on port 8000 which can be changed inside server.c and recompiling.
Download the Dockerfile and build it into a Docker image, then use the generated image to run a container with docker run -p <port>:8000 -v "<directory>:/server/data" <generated-image-name>,
portis the port to host the server on for the host,directoryis where the files are to be hosted,generated-image-nameis the name you gave the Docker image when you built it.
Once running the server will be hosted on 0.0.0.0 at the port you gave it.
The server by default hosts the root target (/) with /index.html so by going to 0.0.0.0:8000 is essentially the same as 0.0.0.0:8000/index.html, this can be modified by changing TARGET_ROOT_TARGET inside target.c.
Here is a demo of the server hosting my personal website: