Forked from wataridori/laravel-quickstart-project-docker.md
Created
August 10, 2021 17:04
-
-
Save decodedmrq/246f538cf23149013cf32e46e148d223 to your computer and use it in GitHub Desktop.
Revisions
-
wataridori revised this gist
Oct 7, 2016 . 1 changed file with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -48,11 +48,11 @@ docker-compose up -d // Run the following command to check docker status docker ps ``` - Enter workspace container and run php commands (run **only once** when initialize the project) ``` docker exec -it project_workspace bash composer install php artisan migrate ``` - Enjoy the project at http://localhost:8000/ - To stop project, use `docker-compose down`. To start project, use `docker-compose up -d` -
wataridori revised this gist
Sep 15, 2016 . 1 changed file with 2 additions and 5 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,8 +1,7 @@ - Install Docker - Docker for Ubuntu: https://docs.docker.com/engine/installation/linux/ubuntulinux/ ``` sudo apt-get update && apt-get install -y apt-transport-https ca-certificates sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D // Open the /etc/apt/sources.list.d/docker.list and add the following line then save it @@ -11,9 +10,7 @@ // Ubuntu 16.04 deb https://apt.dockerproject.org/repo ubuntu-xenial main sudo apt-get update && apt-cache policy docker-engine && apt-get install - y linux-image-extra-$(uname -r) linux-image-extra-virtual apt-get install docker-engine sudo service docker start sudo groupadd docker sudo usermod -aG docker $USER -
wataridori revised this gist
Sep 15, 2016 . 1 changed file with 19 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,5 +1,24 @@ - Install Docker - Docker for Ubuntu: https://docs.docker.com/engine/installation/linux/ubuntulinux/ ``` sudo apt-get update sudo apt-get install apt-transport-https ca-certificates sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D // Open the /etc/apt/sources.list.d/docker.list and add the following line then save it // Ubuntu 14.04 deb https://apt.dockerproject.org/repo ubuntu-trusty main // Ubuntu 16.04 deb https://apt.dockerproject.org/repo ubuntu-xenial main sudo apt-get update && apt-cache policy docker-engine sudo apt-get install linux-image-extra-$(uname -r) linux-image-extra-virtual sudo apt-get install docker-engine sudo service docker start sudo groupadd docker sudo usermod -aG docker $USER ``` - Docker for Mac: https://docs.docker.com/docker-for-mac/#/download-docker-for-mac - Visit https://github.com/FramgiaDockerTeam/laravel-microservices for other information - Clone Laravel Quick Start Project at https://github.com/laravel/quickstart-basic -
wataridori revised this gist
Sep 15, 2016 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,7 +1,7 @@ - Install Docker - Docker for Ubuntu: https://docs.docker.com/engine/installation/linux/ubuntulinux/ - Docker for Mac: https://docs.docker.com/docker-for-mac/#/download-docker-for-mac - Visit https://github.com/FramgiaDockerTeam/laravel-microservices for other information - Clone Laravel Quick Start Project at https://github.com/laravel/quickstart-basic ``` git clone [email protected]:laravel/quickstart-basic.git -
wataridori revised this gist
Sep 15, 2016 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,3 +1,6 @@ - Install Docker - Docker for Ubuntu: https://docs.docker.com/engine/installation/linux/ubuntulinux/ - Docker for Mac: https://docs.docker.com/docker-for-mac/#/download-docker-for-mac - Visit https://github.com/FramgiaDockerTeam/laravel-microservices to other information - Clone Laravel Quick Start Project at https://github.com/laravel/quickstart-basic ``` -
wataridori renamed this gist
Sep 15, 2016 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
wataridori created this gist
Sep 15, 2016 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,39 @@ - Visit https://github.com/FramgiaDockerTeam/laravel-microservices to other information - Clone Laravel Quick Start Project at https://github.com/laravel/quickstart-basic ``` git clone [email protected]:laravel/quickstart-basic.git ``` - Move to the project folder and creat a file named `docker-compose.yml`. Copy data from https://github.com/FramgiaDockerTeam/laravel-microservices/blob/master/docker-compose.yml into that file. ``` cd quickstart-basic // You can download docker-compose.yml file using wget command wget https://raw.githubusercontent.com/FramgiaDockerTeam/laravel-microservices/master/docker-compose.yml ``` - Open `.env` file and change the `DB_HOST` and `REDIS_HOST` ``` ... // DB_HOST=127.0.0.1 DB_HOST=mysql ... // REDIS_HOST=127.0.0.1 REDIS_HOST=redis ``` - `chmod` folder `storage` and `bootstrap/cache` ``` chmod -R 777 storage chmod -R 777 bootstrap/cache ``` - Run docker and wait for about one minute ``` docker-compose up -d // Run the following command to check docker status docker ps ``` - Enter workspace container and run php command ``` docker exec -it project_workspace bash composer install php artisan migrate ``` - Enjoy the project at http://localhost:8000/