Skip to content

alienwebvision/curso-laravel-9

Repository files navigation

Setup Docker Para Projetos Laravel 9 com PHP 8

Assine a Academy, e Seja VIP!

Passo a passo

Clone Repositório

git clone https://github.com/especializati/setup-docker-laravel.git laravel9
cd laravel9/

Alterne para a branch laravel 8.x

git checkout laravel-9-com-php-8

Remova o versionamento

rm -rf .git/

Crie o Arquivo .env

cd example-project/
cp .env.example .env

Atualize as variáveis de ambiente do arquivo .env

APP_NAME=EspecializaTi
APP_URL=http://localhost:8180

DB_CONNECTION=mysql
DB_HOST=mysql
DB_PORT=3306
DB_DATABASE=nome_que_desejar_db
DB_USERNAME=root
DB_PASSWORD=root

CACHE_DRIVER=redis
QUEUE_CONNECTION=redis
SESSION_DRIVER=redis

REDIS_HOST=redis
REDIS_PASSWORD=null
REDIS_PORT=6379

Suba os containers do projeto

docker-compose up -d

Acessar o container

docker-compose exec app bash

Instalar as dependências do projeto

composer install

Gerar a key do projeto Laravel

php artisan key:generate

Acesse o projeto http://localhost:8989

Releases

No releases published

Packages

No packages published

Languages