13
13
branches : ["main"]
14
14
pull_request :
15
15
branches : ["main"]
16
-
16
+
17
17
permissions :
18
18
contents : read
19
19
26
26
uses : actions/checkout@v4
27
27
- name : Deploy With Value 1
28
28
uses :
" infinite-automations/[email protected] "
29
- with :
29
+ with :
30
30
directory : " ./terraform"
31
31
apply : true
32
32
env :
@@ -36,17 +36,23 @@ jobs:
36
36
echo "Running test 1..."
37
37
- name : Deploy With Value 2
38
38
uses :
" infinite-automations/[email protected] "
39
- with :
39
+ with :
40
40
directory : " ./terraform"
41
41
apply : true
42
42
env :
43
43
TF_VAR_my_var : " value2"
44
44
- name : Run Test 2
45
- run : |
46
- echo "Running test 2..."
45
+ uses :
" infinite-automations/[email protected] "
46
+ with :
47
+ directory : " ./terraform"
48
+ test-directory : " ./terraform"
49
+ format : false
50
+ validate : false
51
+ plan : false
52
+ test : true
47
53
- name : Destroy
48
54
uses :
" infinite-automations/[email protected] "
49
- with :
55
+ with :
50
56
directory : " ./terraform"
51
57
setup : false
52
58
init : false
@@ -61,25 +67,28 @@ You can configure additional command arguments with inputs.
61
67
62
68
## Inputs
63
69
64
- | Input Name | Description | Required | Default |
65
- | ----------------- | ----------------------------------------------------------------- | -------- | --------- |
66
- | directory | The directory where the Terraform configuration files are located | false | . |
67
- | terraform-version | The version of Terraform to use | false | latest |
68
- | plan-file | The path to the plan file | false | plan.json |
69
- | common-args | The arguments to pass to all terraform commands | false | |
70
- | init-args | The arguments to pass to terraform init | false | |
71
- | validate-args | The arguments to pass to terraform validate | false | |
72
- | fmt-args | The arguments to pass to terraform fmt | false | -check |
73
- | plan-args | The arguments to pass to terraform plan | false | |
74
- | apply-args | The arguments to pass to terraform apply | false | |
75
- | destroy-args | The arguments to pass to terraform destroy | false | |
76
- | setup | Whether to setup | false | true |
77
- | init | Whether to init | false | true |
78
- | format | Whether to format | false | true |
79
- | validate | Whether to validate | false | true |
80
- | plan | Whether to plan | false | true |
81
- | apply | Whether to apply | false | false |
82
- | destroy | Whether to destroy | false | false |
70
+ | Input Name | Description | Required | Default |
71
+ | ----------------- | ---------------------------------------------------------------------- | -------- | --------- |
72
+ | directory | The directory where the Terraform configuration files are located | false | . |
73
+ | test-directory | The directory where the Terraform test configuration files are located | false | . |
74
+ | terraform-version | The version of Terraform to use | false | latest |
75
+ | plan-file | The path to the plan file | false | plan.json |
76
+ | common-args | The arguments to pass to all terraform commands | false | |
77
+ | init-args | The arguments to pass to terraform init | false | |
78
+ | validate-args | The arguments to pass to terraform validate | false | |
79
+ | fmt-args | The arguments to pass to terraform fmt | false | -check |
80
+ | test-args | The arguments to pass to terraform test | false | |
81
+ | plan-args | The arguments to pass to terraform plan | false | |
82
+ | apply-args | The arguments to pass to terraform apply | false | |
83
+ | destroy-args | The arguments to pass to terraform destroy | false | |
84
+ | setup | Whether to setup | false | true |
85
+ | init | Whether to init | false | true |
86
+ | format | Whether to format | false | true |
87
+ | validate | Whether to validate | false | true |
88
+ | test | Whether to test | false | false |
89
+ | plan | Whether to plan | false | true |
90
+ | apply | Whether to apply | false | false |
91
+ | destroy | Whether to destroy | false | false |
83
92
84
93
## Outputs
85
94
0 commit comments