fix: #146 forgot portal #21
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Laravel 11 | |
on: | |
push: | |
tags: | |
- v* | |
paths-ignore: | |
- "**.md" | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
test: | |
if: ${{ ! startsWith(github.ref, 'refs/tags/') }} | |
name: Test | |
runs-on: ubuntu-latest | |
container: | |
image: laravelfans/laravel:11-dev | |
steps: | |
- | |
name: Checkout | |
uses: actions/checkout@v4 | |
- | |
name: Prepare | |
run: | | |
composer install | |
npm install | |
npm run build | |
- | |
name: PHPUnit | |
env: | |
XDEBUG_MODE: coverage | |
run: php artisan test | |
- | |
name: Upload test results to Codecov | |
if: ${{ !cancelled() }} | |
uses: codecov/test-results-action@v1 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
- | |
name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v4 | |
env: | |
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | |
- | |
name: Lint PHP | |
run: php artisan lint:code | |
- | |
uses: hadolint/[email protected] | |
buildx: | |
if: startsWith(github.ref, 'refs/tags/v') | |
runs-on: ubuntu-latest | |
steps: | |
- | |
name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- | |
name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
- | |
name: Login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- | |
name: Get Version from Tag | |
id: tagver | |
uses: ChrSchu90/[email protected] | |
- | |
name: Build and push | |
uses: docker/build-push-action@v6 | |
with: | |
platforms: linux/amd64,linux/arm64/v8,linux/arm/v7 | |
push: true | |
tags: wifidog/wifidog-auth-laravel:latest,wifidog/wifidog-auth-laravel:${{ steps.tagver.outputs.version }} |