Last active
December 9, 2017 18:26
-
-
Save cgiovanii/dc7d57d2f814f7d73f1c2034e73bb2d8 to your computer and use it in GitHub Desktop.
Docker LAMP Server - Apache2+Php7+MySql5+PhpMyAdmin+Portainer #Docker #LAMP
This file contains 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 characters
version: '2' | |
services: | |
webserver: | |
depends_on: | |
- db | |
image: php:7-apache | |
container_name: Apache2-PHP7 | |
restart: always | |
volumes: | |
- ./public_html:/var/www/html/ | |
# - ./conf/apache2/httpd.conf:/usr/local/apache2/conf/httpd.conf ### vhost config file | |
# - ./conf/apache2/vhosts/httpd-vhosts.conf:/usr/local/apache2/conf/extra/httpd-vhosts.conf | |
# - ./conf/apache2/logs/error.log:/usr/local/apache2/logs/error.log | |
# - ./conf/apache2/logs/access.log:/usr/local/apache2/logs/access.log | |
ports: | |
- 8000:80 # Expose http and https | |
- 4000:443 | |
networks: | |
- damp7 | |
db: | |
image: mysql:latest | |
container_name: MySQL5.7 | |
restart: always | |
volumes: | |
- ./mysql_data:/var/lib/mysql | |
ports: | |
- 3308:3306 | |
environment: | |
MYSQL_ROOT_PASSWORD: password | |
networks: | |
- damp7 | |
pma: | |
depends_on: | |
- db | |
image: phpmyadmin/phpmyadmin | |
container_name: PHPMyAdmin | |
restart: always | |
ports: | |
- 8001:80 | |
environment: | |
PMA_HOST: db | |
MYSQL_ROOT_PASSWORD: password | |
networks: | |
- damp7 | |
portainer: | |
image: portainer/portainer:latest | |
container_name: Portainer | |
command: -H unix:///var/run/docker.sock | |
volumes: | |
- /var/run/docker.sock:/var/run/docker.sock | |
- ./conf/portainer_data:/data | |
ports: | |
- 9001:9000 | |
networks: | |
- damp7 | |
networks: | |
damp7: | |
volumes: | |
mysql_data: |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment