Hi Prefect Team,We have a prefect-server running on a Kubernetes cluster and just updated to
. As environments are being deprecated I am trying to move the flows over to run_config setup.I am using the Docker storage and KubernetesRun for run_config. I noticed that the container that is built with
but when I inject a job spec file withKubernetesRun(job_template_path="job_specs.yaml") (as I need to to access the Kubernetes secrets that I need for the flow to run) only the
are written by the prefect build and the
is left blank. That leads to the container failing with an
"executable not found"
A workaround is to specifically include the
section in the job specs file
command: ["/bin/sh", "-c"]
.That doesn’t seem to be expected behaviour, or am I missing something?
1 year ago
Hey @Clemens I believe this is actually intentional (although it could probably be improved) in the default job template it sets the
and I think that by using a custom job template it is assuming you have the command set. I’m going to open an issue on the repo to verify if that is intended behavior and if it is I think we might be able to make the experience better 🙂
@Marvin open “executable not found when not setting
I think a link in the docs to the default specs would already help a lot
1 year ago
Awesome this is actually already included in a new set of enhancements coming to the docs (for agent related stuff, perhaps it could be added to the KubernetesRun as well) https://github.com/PrefectHQ/prefect/pull/3786 that has an open PR now!