feat(ci): add GitHub Actions workflow for testing and Docker builds #20

Merged
haylan merged 13 commits from patch-2-gitea-registry into main 2026-07-31 12:22:24 +00:00
Showing only changes of commit 47d9a62db7 - Show all commits
+8 -8
View File
@@ -19,9 +19,6 @@ jobs:
- name: Set up Docker Buildx - name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3 uses: docker/setup-buildx-action@v3
# type=gha depends on act_runner's internal cache proxy, which is unreachable
# from job containers on this runner (dial tcp ... i/o timeout). Use the
# registry cache backend instead, same as docker-publish.yml.
- name: Log in to Gitea registry - name: Log in to Gitea registry
uses: docker/login-action@v3 uses: docker/login-action@v3
with: with:
@@ -46,6 +43,7 @@ jobs:
name: graph-dev-image name: graph-dev-image
path: /tmp/graph-dev.tar path: /tmp/graph-dev.tar
retention-days: 1 retention-days: 1
build-prod: build-prod:
needs: build-dev needs: build-dev
runs-on: ubuntu-latest runs-on: ubuntu-latest
@@ -80,8 +78,10 @@ jobs:
- name: Load dev image - name: Load dev image
run: docker load --input /tmp/graph-dev.tar run: docker load --input /tmp/graph-dev.tar
- name: Run PHPUnit - name: Run tests in dev image
run: docker run --rm -v "$(pwd)":/app -v /app/vendor graph-dev:ci vendor/bin/phpunit --testdox run: |
docker run --rm -v "$(pwd)":/app -v /app/vendor graph-dev:ci sh -c "
- name: Run PHPStan composer install --no-interaction &&
run: docker run --rm -v "$(pwd)":/app -v /app/vendor graph-dev:ci composer phpstan vendor/bin/phpunit --testdox &&
composer phpstan
"