@@ -158,51 +158,21 @@ jobs:
158
158
strategy :
159
159
fail-fast : false
160
160
matrix :
161
- otp : ['23.0', '25', '26', '27']
162
- elixir : ['1.13', '1.15', '1.16', '1.17']
163
- exclude :
164
- - otp : ' 23.0'
165
- elixir : ' 1.15'
166
- - otp : ' 23.0'
167
- elixir : ' 1.16'
168
- - otp : ' 23.0'
169
- elixir : ' 1.17'
170
- - otp : ' 26'
171
- elixir : ' 1.13'
172
- - otp : ' 27'
173
- elixir : ' 1.13'
174
- - otp : ' 27'
175
- elixir : ' 1.15'
176
- - otp : ' 27'
177
- elixir : ' 1.16'
178
- runs-on : ubuntu-20.04
161
+ elixir : ['1.13', '1.14', '1.15', '1.16', '1.17']
162
+ runs-on : ubuntu-24.04
163
+ container :
164
+ image : elixir:${{ matrix.elixir }}
179
165
180
166
steps :
181
167
182
168
- uses : actions/checkout@v4
183
169
184
- - name : Get specific Erlang/OTP
185
- uses : erlef/setup-beam@v1
186
- with :
187
- otp-version : ${{matrix.otp}}
188
- elixir-version : ${{matrix.elixir}}
189
-
190
- - name : Get compatible Rebar binaries
191
- if : matrix.otp < 24
192
- run : |
193
- rm rebar
194
- rm rebar3
195
- wget https://github.com/processone/ejabberd/raw/21.12/rebar
196
- wget https://github.com/processone/ejabberd/raw/21.12/rebar3
197
- chmod +x rebar
198
- chmod +x rebar3
199
-
200
170
- name : Prepare libraries
201
171
run : |
202
- sudo apt-get -qq update
203
- sudo apt-get -y purge libgd3 nginx
204
- sudo apt-get -qq install libexpat1-dev libgd-dev libpam0g-dev \
205
- libsqlite3-dev libwebp-dev libyaml-dev
172
+ apt-get -qq update
173
+ apt-get -y purge libgd3 nginx
174
+ apt-get -qq install libexpat1-dev libgd-dev libpam0g-dev \
175
+ libsqlite3-dev libwebp-dev libyaml-dev
206
176
207
177
- name : Enable ModPresenceDemo and an Elixir dependency
208
178
run : |
@@ -216,7 +186,13 @@ jobs:
216
186
with :
217
187
path : |
218
188
~/.cache/rebar3/
219
- key : ${{matrix.otp}}-${{hashFiles('rebar.config')}}
189
+ key : ${{matrix.elixir}}-${{hashFiles('rebar.config')}}
190
+
191
+ - name : Install Hex and Rebar3 manually on older Elixir
192
+ if : matrix.elixir <= '1.14'
193
+ run : |
194
+ mix local.hex --force
195
+ mix local.rebar --force
220
196
221
197
- name : Compile
222
198
run : |
@@ -305,41 +281,21 @@ jobs:
305
281
strategy :
306
282
fail-fast : false
307
283
matrix :
308
- otp : ['23.0', '25', '26', '27']
309
- elixir : ['1.13', '1.15', '1.16', '1.17']
310
- exclude :
311
- - otp : ' 23.0'
312
- elixir : ' 1.15'
313
- - otp : ' 23.0'
314
- elixir : ' 1.16'
315
- - otp : ' 23.0'
316
- elixir : ' 1.17'
317
- - otp : ' 26'
318
- elixir : ' 1.13'
319
- - otp : ' 27'
320
- elixir : ' 1.13'
321
- - otp : ' 27'
322
- elixir : ' 1.15'
323
- - otp : ' 27'
324
- elixir : ' 1.16'
325
- runs-on : ubuntu-20.04
284
+ elixir : ['1.13', '1.14', '1.15', '1.16', '1.17']
285
+ runs-on : ubuntu-24.04
286
+ container :
287
+ image : elixir:${{ matrix.elixir }}
326
288
327
289
steps :
328
290
329
291
- uses : actions/checkout@v4
330
292
331
- - name : Get specific Erlang/OTP
332
- uses : erlef/setup-beam@v1
333
- with :
334
- otp-version : ${{matrix.otp}}
335
- elixir-version : ${{matrix.elixir}}
336
-
337
293
- name : Prepare libraries
338
294
run : |
339
- sudo apt-get -qq update
340
- sudo apt-get -y purge libgd3 nginx
341
- sudo apt-get -qq install libexpat1-dev libgd-dev libpam0g-dev \
342
- libsqlite3-dev libwebp-dev libyaml-dev
295
+ apt-get -qq update
296
+ apt-get -y purge libgd3 nginx
297
+ apt-get -qq install libexpat1-dev libgd-dev libpam0g-dev \
298
+ libsqlite3-dev libwebp-dev libyaml-dev
343
299
344
300
- name : Remove Elixir Matchers
345
301
run : |
@@ -356,17 +312,18 @@ jobs:
356
312
sed -i 's|^{deps, \(.*\)|{deps, \1\n {decimal, ".*", {git, "https://github.com/ericmj/decimal", {branch, "main"}}}, |g' rebar.config
357
313
cat rebar.config
358
314
359
- - name : Unlock Jose dependency on older Erlang
360
- if : matrix.otp < 24
361
- run : |
362
- mix deps.unlock jose
363
-
364
315
- name : Cache Hex.pm
365
316
uses : actions/cache@v4
366
317
with :
367
318
path : |
368
319
~/.hex/
369
- key : ${{matrix.otp}}-${{hashFiles('mix.exs')}}
320
+ key : ${{matrix.elixir}}-${{hashFiles('mix.exs')}}
321
+
322
+ - name : Install Hex and Rebar3 manually on older Elixir
323
+ if : matrix.elixir <= '1.14'
324
+ run : |
325
+ mix local.hex --force
326
+ mix local.rebar --force
370
327
371
328
- name : Compile
372
329
run : |
0 commit comments