The Servala Self-Service Portal
Find a file
2025-03-16 09:23:38 +01:00
.forgejo configure automated container build action 2025-03-07 09:26:57 +01:00
docker Docker: Provide working directory for gunicorn 2025-03-07 15:57:49 +01:00
src Make sure `createuser and createsuperuser` work 2025-03-16 09:23:38 +01:00
.dockerignore initialize docker build 2025-03-07 09:16:24 +01:00
.env.example Docs + default origin setting 2025-03-16 09:23:38 +01:00
.gitignore Initial commit 2025-03-03 15:26:47 +00:00
.pre-commit-config.yaml add a pre-commit configuration 2025-03-07 09:21:48 +01:00
.python-version uv + Django[postgres] installation 2025-03-05 10:44:16 +01:00
Dockerfile initialize docker build 2025-03-07 09:16:24 +01:00
LICENSE Initial commit 2025-03-03 15:26:47 +00:00
pyproject.toml Add Pillow for ImageFields 2025-03-16 09:23:38 +01:00
README.md document docker usage 2025-03-07 16:58:54 +01:00
uv.lock Add Pillow for ImageFields 2025-03-16 09:23:38 +01:00

Servala Portal

The Servala Self-Service Portal

Development setup

First, copy the .env.example file to .env and adjust the settings to your needs. Make sure to source the file before running any commands.

Then use uv to install the project and run its commands while youre developing:

uv sync --dev
uv run src/manage.py migrate
uv run src/manage.py runserver

This will start the development server on http://localhost:8000.

Configuration

TODO

Code style and linting

Servala uses several linters / formatters to keep the project style consistent for you. Run them like this:

uv run black src/  # Code formatting; -c to just check
uv run isort src/  # Import ordering; -c to just check
uv run djlint src/ --reformat --format-js --format-css  # Format templates, JS and CSS, --check to just check
uv run flake8 src/  # Python linter

Docker

The project provides a Dockerfile which builds a production-ready container image. It uses Caddy to serve static files and connect to Gunicorn, the Python WSGI application server.

Building:

docker build -t local/servala-portal .

Running:

docker run --rm -ti -p 8080:8080 --name=servala-portal --rm --env-file .env local/servala-portal

TODO: Persistence

Testing

TODO