Hello Dagster Team, looking for some help with a m...
# ask-community
s
Hello Dagster Team, looking for some help with a multi container deployment. I'm using docker-compose to build and run jobs following the example here https://github.com/dagster-io/dagster/tree/0.14.17/examples/deploy_docker. What I would like to figure out is how to setup an additional user code container and be able to use this when launching specific jobs. Following the comments in the docker-compose setup it seems possible but unsure of how to launch a job to a specific user code container. Thanks in advance!
Would the config be at the job level? I see in the docs here an executor_def can be provided. https://docs.dagster.io/_apidocs/libraries/dagster-docker#dagster_docker.docker_executor
z
I think what you're looking for is in the
workspace.yaml
file. I just added the second user code container as another
grpc_server
entry like this:
Copy code
load_from:
  # Each entry here corresponds to a service in the docker-compose file that exposes user code.
  - grpc_server:
      host: user_code1
      port: 4000
      location_name: "lib1"
  - grpc_server:
      host: user_code2
      port: 4001
      location_name: "lib2"
the docker hosts don't necessarily have to be managed in the same docker compose file (although it's a lot cleaner that way), the user code container just needs to be running in the same docker network
s
Thanks, that seems to be working!
🎉 1