@@ -31,6 +31,8 @@ Maps to the [`corefunc.EnvEnsure()`](https://pkg.go.dev/github.com/northwood-lab
31
31
32
32
## Example Usage
33
33
34
+ ### ` AWS_DEFAULT_REGION ` is defined (no error)
35
+
34
36
``` terraform
35
37
#-------------------------------------------------------------------------
36
38
# AWS_DEFAULT_REGION="us-east-1"
@@ -46,7 +48,11 @@ output "aws_default_region_value" {
46
48
}
47
49
48
50
#=> us-east-1
51
+ ```
52
+
53
+ ### ` AWS_PAGER ` is set to an empty string (error)
49
54
55
+ ``` terraform
50
56
#-------------------------------------------------------------------------
51
57
# AWS_PAGER=""
52
58
@@ -60,7 +66,11 @@ output "aws_pager_value" {
60
66
61
67
#=> [Error] Problem with Environment Variable: environment variable
62
68
#=> AWS_PAGER is not defined
69
+ ```
70
+
71
+ ### ` AWS_VAULT ` is defined, but does not match pattern (error)
63
72
73
+ ``` terraform
64
74
#-------------------------------------------------------------------------
65
75
# AWS_VAULT="dev"
66
76
@@ -77,6 +87,42 @@ output "aws_vault_value" {
77
87
#=> AWS_VAULT does not match pattern (non)?prod$
78
88
```
79
89
90
+ ### Example plan output
91
+
92
+ ``` bash
93
+ AWS_DEFAULT_REGION=" us-east-1" AWS_VAULT=" dev" terraform plan
94
+ ```
95
+
96
+ ``` plain
97
+ data.corefunc_env_ensure.aws_vault: Reading...
98
+ data.corefunc_env_ensure.aws_pager: Reading...
99
+ data.corefunc_env_ensure.aws_default_region: Reading...
100
+ data.corefunc_env_ensure.aws_default_region: Read complete after 0s [name=AWS_DEFAULT_REGION]
101
+
102
+ Changes to Outputs:
103
+ + aws_default_region_value = "us-east-1"
104
+
105
+ You can apply this plan to save these new output values to the Terraform state, without changing any real infrastructure.
106
+ ╷
107
+ │ Error: Problem with Environment Variable
108
+ │
109
+ │ with data.corefunc_env_ensure.aws_pager,
110
+ │ on data-source-AWS_PAGER.tf line 4, in data "corefunc_env_ensure" "aws_pager":
111
+ │ 4: data "corefunc_env_ensure" "aws_pager" {
112
+ │
113
+ │ environment variable AWS_PAGER is not defined
114
+ ╵
115
+ ╷
116
+ │ Error: Problem with Environment Variable
117
+ │
118
+ │ with data.corefunc_env_ensure.aws_vault,
119
+ │ on data-source-AWS_VAULT.tf line 4, in data "corefunc_env_ensure" "aws_vault":
120
+ │ 4: data "corefunc_env_ensure" "aws_vault" {
121
+ │
122
+ │ environment variable AWS_VAULT does not match pattern (non)?prod$
123
+ ╵
124
+ ```
125
+
80
126
<!-- schema generated by tfplugindocs -->
81
127
## Schema
82
128
0 commit comments