Use latest install ffmpeg action #26
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: Tests | |
on: | |
push: | |
branches: | |
- "main" | |
pull_request: | |
types: [opened, synchronize, reopened] | |
jobs: | |
phpunit: | |
name: Tests PHP ${{ matrix.php }} | |
runs-on: ubuntu-latest | |
container: | |
image: klinktechnology/k-box-ci-pipeline-php:${{ matrix.php }} | |
options: --user root | |
services: | |
mariadb: | |
image: mariadb:10.6 | |
env: | |
MYSQL_DATABASE: laravel | |
MYSQL_USER: sail | |
MYSQL_ROOT_PASSWORD: "password" | |
MYSQL_PASSWORD: "password" | |
MYSQL_ALLOW_EMPTY_PASSWORD: 'yes' | |
ports: | |
- 3306 | |
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 | |
strategy: | |
fail-fast: true | |
matrix: | |
php: [8.1] | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 1 | |
- name: Cache PHP dependencies | |
uses: actions/cache@v1 | |
with: | |
path: ~/.composer/cache/files | |
key: dependencies-php-${{ matrix.php }}-composer-${{ hashFiles('composer.json') }} | |
- name: Cache JS dependencies | |
uses: actions/cache@v1 | |
with: | |
path: ~/.yarn/ | |
key: dependencies-js-${{ hashFiles('yarn.lock') }} | |
- name: Install FFmpeg | |
uses: Iamshankhadeep/[email protected] | |
with: | |
version: 6.0 | |
id: setup-ffmpeg | |
- name: Install dependencies | |
run: | | |
cp .env.example .env | |
composer install --prefer-dist | |
yarn config set cache-folder ~/.yarn/ | |
yarn install --link-duplicates | |
yarn build | |
- name: Run tests | |
run: | | |
php artisan key:generate | |
php artisan view:clear | |
php artisan config:clear | |
php artisan route:clear | |
./vendor/bin/phpunit --stop-on-error --stop-on-failure --filter=ConvertVideo | |
env: | |
FFMPEG_TEMPORARY_FILES_ROOT: ${{ github.workspace }} | |
DB_HOST: mariadb | |
DB_USERNAME: sail | |
DB_PASSWORD: password | |