Commit 7285e334 authored by Mahmoud Zalt's avatar Mahmoud Zalt

add the docker compose file and the settings

parent a5954594
# PHP + NGINX Container #----------------------------------
phpn-ginx:
image: mahmoudz/lara-phpnginx
container_name: php-nginx
ports:
- "80:80"
volumes:
- ./settings/nginx:/etc/nginx/sites-available
- ../laravel:/var/www
- ./logs/nginx:/var/log/nginx
links:
- mysql
- redis
- beanstalkd
privileged: true
# MySQL Container #----------------------------------------
mysql:
image: mahmoudz/lara-mysql
container_name: mysql
ports:
- "3306:3306"
volumes_from:
- mysql-data
environment:
MYSQL_DATABASE: laravel-database
MYSQL_USER: root
MYSQL_PASSWORD: pass
privileged: true
# MySQL Data Volume Container #----------------------------
mysql-data:
image: mahmoudz/lara-data
container_name: mysql-data
volumes:
- /var/lib/mysql
# Redis Container #----------------------------------------
redis:
image: mahmoudz/lara-redis
container_name: redis
ports:
- "6379:6379"
privileged: true
# Beanstalkd Container #-----------------------------------
beanstalkd:
image: mahmoudz/lara-beanstalkd
container_name: beanstalkd
ports:
- "11300:11300"
privileged: true
#----------------------------------------------------------
server {
listen 80 default_server;
listen [::]:80 default_server ipv6only=on;
root /var/www/public;
index index.php index.html index.htm;
server_name localdock localdock.dev;
location / {
try_files $uri $uri/ /index.php$is_args$args;
}
location ~ \.php$ {
try_files $uri /index.php =404;
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
location ~ /\.ht {
deny all;
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment