Skip to content

AtmegaBuzz/weebserver

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation


webserver

A Simple implementation of a Static webserver from scratch. being a simple implementation it can handle routes and status code.

Setup

Setup tutorial on youtube

Build the server

    make

.config for server configurations

The website which is going to be hosted should conatin .config file. Example

    /* 
    server_ip = 192.168.0.4;
    port = 80;
    routes:
        {route1,<html filepath1>}
        {route2,<html filepath2>}
    */
     
    routes: // example 
        {/,index.html};
        {/about,about.html};
        {/contact,contact.html};

Host a static site

    ./webserver --host <website folder path>