Skip to content

hermanho/curl-every-10seconds

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

curl-every-10seconds

MicroBadger

Alpine-based image with just curl and run every 10 seconds within 1 minute

Usage

Create a yaml file "cron.yaml" such as:

apiVersion: batch/v1beta1
kind: CronJob
metadata:
  name: cronjob1
spec:
  schedule: "*/1 * * * *"
  jobTemplate:
    spec:
      template:
        spec:
          containers:
            - name: cronjob1
              image: hermanho/curl-every-10seconds
              args:
                - -s
                - https://www.google.com/
          restartPolicy: OnFailure

Execute the following command to deploy

$ kubectl apply -f cron.yaml