diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..abb9d13 --- /dev/null +++ b/.gitignore @@ -0,0 +1,23 @@ +# Local .terraform directories +.terraform/ + +# Terraform state files +*.tfstate +*.tfstate.* + +# Crash logs +crash.log + +# Override files +override.tf +override.tf.json +*_override.tf +*_override.tf.json + +# Terraform lock file (optional) +# Commit if you want reproducible provider versions, otherwise ignore +.terraform.lock.hcl + +# Sensitive variable files +*.tfvars +*.tfvars.json diff --git a/0-bootstrap/.terraform.lock.hcl b/0-bootstrap/.terraform.lock.hcl deleted file mode 100644 index cdc1668..0000000 --- a/0-bootstrap/.terraform.lock.hcl +++ /dev/null @@ -1,25 +0,0 @@ -# This file is maintained automatically by "terraform init". -# Manual edits may be lost in future updates. - -provider "registry.terraform.io/hashicorp/aws" { - version = "5.100.0" - constraints = "~> 5.0" - hashes = [ - "h1:Ijt7pOlB7Tr7maGQIqtsLFbl7pSMIj06TVdkoSBcYOw=", - "zh:054b8dd49f0549c9a7cc27d159e45327b7b65cf404da5e5a20da154b90b8a644", - "zh:0b97bf8d5e03d15d83cc40b0530a1f84b459354939ba6f135a0086c20ebbe6b2", - "zh:1589a2266af699cbd5d80737a0fe02e54ec9cf2ca54e7e00ac51c7359056f274", - "zh:6330766f1d85f01ae6ea90d1b214b8b74cc8c1badc4696b165b36ddd4cc15f7b", - "zh:7c8c2e30d8e55291b86fcb64bdf6c25489d538688545eb48fd74ad622e5d3862", - "zh:99b1003bd9bd32ee323544da897148f46a527f622dc3971af63ea3e251596342", - "zh:9b12af85486a96aedd8d7984b0ff811a4b42e3d88dad1a3fb4c0b580d04fa425", - "zh:9f8b909d3ec50ade83c8062290378b1ec553edef6a447c56dadc01a99f4eaa93", - "zh:aaef921ff9aabaf8b1869a86d692ebd24fbd4e12c21205034bb679b9caf883a2", - "zh:ac882313207aba00dd5a76dbd572a0ddc818bb9cbf5c9d61b28fe30efaec951e", - "zh:bb64e8aff37becab373a1a0cc1080990785304141af42ed6aa3dd4913b000421", - "zh:dfe495f6621df5540d9c92ad40b8067376350b005c637ea6efac5dc15028add4", - "zh:f0ddf0eaf052766cfe09dea8200a946519f653c384ab4336e2a4a64fdd6310e9", - "zh:f1b7e684f4c7ae1eed272b6de7d2049bb87a0275cb04dbb7cda6636f600699c9", - "zh:ff461571e3f233699bf690db319dfe46aec75e58726636a0d97dd9ac6e32fb70", - ] -} diff --git a/0-bootstrap/main.tf b/0-bootstrap/main.tf index be3941d..c420850 100644 --- a/0-bootstrap/main.tf +++ b/0-bootstrap/main.tf @@ -1,10 +1,10 @@ resource "aws_s3_bucket" "tf_state" { - bucket = "quantamvector-infra-statefile-backup" + bucket = "laxmanraju-statefile-logs" } resource "aws_s3_bucket_versioning" "tf_state" { bucket = aws_s3_bucket.tf_state.id - + versioning_configuration { status = "Enabled" } @@ -30,7 +30,7 @@ resource "aws_s3_bucket_public_access_block" "tf_state" { } resource "aws_dynamodb_table" "tf_lock" { - name = "quantamvector-terraform-locks" + name = "laxmanraju-statefile-DB-lock" billing_mode = "PAY_PER_REQUEST" hash_key = "LockID" @@ -39,3 +39,5 @@ resource "aws_dynamodb_table" "tf_lock" { type = "S" } } + +//updated \ No newline at end of file diff --git a/0-bootstrap/providers.tf b/0-bootstrap/providers.tf index eaab0b6..2c5eab9 100644 --- a/0-bootstrap/providers.tf +++ b/0-bootstrap/providers.tf @@ -10,6 +10,6 @@ terraform { } provider "aws" { - region = "ap-northeast-1" + region = "us-east-1" } diff --git a/1-network/backend.tf b/1-network/backend.tf index e6d111b..c2a12d1 100644 --- a/1-network/backend.tf +++ b/1-network/backend.tf @@ -1,9 +1,20 @@ +# terraform { +# backend "s3" { +# bucket = "laxmanraju-state-lock" +# key = "laxmanraju/1-network/terraform.tfstate" +# region = "us-east-1" +# dynamodb_table = "laxmanraju-state-DB-1-lock" +# encrypt = true +# } +# } + terraform { backend "s3" { - bucket = "quantamvector-infra-statefile-backup" - key = "quantamvector/1-network/terraform.tfstate" - region = "ap-northeast-1" - dynamodb_table = "quantamvector-terraform-locks" - encrypt = true + bucket = "laxmanraju-statefile-logs" # your S3 bucket + key = "env/terraform.tfstate" + dynamodbdynamodb_table = "laxmanraju-statefile-DB-lock" # path inside the bucket + region = "us-east-1" + encrypt = true + use_lockfile = true # replaces dynamodb_table } } \ No newline at end of file diff --git a/1-network/providers.tf b/1-network/providers.tf index 564aab2..0318a4f 100644 --- a/1-network/providers.tf +++ b/1-network/providers.tf @@ -10,5 +10,5 @@ terraform { } provider "aws" { - region = "ap-northeast-1" -} \ No newline at end of file + region = "us-east-1" +} diff --git a/1-network/variables.tf b/1-network/variables.tf index b669d16..3e7090e 100644 --- a/1-network/variables.tf +++ b/1-network/variables.tf @@ -1,6 +1,6 @@ variable "project" { type = string - default = "quantamvector" + default = "microservices-v2" } variable "vpc_cidr" { @@ -10,5 +10,5 @@ variable "vpc_cidr" { variable "azs" { type = list(string) - default = ["ap-northeast-1a", "ap-northeast-1c", "ap-northeast-1d"] + default = ["us-east-1a", "us-east-1b"] } diff --git a/2-eks/.terraform.lock.hcl b/2-eks/.terraform.lock.hcl deleted file mode 100644 index 8e83589..0000000 --- a/2-eks/.terraform.lock.hcl +++ /dev/null @@ -1,105 +0,0 @@ -# This file is maintained automatically by "terraform init". -# Manual edits may be lost in future updates. - -provider "registry.terraform.io/hashicorp/aws" { - version = "5.100.0" - constraints = ">= 4.33.0, ~> 5.0, >= 5.95.0, < 6.0.0" - hashes = [ - "h1:Ijt7pOlB7Tr7maGQIqtsLFbl7pSMIj06TVdkoSBcYOw=", - "zh:054b8dd49f0549c9a7cc27d159e45327b7b65cf404da5e5a20da154b90b8a644", - "zh:0b97bf8d5e03d15d83cc40b0530a1f84b459354939ba6f135a0086c20ebbe6b2", - "zh:1589a2266af699cbd5d80737a0fe02e54ec9cf2ca54e7e00ac51c7359056f274", - "zh:6330766f1d85f01ae6ea90d1b214b8b74cc8c1badc4696b165b36ddd4cc15f7b", - "zh:7c8c2e30d8e55291b86fcb64bdf6c25489d538688545eb48fd74ad622e5d3862", - "zh:99b1003bd9bd32ee323544da897148f46a527f622dc3971af63ea3e251596342", - "zh:9b12af85486a96aedd8d7984b0ff811a4b42e3d88dad1a3fb4c0b580d04fa425", - "zh:9f8b909d3ec50ade83c8062290378b1ec553edef6a447c56dadc01a99f4eaa93", - "zh:aaef921ff9aabaf8b1869a86d692ebd24fbd4e12c21205034bb679b9caf883a2", - "zh:ac882313207aba00dd5a76dbd572a0ddc818bb9cbf5c9d61b28fe30efaec951e", - "zh:bb64e8aff37becab373a1a0cc1080990785304141af42ed6aa3dd4913b000421", - "zh:dfe495f6621df5540d9c92ad40b8067376350b005c637ea6efac5dc15028add4", - "zh:f0ddf0eaf052766cfe09dea8200a946519f653c384ab4336e2a4a64fdd6310e9", - "zh:f1b7e684f4c7ae1eed272b6de7d2049bb87a0275cb04dbb7cda6636f600699c9", - "zh:ff461571e3f233699bf690db319dfe46aec75e58726636a0d97dd9ac6e32fb70", - ] -} - -provider "registry.terraform.io/hashicorp/cloudinit" { - version = "2.3.7" - constraints = ">= 2.0.0" - hashes = [ - "h1:M9TpQxKAE/hyOwytdX9MUNZw30HoD/OXqYIug5fkqH8=", - "zh:06f1c54e919425c3139f8aeb8fcf9bceca7e560d48c9f0c1e3bb0a8ad9d9da1e", - "zh:0e1e4cf6fd98b019e764c28586a386dc136129fef50af8c7165a067e7e4a31d5", - "zh:1871f4337c7c57287d4d67396f633d224b8938708b772abfc664d1f80bd67edd", - "zh:2b9269d91b742a71b2248439d5e9824f0447e6d261bfb86a8a88528609b136d1", - "zh:3d8ae039af21426072c66d6a59a467d51f2d9189b8198616888c1b7fc42addc7", - "zh:3ef4e2db5bcf3e2d915921adced43929214e0946a6fb11793085d9a48995ae01", - "zh:42ae54381147437c83cbb8790cc68935d71b6357728a154109d3220b1beb4dc9", - "zh:4496b362605ae4cbc9ef7995d102351e2fe311897586ffc7a4a262ccca0c782a", - "zh:652a2401257a12706d32842f66dac05a735693abcb3e6517d6b5e2573729ba13", - "zh:7406c30806f5979eaed5f50c548eced2ea18ea121e01801d2f0d4d87a04f6a14", - "zh:7848429fd5a5bcf35f6fee8487df0fb64b09ec071330f3ff240c0343fe2a5224", - "zh:78d5eefdd9e494defcb3c68d282b8f96630502cac21d1ea161f53cfe9bb483b3", - ] -} - -provider "registry.terraform.io/hashicorp/null" { - version = "3.2.4" - constraints = ">= 3.0.0" - hashes = [ - "h1:L5V05xwp/Gto1leRryuesxjMfgZwjb7oool4WS1UEFQ=", - "zh:59f6b52ab4ff35739647f9509ee6d93d7c032985d9f8c6237d1f8a59471bbbe2", - "zh:78d5eefdd9e494defcb3c68d282b8f96630502cac21d1ea161f53cfe9bb483b3", - "zh:795c897119ff082133150121d39ff26cb5f89a730a2c8c26f3a9c1abf81a9c43", - "zh:7b9c7b16f118fbc2b05a983817b8ce2f86df125857966ad356353baf4bff5c0a", - "zh:85e33ab43e0e1726e5f97a874b8e24820b6565ff8076523cc2922ba671492991", - "zh:9d32ac3619cfc93eb3c4f423492a8e0f79db05fec58e449dee9b2d5873d5f69f", - "zh:9e15c3c9dd8e0d1e3731841d44c34571b6c97f5b95e8296a45318b94e5287a6e", - "zh:b4c2ab35d1b7696c30b64bf2c0f3a62329107bd1a9121ce70683dec58af19615", - "zh:c43723e8cc65bcdf5e0c92581dcbbdcbdcf18b8d2037406a5f2033b1e22de442", - "zh:ceb5495d9c31bfb299d246ab333f08c7fb0d67a4f82681fbf47f2a21c3e11ab5", - "zh:e171026b3659305c558d9804062762d168f50ba02b88b231d20ec99578a6233f", - "zh:ed0fe2acdb61330b01841fa790be00ec6beaac91d41f311fb8254f74eb6a711f", - ] -} - -provider "registry.terraform.io/hashicorp/time" { - version = "0.13.1" - constraints = ">= 0.9.0" - hashes = [ - "h1:ZT5ppCNIModqk3iOkVt5my8b8yBHmDpl663JtXAIRqM=", - "zh:02cb9aab1002f0f2a94a4f85acec8893297dc75915f7404c165983f720a54b74", - "zh:04429b2b31a492d19e5ecf999b116d396dac0b24bba0d0fb19ecaefe193fdb8f", - "zh:26f8e51bb7c275c404ba6028c1b530312066009194db721a8427a7bc5cdbc83a", - "zh:772ff8dbdbef968651ab3ae76d04afd355c32f8a868d03244db3f8496e462690", - "zh:78d5eefdd9e494defcb3c68d282b8f96630502cac21d1ea161f53cfe9bb483b3", - "zh:898db5d2b6bd6ca5457dccb52eedbc7c5b1a71e4a4658381bcbb38cedbbda328", - "zh:8de913bf09a3fa7bedc29fec18c47c571d0c7a3d0644322c46f3aa648cf30cd8", - "zh:9402102c86a87bdfe7e501ffbb9c685c32bbcefcfcf897fd7d53df414c36877b", - "zh:b18b9bb1726bb8cfbefc0a29cf3657c82578001f514bcf4c079839b6776c47f0", - "zh:b9d31fdc4faecb909d7c5ce41d2479dd0536862a963df434be4b16e8e4edc94d", - "zh:c951e9f39cca3446c060bd63933ebb89cedde9523904813973fbc3d11863ba75", - "zh:e5b773c0d07e962291be0e9b413c7a22c044b8c7b58c76e8aa91d1659990dfb5", - ] -} - -provider "registry.terraform.io/hashicorp/tls" { - version = "4.2.1" - constraints = ">= 3.0.0" - hashes = [ - "h1:akFNuHwvrtnYMBofieoeXhPJDhYZzJVu/Q/BgZK2fgg=", - "zh:0d1e7d07ac973b97fa228f46596c800de830820506ee145626f079dd6bbf8d8a", - "zh:5c7e3d4348cb4861ab812973ef493814a4b224bdd3e9d534a7c8a7c992382b86", - "zh:7c6d4a86cd7a4e9c1025c6b3a3a6a45dea202af85d870cddbab455fb1bd568ad", - "zh:7d0864755ba093664c4b2c07c045d3f5e3d7c799dda1a3ef33d17ed1ac563191", - "zh:83734f57950ab67c0d6a87babdb3f13c908cbe0a48949333f489698532e1391b", - "zh:951e3c285218ebca0cf20eaa4265020b4ef042fea9c6ade115ad1558cfe459e5", - "zh:b9543955b4297e1d93b85900854891c0e645d936d8285a190030475379c5c635", - "zh:bb1bd9e86c003d08c30c1b00d44118ed5bbbf6b1d2d6f7eaac4fa5c6ebea5933", - "zh:c9477bfe00653629cd77ddac3968475f7ad93ac3ca8bc45b56d1d9efb25e4a6e", - "zh:d4cfda8687f736d0cba664c22ec49dae1188289e214ef57f5afe6a7217854fed", - "zh:dc77ee066cf96532a48f0578c35b1eaf6dc4d8ddd0e3ae8e029a3b10676dd5d3", - "zh:f569b65999264a9416862bca5cd2a6177d94ccb0424f3a4ef424428912b9cb3c", - ] -} diff --git a/2-eks/backend.tf b/2-eks/backend.tf index dcca4af..af892a3 100644 --- a/2-eks/backend.tf +++ b/2-eks/backend.tf @@ -1,9 +1,10 @@ terraform { backend "s3" { - bucket = "quantamvector-infra-statefile-backup" - key = "quantamvector/2-eks/terraform.tfstate" - region = "ap-northeast-1" - dynamodb_table = "quantamvector-terraform-locks" + bucket = "laxmanraju-statefile-logs" + key = "laxmanraju/2-eks/terraform.tfstate" + region = "us-east-1" + dynamodb_table = "laxmanraju-statefile-DB-lock" + use_lockfile = true # replaces dynamodb_table encrypt = true } -} \ No newline at end of file +} diff --git a/2-eks/data.tf b/2-eks/data.tf index 533c278..3a63e75 100644 --- a/2-eks/data.tf +++ b/2-eks/data.tf @@ -2,8 +2,8 @@ data "terraform_remote_state" "network" { backend = "s3" config = { - bucket = "quantamvector-infra-statefile-backup" - key = "quantamvector/1-network/terraform.tfstate" - region = "ap-northeast-1" + bucket = "laxmanraju-statefile-logs" + key = "env/terraform.tfstate" + region = "us-east-1" } } diff --git a/2-eks/outputs.tf b/2-eks/outputs.tf index 0502f6b..2410276 100644 --- a/2-eks/outputs.tf +++ b/2-eks/outputs.tf @@ -11,5 +11,5 @@ output "cluster_certificate_authority_data" { } output "region" { - value = "ap-northeast-1" + value = "us-east-1" } diff --git a/2-eks/providers.tf b/2-eks/providers.tf index 56eadea..0318a4f 100644 --- a/2-eks/providers.tf +++ b/2-eks/providers.tf @@ -10,5 +10,5 @@ terraform { } provider "aws" { - region = "ap-northeast-1" + region = "us-east-1" } diff --git a/2-eks/variables.tf b/2-eks/variables.tf index ccfc33c..bfb12aa 100644 --- a/2-eks/variables.tf +++ b/2-eks/variables.tf @@ -1,6 +1,6 @@ variable "project" { type = string - default = "quantamvector" + default = "microservices-v2" } variable "kubernetes_version" { @@ -11,5 +11,5 @@ variable "kubernetes_version" { variable "ssh_key_name" { type = string description = "Name of the EC2 key pair for SSH access to worker nodes" - default = "Tokyo-key" + default = "Common" } diff --git a/Jenkinsfile b/Jenkinsfile index ea39eb2..741ba25 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -11,7 +11,7 @@ pipeline { environment { AWS_ACCESS_KEY_ID = credentials('AWS_ACCESS_KEY_ID') AWS_SECRET_ACCESS_KEY = credentials('AWS_SECRET_ACCESS_KEY') - AWS_DEFAULT_REGION = 'ap-northeast-1' + AWS_DEFAULT_REGION = 'us-east-1' } agent any @@ -22,7 +22,7 @@ pipeline { steps { script { dir('terraform') { - git url: 'https://github.com/QuntamVector/Infrastructure.git', branch: 'main' + git url: 'https://github.com/laxmanraju4144/Infrastructure.git', branch: 'main' } } } @@ -36,8 +36,8 @@ pipeline { sh 'cd terraform/0-bootstrap && terraform init -input=false' // Import existing resources into state if they already exist in AWS // '|| true' ensures pipeline does not fail if resource does not exist yet (first run) - sh 'cd terraform/0-bootstrap && terraform import aws_s3_bucket.tf_state quantamvector-infra-statefile-backup || true' - sh 'cd terraform/0-bootstrap && terraform import aws_dynamodb_table.tf_lock quantamvector-terraform-locks || true' + sh 'cd terraform/0-bootstrap && terraform import aws_s3_bucket.tf_state laxmanraju-statefile-logs || true' + sh 'cd terraform/0-bootstrap && terraform import aws_dynamodb_table.tf_lock laxmanraju-statefile-DB-lock || true' sh 'cd terraform/0-bootstrap && terraform plan -out tfplan' sh 'cd terraform/0-bootstrap && terraform show -no-color tfplan > tfplan.txt' } @@ -88,10 +88,18 @@ pipeline { } } + // stage('Plan: 2-eks') { + // when { expression { params.terraformAction == 'apply' } } + // steps { + // sh 'cd terraform/2-eks && terraform init -input=false' + // sh 'cd terraform/2-eks && terraform plan -out tfplan' + // sh 'cd terraform/2-eks && terraform show -no-color tfplan > tfplan.txt' + // } + // } stage('Plan: 2-eks') { when { expression { params.terraformAction == 'apply' } } steps { - sh 'cd terraform/2-eks && terraform init -input=false' + sh 'cd terraform/2-eks && terraform init -reconfigure -input=false' sh 'cd terraform/2-eks && terraform plan -out tfplan' sh 'cd terraform/2-eks && terraform show -no-color tfplan > tfplan.txt' } @@ -152,3 +160,153 @@ pipeline { } } } + + + + +//pipeline { + +// parameters { +// choice( +// name: 'terraformAction', +// choices: ['apply', 'destroy'], +// description: 'Choose your terraform action' +// ) +// choice( +// name: 'initMode', +// choices: ['migrate', 'reconfigure'], +// description: 'Choose how to handle backend changes' +// ) +// } + +// environment { +// AWS_ACCESS_KEY_ID = credentials('AWS_ACCESS_KEY_ID') +// AWS_SECRET_ACCESS_KEY = credentials('AWS_SECRET_ACCESS_KEY') +// AWS_DEFAULT_REGION = 'us-east-1' +// } + +// agent any + +// stages { + +// stage('Checkout') { +// steps { +// script { +// dir('terraform') { +// git url: 'https://github.com/laxmanraju4144/Infrastructure.git', branch: 'main' +// } +// } +// } +// } + +// // ─── APPLY STAGES ───────────────────────────────────────────────────── + +// stage('Plan: 0-bootstrap') { +// when { expression { params.terraformAction == 'apply' } } +// steps { +// script { +// def initFlag = params.initMode == 'migrate' ? '-migrate-state' : '-reconfigure' +// sh "cd terraform/0-bootstrap && terraform init ${initFlag} -input=false" +// } +// sh 'cd terraform/0-bootstrap && terraform import aws_s3_bucket.tf_state quantamvector-infra-statefile-backup || true' +// sh 'cd terraform/0-bootstrap && terraform import aws_dynamodb_table.tf_lock quantamvector-terraform-locks || true' +// sh 'cd terraform/0-bootstrap && terraform plan -out tfplan' +// sh 'cd terraform/0-bootstrap && terraform show -no-color tfplan > tfplan.txt' +// } +// } + +// stage('Approval: 0-bootstrap') { +// when { expression { params.terraformAction == 'apply' } } +// steps { +// script { +// def plan = readFile 'terraform/0-bootstrap/tfplan.txt' +// input message: '[0-bootstrap] Approve to proceed', +// parameters: [text(name: 'Plan', description: 'Terraform Plan Output', defaultValue: plan)] +// } +// } +// } + +// stage('Apply: 0-bootstrap') { +// when { expression { params.terraformAction == 'apply' } } +// steps { +// sh 'cd terraform/0-bootstrap && terraform apply -input=false tfplan' +// } +// } + +// stage('Plan: 1-network') { +// when { expression { params.terraformAction == 'apply' } } +// steps { +// script { +// def initFlag = params.initMode == 'migrate' ? '-migrate-state' : '-reconfigure' +// sh "cd terraform/1-network && terraform init ${initFlag} -input=false" +// } +// sh 'cd terraform/1-network && terraform plan -out tfplan' +// sh 'cd terraform/1-network && terraform show -no-color tfplan > tfplan.txt' +// } +// } + +// stage('Approval: 1-network') { +// when { expression { params.terraformAction == 'apply' } } +// steps { +// script { +// def plan = readFile 'terraform/1-network/tfplan.txt' +// input message: '[1-network] Approve to proceed', +// parameters: [text(name: 'Plan', description: 'Terraform Plan Output', defaultValue: plan)] +// } +// } +// } + +// stage('Apply: 1-network') { +// when { expression { params.terraformAction == 'apply' } } +// steps { +// sh 'cd terraform/1-network && terraform apply -input=false tfplan' +// } +// } + +// // Continue with 2-eks stages (same pattern)... + +// // ─── DESTROY STAGES ─────────────────────────────────────────────────── + +// stage('Destroy: 2-eks') { +// when { expression { params.terraformAction == 'destroy' } } +// steps { +// script { +// def initFlag = params.initMode == 'migrate' ? '-migrate-state' : '-reconfigure' +// sh "cd terraform/2-eks && terraform init ${initFlag} -input=false" +// } +// sh 'cd terraform/2-eks && terraform destroy -auto-approve' +// } +// } + +// stage('Destroy: 1-network') { +// when { expression { params.terraformAction == 'destroy' } } +// steps { +// script { +// def initFlag = params.initMode == 'migrate' ? '-migrate-state' : '-reconfigure' +// sh "cd terraform/1-network && terraform init ${initFlag} -input=false" +// } +// sh 'cd terraform/1-network && terraform destroy -auto-approve' +// } +// } + +// stage('Destroy: 0-bootstrap') { +// when { expression { params.terraformAction == 'destroy' } } +// steps { +// script { +// def initFlag = params.initMode == 'migrate' ? '-migrate-state' : '-reconfigure' +// sh "cd terraform/0-bootstrap && terraform init ${initFlag} -input=false" +// } +// sh 'cd terraform/0-bootstrap && terraform destroy -auto-approve' +// } +// } +// } + +// post { +// success { +// echo "terraform ${params.terraformAction} completed successfully." +// } +// failure { +// echo "Pipeline failed. Check the stage logs above." +// } +// } +// }