mironov
606132d040
Reviewed-on: #2 |
||
---|---|---|
backend | ||
common | ||
console | ||
docker | ||
environments | ||
frontend | ||
vagrant | ||
.bowerrc | ||
.gitignore | ||
LICENSE.md | ||
README.md | ||
Vagrantfile | ||
codeception.yml | ||
composer.json | ||
composer.lock | ||
docker-compose.yml | ||
init | ||
init.bat | ||
requirements.php | ||
yii.bat |
README.md
Support WebEffector.ru
CodeStyle
DataBase => kebab_style
PHP => camelCaseStyle
Starting
Stack:
- php 8.1.27
- mysql 8
- Docker docker.com
Docker
Init:
docker-compose run --rm php ./init --env=Development --overwrite
Composer install:
docker-compose run --rm php composer install
Run Yii migrations:
Init application
docker-compose run --rm php ./yii migrate 2
Init RBAC
docker-compose run --rm php ./yii migrate 4 --migrationPath=@yii/rbac/migrations
Migrate other
docker-compose run --rm php ./yii migrate
Dump:
docker ps
docker exec -it номер_контейнера_mysql bash
mysql -u root -proot db_name < /dump/dump.sql
Use
Hosts:
127.0.0.1 web.local
127.0.0.1 admin.web.local
Up:
docker-compose up -d
Down:
docker-compose down
ReBuild without a cache:
docker-compose build --no-cache php
Url dev:
frontend: web.local
backend: admin.web.local
Url stage:
frontend: example.webeffector.ru
backend: admin-example.webeffector.ru
Test data for stage/dev:
- Администратор admin@web.local:admin
- Менеджер manager@web.local:manager
- Пользователь user@web.local:user