Skip to content

Instantly share code, notes, and snippets.

@KazunagaIida
Created April 29, 2017 08:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save KazunagaIida/053b919c24ea8aaac2ca9211c3f34e7a to your computer and use it in GitHub Desktop.
Save KazunagaIida/053b919c24ea8aaac2ca9211c3f34e7a to your computer and use it in GitHub Desktop.
Dockerで超簡単にlaravel環境を構築する方法 ref: http://qiita.com/kiida510/items/cc31453f8034ceb73487
$ docker --version
$ docker-compose --version
$ docker-machine --version
### Applications Code Container #############################
applications:
image: tianon/true
volumes:
## 変更前
#- ${APPLICATION}:/var/www
## 変更後
- ../ProjectName/:/var/www/ProjectName
### Nginx Server Container ##################################
nginx:
build:
context: ./nginx
args:
- PHP_UPSTREAM=php-fpm
volumes_from:
- applications
volumes:
- ${NGINX_HOST_LOG_PATH}:/var/log/nginx
- ${NGINX_SITES_PATH}:/etc/nginx/sites-available
ports:
## 変更前
#- "${NGINX_HOST_HTTP_PORT}:80"
## 変更後
- "8080:80"
## 変更前
#- "${NGINX_HOST_HTTPS_PORT}:443"
## 変更後
- "443:443"
depends_on:
- php-fpm
networks:
- frontend
- backend
## 変更前
#root /var/www/public;
## 変更後
root /var/www/ProjectName/public;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment