Skip to content

Commit

Permalink
taskctl tasks fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
trntv committed Feb 24, 2021
1 parent 19d626d commit 180d0dc
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 82 deletions.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ Please, consider helping project via [contributions](https://github.com/yii2-sta
- [Installation](docs/installation.md)
- [Manual installation](docs/installation.md#manual-installation)
- [Docker installation](docs/installation.md#docker-installation)
- [Vagrant installation](docs/installation.md#vagrant-installation)
- [Components documentation](docs/components.md)
- [Console commands](docs/console.md)
- [Testing](docs/testing.md)
Expand Down Expand Up @@ -54,6 +53,11 @@ Please, consider helping project via [contributions](https://github.com/yii2-sta
- Logs viewer
- System monitoring

### Development tasks
To list all available development tasks follow these steps:
1. Install [taskctl](https://github.com/taskctl/taskctl) task runner
2. Run ``taskctl``

### I18N
- Built-in translations:
- English
Expand Down
74 changes: 0 additions & 74 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

19 changes: 12 additions & 7 deletions taskctl.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ pipelines:
- build:env
- install
- task: docker:start
depends_on: build
depends_on: docker:build
- task: banner
depends_on: docker:start

docker:tests:
- task: docker:start
Expand All @@ -36,7 +38,7 @@ tasks:
heroku:compile:
command:
- cp deploy/heroku/.env .env
- php console/yii migrate/fresh --interactive=0
- php console/yii migrate/fresh
- php console/yii app/setup --interactive=0
env:
YII_ENV: heroku
Expand All @@ -48,21 +50,20 @@ tasks:

docker:build:
command:
- docker-compose run -T --rm app composer run-script php console/yii app/setup --interactive=0
- docker-compose run -T --rm webpacker npm i npm@latest -g
- docker-compose run -T --rm webpacker npm install
- docker-compose run -T --rm app php console/yii app/setup --interactive=0
- docker-compose run -T --rm webpacker npm run build

docker:tests:run:
command:
- docker-compose exec -T db mysql -uroot -proot -e \"CREATE DATABASE IF NOT EXISTS \\`yii2-starter-kit-test\\` CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci\"
- docker-compose exec -T db mysql -uroot -proot -e "CREATE DATABASE IF NOT EXISTS \`yii2-starter-kit-test\` CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;"
- docker-compose exec -T app ./vendor/bin/codecept build
- docker-compose exec -T app php tests/bin/yii app/setup --interactive=0
- docker-compose exec -T app vendor/bin/codecept run
- echo "Done!"

docker:tests:server:
command:
- docker-compose exec -T app php -S localhost:8080
- docker-compose exec -T app php -S localhost:8080 -t /app

docker:start:
command:
Expand All @@ -71,3 +72,7 @@ tasks:
docker:cleanup:
command:
- docker-compose rm -fsv

banner:
command:
- echo "Started! Visit http://yii2-starter-kit.localhost"

0 comments on commit 180d0dc

Please sign in to comment.