Nicholas
05/30/2023, 4:24 PMdeployment.yaml
for my project:
deployments:
- name: my-kubernetes
version: "0.0.1"
entrypoint: demo.py:run_demo_prefect
infrastructure:
type: kubernetes-job
image: "docker-repository-url/image-name:tag"
work_pool:
name: default
work_queue_name: default
The worker correctly runs the deployment in a new Kubernetes Job, yet using the default Prefect image instead of the one I have specified. What I’m missing?alex
05/30/2023, 4:33 PMinfrastructure
that the prefect deploy command does not recognize. Instead, you can specify your custom image under work_pool
like so:
work_pool:
name: default
work_queue_name: default
job_variables:
image: "docker-repository-url/image-name:tag"
If you’re using the build_docker_image
step you can use the output from that step to automatically populate that field like this:
work_pool:
name: default
work_queue_name: default
job_variables:
image: "{{ image_name }}"
Nicholas
05/30/2023, 4:49 PM