36 lines
647 B
YAML
36 lines
647 B
YAML
---
|
|
# Sample Docker Compose File
|
|
|
|
version: "3.3"
|
|
|
|
volumes:
|
|
db:
|
|
|
|
networks:
|
|
default:
|
|
external:
|
|
name: ${NETWORKNAME}
|
|
|
|
services:
|
|
|
|
db:
|
|
image: mariadb:latest
|
|
restart: always
|
|
container_name: "${DBHOST}"
|
|
environment:
|
|
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
|
|
MYSQL_PASSWORD: ${DBPASSWORD}
|
|
MYSQL_DATABASE: ${DB}
|
|
MYSQL_USER: ${DBUSER}
|
|
volumes:
|
|
- "db:/var/lib/mysql"
|
|
|
|
php-app:
|
|
container_name: "${DOCKERNAME}"
|
|
image: "4lights/phpcontainer:latest"
|
|
restart: always
|
|
volumes:
|
|
- "./:/data"
|
|
- ./php.ini:/usr/local/etc/php/php.ini
|
|
ports:
|
|
- "${DOCKERPORT}:80" |