Simplifying laravel-mysql example
This commit is contained in:
parent
9e33c7b24e
commit
e8af2cb78d
@ -21,13 +21,13 @@ jobs:
|
|||||||
MYSQL_ROOT_PASSWORD: password
|
MYSQL_ROOT_PASSWORD: password
|
||||||
MYSQL_DATABASE: laravel
|
MYSQL_DATABASE: laravel
|
||||||
ports:
|
ports:
|
||||||
- 3306/tcp
|
- 3306:3306
|
||||||
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3
|
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3
|
||||||
|
|
||||||
redis:
|
redis:
|
||||||
image: redis
|
image: redis
|
||||||
ports:
|
ports:
|
||||||
- 6379/tcp
|
- 6379:6379
|
||||||
options: --health-cmd="redis-cli ping" --health-interval=10s --health-timeout=5s --health-retries=3
|
options: --health-cmd="redis-cli ping" --health-interval=10s --health-timeout=5s --health-retries=3
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
@ -45,9 +45,6 @@ jobs:
|
|||||||
extensions: mbstring, dom, fileinfo, mysql
|
extensions: mbstring, dom, fileinfo, mysql
|
||||||
coverage: xdebug
|
coverage: xdebug
|
||||||
|
|
||||||
- name: Start mysql service
|
|
||||||
run: sudo systemctl start mysql
|
|
||||||
|
|
||||||
- name: Get composer cache directory
|
- name: Get composer cache directory
|
||||||
id: composer-cache
|
id: composer-cache
|
||||||
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
|
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
|
||||||
@ -74,12 +71,6 @@ jobs:
|
|||||||
|
|
||||||
- name: Run Migration
|
- name: Run Migration
|
||||||
run: php artisan migrate -v
|
run: php artisan migrate -v
|
||||||
env:
|
|
||||||
DB_PORT: ${{ job.services.mysql.ports['3306'] }}
|
|
||||||
REDIS_PORT: ${{ job.services.redis.ports['6379'] }}
|
|
||||||
|
|
||||||
- name: Test with phpunit
|
- name: Test with phpunit
|
||||||
run: vendor/bin/phpunit --coverage-text
|
run: vendor/bin/phpunit --coverage-text
|
||||||
env:
|
|
||||||
DB_PORT: ${{ job.services.mysql.ports['3306'] }}
|
|
||||||
REDIS_PORT: ${{ job.services.redis.ports['6379'] }}
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user