-
Notifications
You must be signed in to change notification settings - Fork 14
/
6.sh
50 lines (40 loc) · 827 Bytes
/
6.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
module "nginx-controller" {
source = "terraform-iaac/nginx-controller/helm"
}
provider "helm" {
kubernetes {
config_path = "~/.kube/config"
}
}
https://registry.terraform.io/modules/terraform-iaac/nginx-controller/helm/latest?tab=inputs
module "app" {
source = "../../modules/app"
env = "prod"
controller_kind = "Deployment" # use this
}
# dev/app-tg/terragrunt.hcl
terraform {
source = "../../modules/app"
}
include {
path = find_in_parent_folders()
}
# dev/terragrunt.hcl
inputs= {
env = "development"
}
generate "provider" {
path = "provider.tf"
if_exists = "overwrite"
contents = <<EOF
provider "kubernetes" {
config_path = "~/.kube/config"
}
provider "helm" {
kubernetes {
config_path = "~/.kube/config"
}
}
EOF
}
# https://github.com/gruntwork-io/terragrunt/releases