This repository has been archived by the owner on Sep 29, 2024. It is now read-only.
Bump axios from 1.4.0 to 1.6.0 #6
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: Pull Request | CI PEST | |
on: pull_request | |
jobs: | |
ci_pest: | |
runs-on: ${{ matrix.os }} | |
name: pull-request | ci pest | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ ubuntu-latest ] | |
php: [ 8.2 ] | |
node: [ 16 ] | |
steps: | |
- name: set timezone | |
uses: szenius/[email protected] | |
with: | |
timezoneLinux: "Europe/Zurich" | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: '0' | |
- name: Setup php env | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: ${{ matrix.php }} | |
extensions: dom, curl, fileinfo, mysql, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick | |
- name: Prepare the .env file | |
run: cp .env.ci .env | |
- name: Prepare the vite.config.js file | |
run: cp vite.config-example.js vite.config.js | |
# Backend dependencies | |
- name: Apply Nova license | |
run: composer config http-basic.nova.laravel.com ${{ secrets.NOVA_USERNAME }} ${{ secrets.NOVA_LICENSE_KEY }} | |
- name: Get composer cache directory | |
id: composer-cache | |
run: echo "::set-output name=dir::$(composer config cache-files-dir)" | |
- name: Cache composer dependencies | |
uses: actions/cache@v3 | |
with: | |
path: ${{ steps.composer-cache.outputs.dir }} | |
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} | |
restore-keys: ${{ runner.os }}-composer- | |
- name: Install Composer dependencies | |
run: composer install -q --no-progress --prefer-dist --no-interaction --no-suggest --optimize-autoloader --no-scripts | |
# Prepare Backend | |
- name: Create Database | |
run: | | |
sudo systemctl start mysql | |
mysql --user="root" --password="root" -e "CREATE DATABASE laravel character set UTF8mb4 collate utf8mb4_bin;" | |
# Artisan commands | |
- name: Generate app key | |
run: php artisan key:generate | |
- name: Run Migration | |
run: php artisan migrate:fresh | |
# Frontend dependencies | |
- name: Set NPM token | |
run: npm config set "//npm.fontawesome.com/:_authToken" ${{ secrets.FONTAWESOME_NPM_AUTH_TOKEN }} | |
- name: Get npm cache directory | |
id: npm-cache-dir | |
run: | | |
echo "::set-output name=dir::$(npm config get cache)" | |
- name: Cache node_modules π¦ | |
uses: actions/cache@v3 | |
id: npm-cache | |
with: | |
path: ${{ steps.npm-cache-dir.outputs.dir }} | |
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} | |
restore-keys: | | |
${{ runner.os }}-node- | |
- name: Install dependencies π¨π»βπ» | |
run: npm install --frozen-lockfile | |
- name: Build assets π¨π»βπ» | |
run: npm run build | |
- name: Publish Laravel assets | |
run: php artisan vendor:publish --tag=laravel-assets --ansi --force | |
- name: Publish Laravel Nova assets | |
run: php artisan vendor:publish --tag=nova-assets --ansi --force | |
- name: Clear Cache | |
run: php artisan view:clear | |
# Backend tests | |
- name: Execute PHPunit Test | |
run: php artisan test --parallel | |
# Store logs | |
- name: Store Log Artifacts | |
uses: actions/upload-artifact@v3 | |
if: failure() | |
with: | |
name: Store report artifacts | |
path: ./storage/logs |