1.2 KiB
1.2 KiB
zetikettes
ouaich.
Initial setup
docker build -t zetikettes .
sudo mkdir -p /etc/docker/compose/zetikettes
sudo cp docker-compose.yml /etc/docker/compose/zetikettes/
sudo systemctl enable --now docker-compose@zetikettes
Nginx is configured to:
- redirect /zetikettes/srv/ to localhost:8000
- redirect /zetikettes/ to /var/lib/zetikettes/static
Conf is in /etc/nginx/sites-available/default
Test
docker run --rm -it -v $PWD/templates:/data zetikettes /bin/bash /root/zetikettes/old/mkjam.sh
This should produce a .pdf in templates/
. Open it to check that
layout & fonts are correct.
Run
docker-compose up
Notes for deploying
.h3 Initialize empty database
python manage.py migrate
.h3 Prepare static files
python manage.py collectstatic
The files will be in www_static/
and need to be moved to /var/lib/zetikettes/www_static
.h3 Change host settings
If not deploying on aerith.ponteilla.net
, you'll need to edit backend/zetikettes/zetikettes/settings.py
to change a couple things in there.
Change available templates
- go to /zetikettes/admin
- add the newtikette
- still no need to restart the container (magic!)
- profit.