Skip to content

Commit b808ca9

Browse files
author
Anca
committed
add dummy config to build without active profile + separate tflocal workspace
1 parent e8a760f commit b808ca9

File tree

6 files changed

+438
-6
lines changed

6 files changed

+438
-6
lines changed

README.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -171,16 +171,17 @@ Usage: terraform [global options] <subcommand> [args]
171171
...
172172
```
173173

174-
From here on, it's smooth sailing, the same as before. You can eve use the same folder to run
175-
your commands:
174+
From here on, it's smooth sailing, the same as before. Switch to `setup/tflocal` folder, the files are
175+
identical as the ones in `setup/terraform`, but for the newly generated state files, it is a good idea
176+
to separate these "workspaces":
176177

177178
```
178179
$ tflocal init
179180
$ tflocal plan -var 'env=dev'
180181
$ tflocal apply -var 'env=dev'
181182
```
182183

183-
Well, almost, we're doing a little cheating and passing and environmental variable to let the Lambda
184+
What we're doing here is just passing an environmental variable to let the Lambda
184185
know this is the `dev` environment.
185186

186187
After that, the Spring Boot application needs to start using the dev profile (make sure you're in

setup/tflocal/data.json

Lines changed: 254 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,254 @@
1+
{
2+
"shipment1": {
3+
"shipmentId": {
4+
"S": "dc3b6668-45ba-4c10-9860-95bbffaebfc1"
5+
},
6+
"recipient": {
7+
"M": {
8+
"name": {
9+
"S": "Harry Potter"
10+
},
11+
"address": {
12+
"M": {
13+
"postalCode": {
14+
"S": "LNDNGB"
15+
},
16+
"street": {
17+
"S": "Privet Drive"
18+
},
19+
"number": {
20+
"S": "4"
21+
},
22+
"city": {
23+
"S": "Little Whinging"
24+
},
25+
"additionalInfo": {
26+
"S": ""
27+
}
28+
}
29+
}
30+
}
31+
},
32+
"sender": {
33+
"M": {
34+
"name": {
35+
"S": "Hermione Granger"
36+
},
37+
"address": {
38+
"M": {
39+
"postalCode": {
40+
"S": "OXFGB"
41+
},
42+
"street": {
43+
"S": "Grimmauld Place"
44+
},
45+
"number": {
46+
"S": "12"
47+
},
48+
"city": {
49+
"S": "London"
50+
},
51+
"additionalInfo": {
52+
"S": ""
53+
}
54+
}
55+
}
56+
}
57+
},
58+
"weight": {
59+
"N": "1.0"
60+
},
61+
"imageLink": {
62+
"NULL": true
63+
}
64+
},
65+
"shipment2": {
66+
"shipmentId": {
67+
"S": "f7fc2d00-5cd9-4749-b5ac-10a6f7ac0310"
68+
},
69+
"recipient": {
70+
"M": {
71+
"name": {
72+
"S": "Walter White"
73+
},
74+
"address": {
75+
"M": {
76+
"postalCode": {
77+
"S": "ALBQNM"
78+
},
79+
"street": {
80+
"S": "Negra Arroyo Lane"
81+
},
82+
"number": {
83+
"S": "308"
84+
},
85+
"city": {
86+
"S": "Albuquerque"
87+
},
88+
"additionalInfo": {
89+
"S": "RV storage"
90+
}
91+
}
92+
}
93+
}
94+
},
95+
"sender": {
96+
"M": {
97+
"name": {
98+
"S": "Tony Stark"
99+
},
100+
"address": {
101+
"M": {
102+
"postalCode": {
103+
"S": "NYCNY"
104+
},
105+
"street": {
106+
"S": "Avenue of the Americas"
107+
},
108+
"number": {
109+
"S": "64"
110+
},
111+
"city": {
112+
"S": "New York City"
113+
},
114+
"additionalInfo": {
115+
"S": "Stark Tower"
116+
}
117+
}
118+
}
119+
}
120+
},
121+
"weight": {
122+
"N": "0.7"
123+
},
124+
"imageLink": {
125+
"NULL": true
126+
}
127+
},
128+
"shipment3": {
129+
"shipmentId": {
130+
"S": "3317ac4f-1f9b-4bab-a974-4aadf79d7da5"
131+
},
132+
"recipient": {
133+
"M": {
134+
"name": {
135+
"S": "Buddy The Elf"
136+
},
137+
"address": {
138+
"M": {
139+
"postalCode": {
140+
"S": "938746"
141+
},
142+
"street": {
143+
"S": "Candy Cane Lane"
144+
},
145+
"number": {
146+
"S": "1"
147+
},
148+
"city": {
149+
"S": "North Pole"
150+
},
151+
"additionalInfo": {
152+
"S": "Santa's Workshop"
153+
}
154+
}
155+
}
156+
}
157+
},
158+
"sender": {
159+
"M": {
160+
"name": {
161+
"S": "The Grinch"
162+
},
163+
"address": {
164+
"M": {
165+
"postalCode": {
166+
"S": "69869"
167+
},
168+
"street": {
169+
"S": "Mount Crumpit"
170+
},
171+
"number": {
172+
"S": "666"
173+
},
174+
"city": {
175+
"S": "Whoville"
176+
},
177+
"additionalInfo": {
178+
"S": "Cave"
179+
}
180+
}
181+
}
182+
}
183+
},
184+
"weight": {
185+
"N": "9.0"
186+
},
187+
"imageLink": {
188+
"NULL": true
189+
}
190+
},
191+
"shipment4": {
192+
"shipmentId": {
193+
"S": "26c09286-a00c-11ed-a8fc-0242ac120002"
194+
},
195+
"recipient": {
196+
"M": {
197+
"name": {
198+
"S": "Home Sweet Home"
199+
},
200+
"address": {
201+
"M": {
202+
"postalCode": {
203+
"S": "98653"
204+
},
205+
"street": {
206+
"S": "47th Street"
207+
},
208+
"number": {
209+
"S": "4"
210+
},
211+
"city": {
212+
"S": "Springfield"
213+
},
214+
"additionalInfo": {
215+
"S": ""
216+
}
217+
}
218+
}
219+
}
220+
},
221+
"sender": {
222+
"M": {
223+
"name": {
224+
"S": "Warehouse of Unicorns"
225+
},
226+
"address": {
227+
"M": {
228+
"postalCode": {
229+
"S": "98653"
230+
},
231+
"street": {
232+
"S": "47th Street"
233+
},
234+
"number": {
235+
"S": "4"
236+
},
237+
"city": {
238+
"S": "Townsville"
239+
},
240+
"additionalInfo": {
241+
"S": ""
242+
}
243+
}
244+
}
245+
}
246+
},
247+
"weight": {
248+
"N": "2.3"
249+
},
250+
"imageLink": {
251+
"NULL": true
252+
}
253+
}
254+
}

setup/tflocal/locals.tf

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
locals {
2+
json_data = file("./data.json")
3+
tf_data = jsondecode(local.json_data)
4+
}

0 commit comments

Comments
 (0)