You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Jenkinsfile 543B

123456789101112131415161718192021222324252627282930313233
  1. pipeline {
  2. agent any
  3. stages {
  4. stage('Init') {
  5. steps {
  6. sh '''export PATH=$PATH:/var/jenkins_home
  7. terraform init'''
  8. }
  9. }
  10. stage('Plan') {
  11. steps {
  12. sh '''export PATH=$PATH:/var/jenkins_home
  13. terraform plan'''
  14. }
  15. }
  16. stage('Apply') {
  17. steps {
  18. sh '''export PATH=$PATH:/var/jenkins_home
  19. terraform apply -auto-approve'''
  20. }
  21. }
  22. stage('Destroy') {
  23. steps {
  24. sh '''export PATH=$PATH:/var/jenkins_home
  25. terraform destroy -auto-approve'''
  26. }
  27. }
  28. }
  29. }