Skip to content

Commit

Permalink
chore: ci.yml - avoid calling brew link libpq --force on macos (#2627)
Browse files Browse the repository at this point in the history
* ci.yml: avoid calling brew link libpq --force on macos
PRs started to fail due to that but we are not actually running
postgres tests on MacOS

* fix: remove brew linking for test job
* fix: conditional compilation for macos
* fix: remove autoformatted details

---------

Co-authored-by: rymnc <[email protected]>
  • Loading branch information
Ivansete-status and rymnc authored Apr 26, 2024
1 parent 843fe21 commit 05f332e
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 15 deletions.
20 changes: 9 additions & 11 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,12 @@ jobs:
- 'Makefile'
- 'waku.nimble'
- 'library/**'
v2:
- 'waku/**'
- 'apps/**'
- 'tools/**'
- 'tests/all_tests_v2.nim'
- 'tests/**'
docker:
- 'docker/**'
Expand All @@ -55,8 +53,8 @@ jobs:
if: ${{ needs.changes.outputs.v2 == 'true' || needs.changes.outputs.common == 'true' }}
strategy:
matrix:
rln_version : [1, 2]
os: [ubuntu-latest, macos-latest]
rln_version: [1, 2]
os: [ubuntu-latest, macos-13]
runs-on: ${{ matrix.os }}
timeout-minutes: 60

Expand Down Expand Up @@ -86,8 +84,8 @@ jobs:
if: ${{ needs.changes.outputs.v2 == 'true' || needs.changes.outputs.common == 'true' }}
strategy:
matrix:
rln_version : [1, 2]
os: [ubuntu-latest, macos-latest]
rln_version: [1, 2]
os: [ubuntu-latest, macos-13]
runs-on: ${{ matrix.os }}
timeout-minutes: 60

Expand All @@ -111,16 +109,16 @@ jobs:

- name: Run tests
run: |
if [ ${{ runner.os }} == "macOS" ]; then
brew unlink postgresql@14
brew link libpq --force
if [ ${{ runner.os }} == "Linux" ]; then
sudo docker run --rm -d -e POSTGRES_PASSWORD=test123 -p 5432:5432 postgres:15.4-alpine3.18
fi
postgres_enabled=0
if [ ${{ runner.os }} == "Linux" ]; then
sudo docker run --rm -d -e POSTGRES_PASSWORD=test123 -p 5432:5432 postgres:15.4-alpine3.18
postgres_enabled=1
fi
make RLN_V${{matrix.rln_version}}=true V=1 LOG_LEVEL=DEBUG QUICK_AND_DIRTY_COMPILER=1 POSTGRES=1 test testwakunode2
make RLN_V${{matrix.rln_version}}=true V=1 LOG_LEVEL=DEBUG QUICK_AND_DIRTY_COMPILER=1 POSTGRES=$postgres_enabled test testwakunode2
build-docker-image:
needs: changes
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/pre-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,10 @@ jobs:
needs: tag-name
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
os: [ubuntu-latest, macos-13]
arch: [amd64]
include:
- os: macos-latest
- os: macos-13
arch: arm64
runs-on: ${{ matrix.os }}
steps:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release-assets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ jobs:
build-and-upload:
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
os: [ubuntu-latest, macos-13]
arch: [amd64]
include:
- os: macos-latest
- os: macos-13
arch: arm64
runs-on: ${{ matrix.os }}
timeout-minutes: 60
Expand Down

0 comments on commit 05f332e

Please sign in to comment.