45 lines
1.2 KiB
YAML
45 lines
1.2 KiB
YAML
# documentation: https://gitamin.ir/smx/ifosspress
|
|
# slogan: A brief description of your service.
|
|
# tags: tag1,tag2,tag3
|
|
# logo: svgs/your-service.svg
|
|
# port: 80
|
|
|
|
services:
|
|
wordpress:
|
|
build: .
|
|
volumes:
|
|
- 'wordpress-files:/var/www/html'
|
|
- 'wp-config.php /var/www/html/wp-config.php'
|
|
- 'wp-content/plugins /var/www/html/wp-content/plugins'
|
|
- 'wp-content/themes /var/www/html/wp-content/themes'
|
|
environment:
|
|
- WORDPRESS_DB_HOST=mariadb
|
|
- WORDPRESS_DB_USER=${SERVICE_USER_WORDPRESS}
|
|
- WORDPRESS_DB_PASSWORD=${SERVICE_PASSWORD_WORDPRESS}
|
|
- WORDPRESS_DB_NAME=${SERVICE_DB_NAME}
|
|
depends_on:
|
|
- mariadb
|
|
|
|
nginx:
|
|
image: nginx:alpine
|
|
depends_on:
|
|
- wordpress
|
|
volumes:
|
|
- 'wordpress-files:/var/www/html'
|
|
- './nginx/default.conf:/etc/nginx/conf.d/default.conf'
|
|
ports:
|
|
- "80:80"
|
|
|
|
mariadb:
|
|
image: mariadb:11
|
|
volumes:
|
|
- 'mariadb-data:/var/lib/mysql'
|
|
environment:
|
|
- MYSQL_ROOT_PASSWORD=${SERVICE_PASSWORD_ROOT}
|
|
- MYSQL_DATABASE=${SERVICE_DB_NAME}
|
|
- MYSQL_USER=${SERVICE_USER_WORDPRESS}
|
|
- MYSQL_PASSWORD=${SERVICE_PASSWORD_WORDPRESS}
|
|
|
|
volumes:
|
|
wordpress-files:
|
|
mariadb-data: |