trying to setup a new docker compose and its not w...
# prefect-docker
k
trying to setup a new docker compose and its not working, it just exits after starting up.
n
that first env var for the db connection string doesnt look right, we dont have any settings that have double underscores
k
Just ran the one your provided and i get this error
n
thats because its referencing my file
work.py
instead of starting the worker process that I mentioned you'd want to swap this for in the other thread
youd want something like this instead
Copy code
worker:
    image: prefecthq/prefect:2-python3.11
    restart: always
    command: ["prefect", "worker", "start", "--pool", "your-pool"]
also it seems your image is perhaps a prefect 1 image?
--host
should be a valid flag for
prefect server start
in prefect 2.x
k
was using this https://hub.docker.com/r/prefecthq/prefect , thought it would have been the most up to date.
if i wanna use the most recent prefect, which docker image should i use? prefecthq/prefect:2-python3.12 ?
n
yep! thatd be latest prefect 2.x for 3.12