- Python 98.8%
- Dockerfile 1.2%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
| app | ||
| tests | ||
| .env.example | ||
| compose.yaml | ||
| Dockerfile | ||
| pytest.ini | ||
| README.md | ||
| requirements-dev.txt | ||
| requirements.txt | ||
Deltion → Nextcloud ICS Calendar Bridge
A small read-only service that converts the Deltion timetable into a standard .ics calendar feed for Nextcloud and other calendar apps.
Deltion API → Python service → cached .ics → Nextcloud Calendar
Designed for LAN use with Docker Compose/Dockge.
Features
- Deltion timetable →
.ics - Nextcloud calendar subscriptions
- Per-group and per-week caching
- Background refresh without blocking calendar requests
- Automatic week rollover
- Stable event UIDs
- Optional group allow-list
- Fast
/healthendpoint
Installation
Docker Compose / Dockge
- Copy the project to your Docker/Dockge stacks directory.
- Copy
.env.exampleto.envand configure it. - Start the stack.
The service runs on port 8000.
Check:
http://<host>:8000/health
Calendar URL
The group is specified in the URL:
http://<host>:8000/calendar/GT41B.ics
Example groups:
/calendar/GT41B.ics
/calendar/GT42A.ics
Add the URL to Nextcloud using Calendar → New calendar → Subscribe from URL.
Configuration
| Variable | Default | Description |
|---|---|---|
DELTION_GROUP |
GT41B |
Group preloaded at startup |
WEEKS_AHEAD |
8 |
Weeks cached into the future |
WEEKS_BEHIND |
1 |
Weeks cached into the past |
CURRENT_WEEK_REFRESH_MINUTES |
5 |
Current week refresh interval |
NEXT_WEEK_REFRESH_MINUTES |
15 |
Next week refresh interval |
FUTURE_WEEK_REFRESH_MINUTES |
30 |
Future week refresh interval |
PREVIOUS_WEEK_REFRESH_MINUTES |
30 |
Previous week refresh interval |
MAX_CONCURRENT_REFRESHES |
3 |
Maximum simultaneous Deltion requests |
ALLOWED_GROUPS |
unset | Optional comma-separated group allow-list |
DELTION_BASE_URL |
https://roosters.deltion.nl |
Deltion base URL |
HTTP_TIMEOUT |
10 |
HTTP timeout in seconds |
DELTION_COOKIE |
unset | Optional Deltion session cookie |
LOG_LEVEL |
INFO |
Logging level |
Caching
Calendar requests never contact Deltion directly. Cached weeks are refreshed in the background.
Default refresh intervals:
- Previous week: 30 min
- Current week: 5 min
- Next week: 15 min
- Further future: 30 min
Cache is stored in memory and is rebuilt after a restart.
If a refresh fails, the previous cached data is kept.
Health
GET /health
Shows cache status and refresh information.
GET /health?check_upstream=true
Also checks whether Deltion is reachable.
Security
The service has no authentication by default and is intended for LAN use.
If exposed outside your LAN, set ALLOWED_GROUPS to prevent arbitrary group codes from being tracked and requested.
DELTION_COOKIE, if used, should be treated as a secret and never committed to Git.
Development
Install dependencies:
pip install -r requirements.txt
Run:
uvicorn app.main:app --host 0.0.0.0 --port 8000
Run tests:
pip install -r requirements-dev.txt
pytest -q