-
Notifications
You must be signed in to change notification settings - Fork 0
/
global-config.hcl
44 lines (36 loc) · 1.04 KB
/
global-config.hcl
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
locals {
git_root_path = run_cmd("--terragrunt-quiet", "git", "rev-parse", "--show-toplevel")
}
terraform {
before_hook "tfenv_test" {
commands = ["init", "apply", "plan", "destroy"]
execute = ["${local.git_root_path}/bin/tfenv-test.sh"]
}
before_hook "tgenv_test" {
commands = ["init", "apply", "plan", "destroy"]
execute = ["${local.git_root_path}/bin/tgenv-test.sh"]
}
before_hook "git_test" {
commands = ["init", "apply", "plan", "destroy"]
execute = ["${local.git_root_path}/bin/git-test.sh"]
}
extra_arguments "plugin_dir" {
commands = [
"init",
"plan",
"apply",
"destroy",
"output"
]
env_vars = {
TF_PLUGIN_CACHE_DIR = "${local.git_root_path}/terraform/plugins_cache"
}
}
}
remote_state {
backend = "local"
config = {
path = "${local.git_root_path}/terraform/states/${path_relative_to_include("global-config.hcl")}/terraform.tfstate"
}
}
download_dir = "${local.git_root_path}/terraform/terragrunt_cache"