diff --git a/.github/workflows/build-ci.yml b/.github/workflows/build-ci.yml index 45833d579..d04181fe7 100644 --- a/.github/workflows/build-ci.yml +++ b/.github/workflows/build-ci.yml @@ -15,45 +15,57 @@ jobs: os: - "ubuntu-latest" mongodb: - - "4.4" - - "5.0" - - "6.0" - - "7.0" + #- "4.4" + #- "5.0" + #- "6.0" + #- "7.0" + - "Atlas" php: - - "8.1" - - "8.2" + #- "8.1" + #- "8.2" - "8.3" laravel: - - "10.*" + #- "10.*" - "11.*" - include: - - php: "8.1" - laravel: "10.*" - mongodb: "5.0" - mode: "low-deps" - os: "ubuntu-latest" - - php: "8.4" - laravel: "11.*" - mongodb: "7.0" - mode: "ignore-php-req" - os: "ubuntu-latest" - exclude: - - php: "8.1" - laravel: "11.*" + #include: + #- php: "8.1" + # laravel: "10.*" + # mongodb: "5.0" + # mode: "low-deps" + # os: "ubuntu-latest" + #- php: "8.4" + # laravel: "11.*" + # mongodb: "7.0" + # mode: "ignore-php-req" + # os: "ubuntu-latest" + #exclude: + #- php: "8.1" + # laravel: "11.*" steps: - uses: "actions/checkout@v4" - name: "Create MongoDB Replica Set" + if: ${{ matrix.mongodb != 'Atlas' }} run: | docker run --name mongodb -p 27017:27017 -e MONGO_INITDB_DATABASE=unittest --detach mongo:${{ matrix.mongodb }} mongod --replSet rs --setParameter transactionLifetimeLimitSeconds=5 if [ "${{ matrix.mongodb }}" = "4.4" ]; then MONGOSH_BIN="mongo"; else MONGOSH_BIN="mongosh"; fi until docker exec --tty mongodb $MONGOSH_BIN 127.0.0.1:27017 --eval "db.runCommand({ ping: 1 })"; do - sleep 1 + sleep 1 done sudo docker exec --tty mongodb $MONGOSH_BIN 127.0.0.1:27017 --eval "rs.initiate({\"_id\":\"rs\",\"members\":[{\"_id\":0,\"host\":\"127.0.0.1:27017\" }]})" + - name: "Create MongoDB Atlas Local" + if: ${{ matrix.mongodb == 'Atlas' }} + run: | + docker run --name mongodb -p 27017:27017 -e MONGO_INITDB_DATABASE=unittest --detach mongodb/mongodb-atlas-local:latest + until docker exec --tty mongodb mongosh 127.0.0.1:27017 --eval "db.runCommand({ ping: 1 })"; do + sleep 1 + done + # is there a starting issue? + sleep 10 + - name: "Show MongoDB server status" run: | if [ "${{ matrix.mongodb }}" = "4.4" ]; then MONGOSH_BIN="mongo"; else MONGOSH_BIN="mongosh"; fi