~rostiger/merveilles_stickers

Websitie for Merveilles Stickers
Updated header
Fixed skipping last json dataset
Generalized json string parsing step

refs

main
browse  log 

clone

read-only
https://git.sr.ht/~rostiger/merveilles_stickers
read/write
git@git.sr.ht:~rostiger/merveilles_stickers

You can also use your local clone with git send-email.

#Merveilles Stickers

This website uses mould to generate a binary that runs on the webserver.
The bin generates the HTML code and stores the form data as a json file.

#Setup

Clone this repo, enter its root directory and clone the mould repo into it.

IMPORTANT: Open the mould-it bash script file and edit the $ROOT_PATH variable to reflect the location of the root repository.

Save the file and run ./mould-it to build the website.
All output files will be located in a dst directory.

Use ./mould-it -s to serve the page locally (default localhost:7272)

#Deployment

The website is hosted on Uberspace and the setup procedure is specific to their toolchain and server configuration options.

First, setup the subdomain stickers.yourdomain.com with your domain hosting service.

To make the website available at a specific location you need to add a reverse proxy rule on the webserver to direct queries to the running server binary. To do so, connect to the webserver using ssh and use the Uberspace web backend to add an nginx configuration option:
uberspace web backend set stickers.yourdomain.com --http --port 7272

Check if the settings have been applied correctly with cat /readonly/username/nginx.conf

Upload the binary generated by Mould to your webhost's bin directory. Run the binary and visit stickers.yourdomain.com to check if the page is being loaded and the form submission works.

To keep the server binary running use tmux in your ssh shell:
tmux new-session -s merveilles-stickers
Enter the bin directory if it's not the current working directory:
cd /home/rostiger/bin
Now execute the binary:
./mould-merveilles-stickers

Press ctrl-b and d to detach from the session.

To check in on the running server binary attach the session again with
tmux attach-session -t merveilles-stickers