This is a demo using Docker and Laravel. Data is stored here permanently
- Install
docker
anddocker-compose
- clone this project
- cd into the folder
- runn
cp my-project/.env.example my-project/.env
- run
docker-compose up --build -d
(grab a coffee, this will take some time) - run
docker-compose exec app rm -rf vendor composer.lock
- run
docker-compose exec app composer install
- run
docker-compose exec app php artisan key:generate
- run
docker-compose exec app php artisan migrate
<< Wait for mysql to be ready
- execude any command inside the app container
docker-compose exec <command>
- run artisan commands with
docker-compose exec app php artisan <command>
- run tests with
docker-compose exec app php artisan test
- access database with
docker-compose exec mariadb mysql
user: bis@bis.de
password: please_change_me!
follow these steps if you have permission issues running the container
sudo groupadd docker
(if group not already exist)sudo usermod -aG docker $USER
-> adds your user to the groupnewgrp docker
- try to run again
- if there is still an error, try reboot