Questions tagged [kubernetes-cronjob]

301 questions
0
votes
1 answer

Passing annotation to scheduled task in spring cloud dataflow

I am running SCDF on Kubernetes and have scheduled some tasks. I have to pass annotations to my tasks. I have given the following annotations in env: - name: SPRING_CLOUD_DEPLOYER_KUBERNETES_POD_ANNOTATIONS value: - name:…
0
votes
2 answers

How do I mail the output of a kubernetes cronjob?

I've setup a cronjob in Openshift. I can see its logs through the Web Console but I want to receive a mail containing the output of the job whenever it completes. How do I go about implementing this?
vatsal
  • 109
  • 2
  • 12
0
votes
1 answer

kubernetes cron job which should run every 10mins and should delete the pods which are in "Terminating" state in all the namespaces in the cluster?

kubernetes cron job which should run every 10mins and should delete the pods which are in "Terminating" state in all the namespaces in the cluster? please help me out....am struggling with the bash one liner shell script apiVersion: batch/v1 …
0
votes
1 answer

Getting bad minute error from crontab despite seemingly accurate syntax

Not sure what's going on as this cronjob is pretty straighforward. I want my cronjob to run every 5 minutes. Below is the script (memory.sh) in it's entirety. Below that is the schedule it's requested to run on via the crontab. I've replicated the…
NealR
  • 10,189
  • 61
  • 159
  • 299
0
votes
1 answer

Cron Job in Cpanel - Timezone issue

I have a php file which works fine in browser as well as in cron job section. The only thing i am facing is the timezone which i want to run that cron is not syncing with the server timezone. I want to run the cron job in indian timezone everyday…
Durgaprasad
  • 323
  • 2
  • 14
0
votes
1 answer

Environment Variables inside a Cronjob in Kubernetes

I have a nodejs application that runs every month and fetches data from an external database. It has some environment variables. Can I run this as a Cronjob in Kubernetes and is it possible to define env variables and also source the env variable…
Anshul Tripathi
  • 529
  • 2
  • 11
  • 28
0
votes
1 answer

Change the LAST SCHEDULE date format on Kubernetes CronJob

I'm reading the documentation and is not clear how change the format of the LAST-SCHEDULE date column. For me, is returning an approximation in hours (4h): kubectl get cronjob job-one NAME SCHEDULE SUSPEND ACTIVE LAST SCHEDULE …
Dherik
  • 17,757
  • 11
  • 115
  • 164
-1
votes
0 answers

Monitor and alert for kubernetes jobs created by cronjob

problem and the question the question has been asked and answered here Monitor Kubernetes Cronjob and there are a couple great writeups on the web Prometheus: K8s Cronjob alerts and i do not like making this separate thread but i can not provide…
-1
votes
1 answer

Recovery loop in kubernetes fixed to 6 minutes

Here is the case, i'm currentlly have a lot of cronjob triggered each hours. In order not to take all my cluster resources, the pod described to the cronjob is quota restricted to 15 pods in parallel. It works fine, but when all my pods are finished…
-1
votes
1 answer

Kubernetes Job that can restart a pod or rollout restart deployment

I have containerized app running on kubernetes which has volume mounted to efs. The volume contains a directory that gets updated with files on a periodic basis(eg. monthly). The update of files(zip and upzip) can be done by a CronJob. It's a big…
alltej
  • 6,787
  • 10
  • 46
  • 87
-1
votes
2 answers

Using aws-cli in cronjob

I'm trying to run aws sts get-caller-identity in a cronjob, however this results in /bin/sh: 1: aws: not found spec: containers: - command: - /bin/sh - -c - aws sts get-caller-identity
-1
votes
1 answer

How to create a Cronjob in spinnaker

I created a cronJob using kubectl. I would like to manage this job using spinnaker but i cant find my created job in spinnaker. I created the file running "kubectl create -f https://k8s.io/examples/application/job/cronjob.yaml" This cronjob looks…
mgg
  • 321
  • 1
  • 2
  • 10
-2
votes
0 answers

Bash script error - SMTP server value is an invalid alias name'"

I have a Bash Script to send email which is excuted via Kubernetes CronJob but when the job runs the email is not being sent as in the error log below : kubectl -n labs logs send-mail-28210503--1-grtpv bin dev mail.sh etc home lib media mnt opt…
Golide
  • 835
  • 3
  • 13
  • 36
-2
votes
1 answer

Job not running on scheduled time - Kubernetes CronJob

Cronjobs are not running any job on its scheduled times, the jobs runs only when one or more cronjobs are deleted. Is there some cronjob number limit ? Where to get log messages of this problem? EDIT: I have exactly the same environment for…
caslurjf
  • 1
  • 2
-2
votes
1 answer

How to create kubernetes job/cronjob which will run continuously

I have a kubernetes job. I want to execute this job continuously . Like 1st will run, it will take around 10 or 15 minutes to complete. Then it will wait for 2 minutes. again same job will be triggered. like that it continue. Is there any to way to…
Baitanik
  • 63
  • 1
  • 7
1 2 3
20
21