Heya! Is there a way I could easily run a docker c...
# ask-community
d
Heya! Is there a way I could easily run a docker container as an op locally? I've tried with the docker executor but I'm struggling to find examples. I might be confusing terms (executors vs ops vs jobs ...) too. I'm trying to port some Argo tasks (docker images) to Dagster and want to try things locally.
d
Hi David - to confirrm this is a Docker container that isn't running Dagster Python code? We're just in the process of adding a docker_container_op (similar to k8s_job_op: https://docs.dagster.io/_apidocs/libraries/dagster-k8s#dagster_k8s.k8s_job_op) - that will probably be ready in the release next week due to an offsite happening this week
d
awesome! that's exactly what I was looking for 🙂
as I'm coming from Argo. I was planing on using the k8s op on prod and the Docker one on dev. Does that makes sense?
d
that could work, yeah - although both of those ops lose some of the benefits of dagster since you don't really end up taking advantage of the programming model
d
I know 😕 The thing is we have a bunch of potential ops already Dockerized and working
My plan was to try Dagster as an Argo replacement and then iterativelly move towards SDAs in the places we can
👍 1
d
you could even get fancier and write your own op that selectively calls execute_docker_container vs. execute_k8s_job depending on configuration on the op
d
the main "issue" is that we have a bunch of non Python tasks that can't work on Dagster
d
that makes sense and is a reasonable use case for those ops
d
sweet! I'll test the new Docker op when it comes out
tbh I'm still wrapping my head around all the Dagster concepts
I come from simple Dockerfiles cronjobed in Argo 🙈
Do you know anyone or a project that went through this migration?
d
There are a fair amount of users using k8s_job_op for this purpose, yeah - it's the main reason we added it
d
awesome to know! wouldn't like ot be the only weird one using that approach
alright, thanks a lot @daniel! this is super helpful 🙂 I'm excited for the next release. Enjoy the offsite
condagster 1