1
0
Fork 0
mirror of https://github.com/processone/ejabberd synced 2025-10-03 09:49:18 +02:00

CI: Bump ubuntu-24.04, and Erlang 25+ (#4281)

Update postgresql preparation:
- ubuntu-20.04 included PostgreSQL 14.13
- ubuntu-24.04 includes PostgreSQL 16.4
and in the meantime, PostgreSQL 15.0 revoked
"the CREATE permission from all users except a database owner from the public (or default) schema."
See https://www.postgresql.org/about/news/postgresql-15-released-2526/
This commit is contained in:
Badlop 2025-04-01 15:39:17 +02:00
parent 4d3681aba1
commit e43d864184

View file

@ -25,8 +25,8 @@ jobs:
strategy: strategy:
fail-fast: false fail-fast: false
matrix: matrix:
otp: ['20.0', '25', '26', '27'] otp: ['25', '26', '27']
runs-on: ubuntu-20.04 runs-on: ubuntu-24.04
services: services:
redis: redis:
image: public.ecr.aws/docker/library/redis image: public.ecr.aws/docker/library/redis
@ -50,13 +50,6 @@ jobs:
with: with:
otp-version: ${{ matrix.otp }} otp-version: ${{ matrix.otp }}
- name: Get a compatible Rebar3
if: matrix.otp < 24
run: |
rm rebar3
wget https://github.com/processone/ejabberd/raw/21.12/rebar3
chmod +x rebar3
- name: Install MS SQL Server - name: Install MS SQL Server
run: | run: |
docker run -d -e "ACCEPT_EULA=Y" -e "SA_PASSWORD=ejabberd_Test1" \ docker run -d -e "ACCEPT_EULA=Y" -e "SA_PASSWORD=ejabberd_Test1" \
@ -83,6 +76,8 @@ jobs:
WITH PASSWORD 'ejabberd_test';" WITH PASSWORD 'ejabberd_test';"
sudo -u postgres psql -c "GRANT ALL PRIVILEGES sudo -u postgres psql -c "GRANT ALL PRIVILEGES
ON DATABASE ejabberd_test TO ejabberd_test;" ON DATABASE ejabberd_test TO ejabberd_test;"
sudo -u postgres psql -c "GRANT ALL ON SCHEMA public TO ejabberd_test;"
sudo -u postgres psql -c "ALTER DATABASE ejabberd_test OWNER TO ejabberd_test;"
sudo -u postgres psql ejabberd_test -c "GRANT ALL PRIVILEGES ON ALL sudo -u postgres psql ejabberd_test -c "GRANT ALL PRIVILEGES ON ALL
TABLES IN SCHEMA public TABLES IN SCHEMA public
TO ejabberd_test;" TO ejabberd_test;"
@ -107,10 +102,6 @@ jobs:
~/.cache/rebar3/ ~/.cache/rebar3/
key: ${{matrix.otp}}-${{hashFiles('rebar.config')}} key: ${{matrix.otp}}-${{hashFiles('rebar.config')}}
- name: Get old eredis for old Erlang
if: matrix.otp < 21
run: ./rebar3 unlock eredis
- name: Compile - name: Compile
run: | run: |
./autogen.sh ./autogen.sh
@ -129,7 +120,6 @@ jobs:
- run: make dialyzer - run: make dialyzer
- run: make test-eunit - run: make test-eunit
- run: make elvis - run: make elvis
if: matrix.otp >= 23
- name: Check Production Release - name: Check Production Release
run: | run: |
@ -267,6 +257,8 @@ jobs:
sudo -u postgres psql -c "CREATE DATABASE ejabberd_test;" sudo -u postgres psql -c "CREATE DATABASE ejabberd_test;"
sudo -u postgres psql -c "GRANT ALL PRIVILEGES sudo -u postgres psql -c "GRANT ALL PRIVILEGES
ON DATABASE ejabberd_test TO ejabberd_test;" ON DATABASE ejabberd_test TO ejabberd_test;"
sudo -u postgres psql -c "GRANT ALL ON SCHEMA public TO ejabberd_test;"
sudo -u postgres psql -c "ALTER DATABASE ejabberd_test OWNER TO ejabberd_test;"
sudo -u postgres psql ejabberd_test -c "GRANT ALL PRIVILEGES ON ALL sudo -u postgres psql ejabberd_test -c "GRANT ALL PRIVILEGES ON ALL
TABLES IN SCHEMA public TABLES IN SCHEMA public
TO ejabberd_test;" TO ejabberd_test;"