This example create a environment facilitate you can run your project in server.
About laravel
it just create environment not exec any command to help you deploy automatically.
About nuxtjs
it auto generate and start app. Then when update nuxtjs
src you need rebuild docker image.
- You need to clone example files.
cp ./.env.example ./.env
cp ./docker-compose.example.yml ./docker-compose.yml
cp -r ./nginx/ssl-example ./nginx/ssl
Then change them to your tailored configs. You can ignore update ssl files.
- Clone your laravel and nuxtjs.
Clone it accordingly to ./laravel/src
and ./nuxtjs/src
- Config nuxtjs
Normally you would set private laravel url (local url to laravel) to http://nginx:8000
- Run your project
docker-compose up -d
- Instantiate laravel
docker-compose exec laravel composer install --ignore-platform-reqs
docker-compose exec laravel php artisan key:generate -n
docker-compose exec laravel php artisan optimize
docker-compose exec laravel php artisan migrate --seed
docker-compose exec laravel php artisan storage:link
- Update
laravel
, then we just exec needed. - Update
Nuxtjs
, then we need just below command.
docker-compose down
docker-compose build --no-cache nuxtjs
docker-compose up -d