Skip to content

Commit 41da541

Browse files
authored
Revert "Revert "Update to Elixir 1.18 (#132)" (#133)" (#134)
* update version * bookworm and otp 27.2 * use 1.18.1 * consolidate docker commands * clear /tmp of files created by root * builder and runner
1 parent a9559fb commit 41da541

File tree

7 files changed

+23
-19
lines changed

7 files changed

+23
-19
lines changed

.github/workflows/elixir_tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ jobs:
77
runs-on: ubuntu-20.04
88

99
container:
10-
image: hexpm/elixir:1.17.0-erlang-27.0-debian-bookworm-20240612
10+
image: hexpm/elixir:1.18.1-erlang-27.2-debian-bookworm-20241223
1111

1212
steps:
1313
- name: Install git

.github/workflows/exercism_test_helper_build_test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
runs-on: ubuntu-22.04
1212

1313
container:
14-
image: hexpm/elixir:1.17.0-erlang-27.0-debian-bookworm-20240612
14+
image: hexpm/elixir:1.18.1-erlang-27.2-debian-bookworm-20241223
1515

1616
steps:
1717
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683

.tool-versions

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
elixir 1.17.0-otp-27
2-
erlang 27.0
1+
elixir 1.18.1-otp-27
2+
erlang 27.2

Dockerfile

Lines changed: 16 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,4 @@
1-
FROM hexpm/elixir:1.17.0-erlang-27.0-debian-bookworm-20240612
2-
3-
# Install SSL ca certificates
4-
RUN apt-get update && \
5-
apt-get install bash jo jq -y
1+
FROM hexpm/elixir:1.18.1-erlang-27.2-debian-bookworm-20241223 as builder
62

73
# Create appuser
84
RUN useradd -ms /bin/bash appuser
@@ -13,15 +9,23 @@ COPY . .
139

1410
# Compile the formatter
1511
WORKDIR /opt/test-runner/exercism_test_helper
16-
RUN mix local.rebar --force
17-
RUN mix local.hex --force
18-
RUN mix deps.get
19-
RUN MIX_ENV=test mix compile
20-
RUN mix test --no-compile
12+
RUN mix local.rebar --force && \
13+
mix local.hex --force && \
14+
mix deps.get && \
15+
MIX_ENV=test mix compile && \
16+
mix test --no-compile
2117

2218
# Build the escript
23-
RUN MIX_ENV=prod mix escript.build
24-
RUN mv exercism_test_helper /opt/test-runner/bin
19+
RUN MIX_ENV=prod mix escript.build && \
20+
mv exercism_test_helper /opt/test-runner/bin
21+
22+
FROM hexpm/elixir:1.18.1-erlang-27.2-debian-bookworm-20241223 as runner
23+
COPY --from=builder /etc/passwd /etc/passwd
24+
COPY --from=builder /opt/test-runner /opt/test-runner
25+
26+
# Install SSL ca certificates
27+
RUN apt-get update && \
28+
apt-get install bash jo jq -y
2529

2630
USER appuser
2731

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Exercism Automated Test Runner for Elixir Exercises
66

77
## Environment
88

9-
The test runner currently targets exercises supporting Elixir >= 1.12 and Erlang/OTP >= 24, but is running on Elixir 1.17.0 on hexpm's `elixir:1.17.0-erlang-27.0-debian-bookworm-20240612` image.
9+
The test runner currently targets exercises supporting Elixir >= 1.14 and Erlang/OTP >= 25, but is running on Elixir 1.18.0 on hexpm's `elixir:1.18.1-erlang-27.2-debian-bookworm-20241223` image.
1010

1111
The `Dockerfile` also has added `bash`, `jo` and `jq` to the image.
1212

elixir

Submodule elixir updated 210 files

exercism_test_helper/mix.exs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ defmodule ExercismTestHelper.MixProject do
55
[
66
app: :exercism_test_helper,
77
version: "0.1.2",
8-
elixir: "~> 1.17",
8+
elixir: "~> 1.18",
99
start_permanent: Mix.env() == :prod,
1010
deps: deps(),
1111
escript: escript()

0 commit comments

Comments
 (0)