docker-compose php7.1_nginx_env_docker

version: "2"

services:

  php-fpm:

      image: f286df33cd2d

      volumes:

        – /data/www/:/var/www/html/

      privileged: true

  nginx:

      image: e548f1a579cf

      volumes:

        – /data/log:/var/log/nginx

        – /data/config/nginx:/etc/nginx

        – /data/www:/usr/share/nginx/html

      ports:

        – 80:80

      privileged: true

  mysql:

      image: 9546ca122d3a

      volumes:

        – /data/www/mysql/my.cnf:/etc/mysql/my.cnf

        – /data/www/mysql/data:/var/lib/mysql

      environment:

        MYSQL_ROOT_PASSWORD: "superhero"

      ports:

        – 3306:3306

      privileged: true

  redis:

      image: 4760dc956b2d

      ports:

        – 6379:6379

      command: –requirepass "superhero"

      privileged: true