File tree Expand file tree Collapse file tree 4 files changed +19
-11
lines changed Expand file tree Collapse file tree 4 files changed +19
-11
lines changed Original file line number Diff line number Diff line change @@ -231,7 +231,7 @@ jobs:
231
231
232
232
- uses : hashicorp/setup-terraform@v2
233
233
with :
234
- terraform_version : 1.1.9
234
+ terraform_version : 1.5.1
235
235
terraform_wrapper : false
236
236
237
237
- name : Test with Mock Database
@@ -296,7 +296,7 @@ jobs:
296
296
297
297
- uses : hashicorp/setup-terraform@v2
298
298
with :
299
- terraform_version : 1.1.9
299
+ terraform_version : 1.5.1
300
300
terraform_wrapper : false
301
301
302
302
- name : Test with PostgreSQL Database
@@ -338,6 +338,11 @@ jobs:
338
338
339
339
- uses : ./.github/actions/setup-go
340
340
341
+ - uses : hashicorp/setup-terraform@v2
342
+ with :
343
+ terraform_version : 1.5.1
344
+ terraform_wrapper : false
345
+
341
346
- name : Run Tests
342
347
run : |
343
348
gotestsum --junitfile="gotests.xml" -- -race ./...
@@ -474,7 +479,7 @@ jobs:
474
479
475
480
- uses : hashicorp/setup-terraform@v2
476
481
with :
477
- terraform_version : 1.1.9
482
+ terraform_version : 1.5.1
478
483
terraform_wrapper : false
479
484
480
485
- name : Build
Original file line number Diff line number Diff line change 22
22
TerraformVersion = version .Must (version .NewVersion ("1.4.6" ))
23
23
24
24
minTerraformVersion = version .Must (version .NewVersion ("1.1.0" ))
25
- maxTerraformVersion = version .Must (version .NewVersion ("1.4 .9" ))
25
+ maxTerraformVersion = version .Must (version .NewVersion ("1.5 .9" )) // use .9 to automatically allow patch releases
26
26
27
27
terraformMinorVersionMismatch = xerrors .New ("Terraform binary minor version mismatch." )
28
28
)
Original file line number Diff line number Diff line change @@ -20,7 +20,6 @@ import (
20
20
21
21
"cdr.dev/slog"
22
22
"cdr.dev/slog/sloggers/slogtest"
23
-
24
23
"github.com/coder/coder/provisioner/terraform"
25
24
"github.com/coder/coder/provisionersdk"
26
25
"github.com/coder/coder/provisionersdk/proto"
@@ -284,15 +283,15 @@ func TestProvision(t *testing.T) {
284
283
Files : map [string ]string {
285
284
"main.tf" : `a` ,
286
285
},
287
- ErrorContains : "initialize terraform" ,
286
+ ErrorContains : "plan terraform" ,
288
287
ExpectLogContains : "Argument or block definition required" ,
289
288
},
290
289
{
291
290
Name : "bad-syntax-2" ,
292
291
Files : map [string ]string {
293
292
"main.tf" : `;asdf;` ,
294
293
},
295
- ErrorContains : "initialize terraform" ,
294
+ ErrorContains : "plan terraform" ,
296
295
ExpectLogContains : `The ";" character is not valid.` ,
297
296
},
298
297
{
Original file line number Diff line number Diff line change 1
1
# This is the base image used for Coder images. It's a multi-arch image that is
2
2
# built in depot.dev for all supported architectures. Since it's built on real
3
3
# hardware and not cross-compiled, it can have "RUN" commands.
4
- FROM alpine:3.18
4
+ FROM alpine:3.18.2
5
5
6
6
# We use a single RUN command to reduce the number of layers in the image.
7
7
# NOTE: Keep the Terraform version in sync with minTerraformVersion and
@@ -11,9 +11,13 @@ RUN apk add --no-cache \
11
11
wget \
12
12
bash \
13
13
git \
14
- openssl>=3.1.1-r1 \
15
- openssh-client \
16
- terraform=1.4.6-r1 && \
14
+ openssh-client && \
15
+ # Use the edge repo, since Terraform doesn't seem to be backported to 3.18.
16
+ # TODO: remove =~
17
+ # For some reason alpine's ARM builders are offline, so ARM builds will have
18
+ # to fall back to 1.5.0.
19
+ apk add --no-cache --repository=https://dl-cdn.alpinelinux.org/alpine/edge/community \
20
+ terraform=~1.5-r0 && \
17
21
addgroup \
18
22
-g 1000 \
19
23
coder && \
You can’t perform that action at this time.
0 commit comments