This is a simple shift management system. Built and maintained by students from the self-governed student dormitory HaDiKo.
This Project enables you to track Shift participation for multiple concurrent Organizations.
A Shift can either be created manually, based on a template or regularly with the use of a recurring shifts and shift templates. A Shift template is also capable of creating multiple shifts at once.
We plan on adding functionality for managing a high density of Shifts in a short time frame. For example a 2 or 3 day event like a LAN Party.
This section describes a quick local setup for development or testing out the software running and getting accessed on a single PC.
Start by cloning the repository and change your working directory to it:
git clone https://github.com/HaDiNet/shiftings
cd shiftings
This software depends on python and its package index. The pip dependencies are listed in pyproject.toml.
You can manage your (virtual) python environment for this project using venv and pip. Make sure they are installed on your system and run the following setup commands:
python -m venv venv
source venv/bin/activate # Linux, BSD, MacOS
# venv\Scripts\activate # Windows
pip install .
Make sure to activate your venv (second line above) in every shell you want to interact with your venv. Some IDEs do this automatically for you.
By running src/manage.py
you can run Django commands and do administration.
The project settings are already setup for development mode (DEBUG = True
). Feel free to have a look at the settings or adapt them to your needs. If you just want to try out the software, no action is required.
The script setup_db.sh initializes your database with the schema matching the shiftings models (running manage.py migrate
) and loading the fixtures providing example data. Execute it for having a local database:
sh setup_db.sh
Django provides a simple development server supporting live reload on code change. You can run it with the following command:
python src/manage.py runserver
After that you can access your local shiftings instance at http://127.0.0.1:8000/.
In development mode you can switch between the pre-defined user fixtures with a button in the context menu at the top right of the web page or you can login using the lower case name as username and password (bob
, perry
etc.). Bob is a superuser and has access to the Django admin page and Perry is a staff member. The other users have different access to the first example organization provided by the fixture. Follow the provided links for more info.
View the Django documentation for upgrading Django projects. After switching to an newer version, make sure there are no warnings or errors by running
python -W all src/manage.py check --deploy
This section describes a shared setup deployed on a server for common use in an organization.
See Django docs for details on how to deploy a Django application.
- Clone the repository
- Configure your WSGI Server
- Add a local_settings.py. See local_settings.sample.py for inspiration.
- Add a cron, systemd timer unit or similar for recurring shift creation
This project is licensed under the MIT License - see the LICENSE file for details