Daniel
04/02/2024, 9:15 AMMarvin
04/02/2024, 9:16 AMbash
prefect work-pool update --base-job-template base-job-template.json my-work-pool
When you manually update the base job template through the Prefect UI, that change might not be automatically reflected in your Kubernetes configuration. It is important to synchronize your changes from the UI back to your Kubernetes files or infrastructure as code.
Advanced customization of the base job template is possible for Kubernetes workers by editing work pools in the UI under the 'Advanced' tab, or by using the CLI as shown above.
Always ensure that your kubectl
command-line tool is available and properly configured, as it's required for operations involving Kubernetes.
For more details, you can refer to the Prefect documentation on work pools and Kubernetes infrastructure:
- Work Pools
- InfrastructureDaniel
04/02/2024, 9:17 AMMarvin
04/02/2024, 9:17 AMttlSecondsAfterFinished
.
However, troubleshooting this issue typically involves the following steps:
1. Verify that the ttlSecondsAfterFinished
field is correctly set in your job specification.
2. Ensure that the Kubernetes version you're using supports this feature (it's available since Kubernetes v1.12).
3. Check for any errors or events related to the job using kubectl describe job <job-name>
and kubectl get events
.
4. Ensure that the Kubernetes cluster roles and service accounts have appropriate permissions to delete jobs.
5. Make sure there's no configuration overriding or ignoring the ttlSecondsAfterFinished
field within your deployment configuration or workflow controller.
If you continue to experience issues, you may want to check the Kubernetes documentation or reach out to the Kubernetes community for further assistance. Additionally, you can manually clean up completed jobs using kubectl delete job <job-name>
.
For any Prefect-specific configuration or cleanup, refer to the Prefect Deployment Guide or Prefect Infrastructure Concepts. If the problem persists, consider filing an issue with the Prefect GitHub repository for further investigation.