fix(honcho/deriver): invoke package main (src.deriver) not module file
src/deriver/deriver.py is a helpers module with no __main__ guard — running it directly loads it and exits cleanly in ~3s with no logs, which is what we were seeing. The actual queue-processor entry point is src/deriver/__main__.py (asyncio.run(run_deriver())), invoked via "python -m src.deriver". Discovered during honcho first-deploy on lincoln: deriver container crash-looped (in the sense that systemd restarted it constantly) but the underlying process was actually exiting 0 on completion of the empty helpers module.
This commit is contained in:
@@ -21,7 +21,7 @@ Network={{ honcho_network_name }}
|
|||||||
# polls the queue and processes work in a loop. Number of concurrent
|
# polls the queue and processes work in a loop. Number of concurrent
|
||||||
# workers controlled via DERIVER_WORKERS.
|
# workers controlled via DERIVER_WORKERS.
|
||||||
WorkingDir=/app
|
WorkingDir=/app
|
||||||
Exec=/app/.venv/bin/python -m src.deriver.deriver
|
Exec=/app/.venv/bin/python -m src.deriver
|
||||||
|
|
||||||
# -- Database ---------------------------------------------------------------
|
# -- Database ---------------------------------------------------------------
|
||||||
Environment=DB_CONNECTION_URI=postgresql+psycopg://{{ honcho_db_user }}:{{ honcho_db_password }}@{{ honcho_postgres_container_name }}:5432/{{ honcho_db_name }}
|
Environment=DB_CONNECTION_URI=postgresql+psycopg://{{ honcho_db_user }}:{{ honcho_db_password }}@{{ honcho_postgres_container_name }}:5432/{{ honcho_db_name }}
|
||||||
|
|||||||
Reference in New Issue
Block a user