[Unit]
Description=RSS2 Categorizer Worker (Python)
After=network.target postgresql.service
Requires=postgresql.service

[Service]
Type=simple
User=rss2
Group=rss2
WorkingDirectory=/opt/rss2/src
EnvironmentFile=/opt/rss2/.env
Environment=CATEGORIZER_BATCH_SIZE=10
Environment=CATEGORIZER_SLEEP_IDLE=5
ExecStart=/opt/rss2/venv/bin/python -m workers.simple_categorizer_worker
Restart=always
RestartSec=10
StandardOutput=journal
StandardError=journal
SyslogIdentifier=rss2-categorizer

MemoryMax=1G
CPUQuota=200%

[Install]
WantedBy=multi-user.target
