Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
对于已部署的 Kubernetes CronJob foo,如何立即手动运行?这将用于在其配置的计划之外进行测试或手动运行。
foo
您可以根据现有作业的配置启动作业,而 cronjob 只是另一种类型的作业。
句法: kubectl create job --from=cronjob/$CronJobName $NameToGiveThePodThatWillBeCreated
kubectl create job --from=cronjob/$CronJobName $NameToGiveThePodThatWillBeCreated
例如: kubectl create job --from=cronjob/foo foo-manual-1
kubectl create job --from=cronjob/foo foo-manual-1