Created
June 21, 2018 12:42
-
-
Save alexellis/dfa1b8790ac3d26614e342746c64cbc8 to your computer and use it in GitHub Desktop.
Jenkins cron job to run an OpenFaaS function every minute
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pipeline { | |
agent any | |
triggers { cron('* * * * *') } | |
stages { | |
stage('Invoke') { | |
steps { | |
sh "curl -sL https://github.com/openfaas/faas-cli/releases/download/0.6.10/faas-cli > faas-cli" | |
sh "chmod +x faas-cli" | |
sh "echo Jenkins! | ./faas-cli invoke --gateway http://192.168.0.35:8080 figlet" | |
} | |
} | |
} | |
} | |
Author
alexellis
commented
Jun 21, 2018
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment