This repository has been archived by the owner on Aug 20, 2024. It is now read-only.
forked from evertramos/docker-wordpress
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
6f68b89
commit 7e9963d
Showing
2 changed files
with
58 additions
and
53 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,8 +16,10 @@ NETWORK=webproxy | |
# | ||
# Database Container options | ||
# | ||
# [IMPORTANT] We recommend to always set a version when starting a new site. | ||
# When migrating or restoring a backup you must know the running version | ||
|
||
# Database image (mariadbmysql) | ||
# Database image (mariadb|mysql) | ||
DB_IMAGE=mariadb | ||
|
||
# Database version | ||
|
@@ -38,25 +40,27 @@ MYSQL_USER=user_name | |
MYSQL_PASSWORD=user_password | ||
|
||
# | ||
# Wordpress Container options | ||
# | ||
|
||
# Wordpress version | ||
# Site Container options | ||
# | ||
# [IMPORTANT] We recommend to always set a version when starting a new site. | ||
# When migrating or restoring a backup you must know the running version for | ||
# theme and plugins compatibility. | ||
WP_VERSION=latest | ||
|
||
# Wordpress container name | ||
CONTAINER_WP_NAME=new-site-site | ||
# Site Image (wordpress) | ||
SITE_IMAGE=wordpress | ||
|
||
# Site Version | ||
SITE_VERSION=latest | ||
|
||
# Path to store your site files | ||
SITE_FILES=./data/site | ||
|
||
# Site container name | ||
CONTAINER_SITE_NAME=new-site-site | ||
|
||
# Max Log File Size | ||
LOGGING_OPTIONS_MAX_SIZE=200k | ||
|
||
# Path to store your wordpress files | ||
WP_FILES=./data/site | ||
|
||
# Table prefix | ||
WORDPRESS_TABLE_PREFIX=wp_ | ||
|
||
|
@@ -65,3 +69,4 @@ DOMAINS=domain.com,www.domain.com | |
|
||
# Your email for Let's Encrypt register | ||
LETSENCRYPT_EMAIL=[email protected] | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,49 +1,49 @@ | ||
version: '3' | ||
|
||
services: | ||
new-site-db: | ||
container_name: ${CONTAINER_DB_NAME} | ||
image: ${DB_IMAGE:-mariadb}:${DB_VERSION:-latest} | ||
restart: unless-stopped | ||
volumes: | ||
- ${DB_FILES}:/var/lib/mysql | ||
environment: | ||
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD} | ||
MYSQL_DATABASE: ${MYSQL_DATABASE} | ||
MYSQL_USER: ${MYSQL_USER} | ||
MYSQL_PASSWORD: ${MYSQL_PASSWORD} | ||
new-site-db: | ||
container_name: ${CONTAINER_DB_NAME} | ||
image: ${DB_IMAGE:-mariadb}:${DB_VERSION:-latest} | ||
restart: unless-stopped | ||
volumes: | ||
- ${DB_FILES}:/var/lib/mysql | ||
environment: | ||
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD} | ||
MYSQL_DATABASE: ${MYSQL_DATABASE} | ||
MYSQL_USER: ${MYSQL_USER} | ||
MYSQL_PASSWORD: ${MYSQL_PASSWORD} | ||
|
||
new-site-wordpress: | ||
depends_on: | ||
- new-site-db | ||
container_name: ${CONTAINER_WP_NAME} | ||
image: wordpress:${WP_VERSION:-latest} | ||
restart: unless-stopped | ||
volumes: | ||
- ${WP_FILES}:/var/www/html | ||
- ./conf.d/php.ini:/usr/local/etc/php/conf.d/php.ini | ||
environment: | ||
WORDPRESS_DB_HOST: ${CONTAINER_DB_NAME}:3306 | ||
WORDPRESS_DB_NAME: ${MYSQL_DATABASE} | ||
WORDPRESS_DB_USER: ${MYSQL_USER} | ||
WORDPRESS_DB_PASSWORD: ${MYSQL_PASSWORD} | ||
WORDPRESS_TABLE_PREFIX: ${WORDPRESS_TABLE_PREFIX} | ||
VIRTUAL_HOST: ${DOMAINS} | ||
LETSENCRYPT_HOST: ${DOMAINS} | ||
LETSENCRYPT_EMAIL: ${LETSENCRYPT_EMAIL} | ||
logging: | ||
options: | ||
max-size: ${LOGGING_OPTIONS_MAX_SIZE:-200k} | ||
new-site-wordpress: | ||
depends_on: | ||
- new-site-db | ||
container_name: ${CONTAINER_SITE_NAME} | ||
image: ${SITE_IMAGE:-wordpress}:${SITE_VERSION:-latest} | ||
restart: unless-stopped | ||
volumes: | ||
- ${SITE_FILES}:/var/www/html | ||
- ./conf.d/php.ini:/usr/local/etc/php/conf.d/php.ini | ||
environment: | ||
WORDPRESS_DB_HOST: ${CONTAINER_DB_NAME}:3306 | ||
WORDPRESS_DB_NAME: ${MYSQL_DATABASE} | ||
WORDPRESS_DB_USER: ${MYSQL_USER} | ||
WORDPRESS_DB_PASSWORD: ${MYSQL_PASSWORD} | ||
WORDPRESS_TABLE_PREFIX: ${WORDPRESS_TABLE_PREFIX} | ||
VIRTUAL_HOST: ${DOMAINS} | ||
LETSENCRYPT_HOST: ${DOMAINS} | ||
LETSENCRYPT_EMAIL: ${LETSENCRYPT_EMAIL} | ||
logging: | ||
options: | ||
max-size: ${LOGGING_OPTIONS_MAX_SIZE:-200k} | ||
|
||
wpcli: | ||
image: tatemz/wp-cli | ||
volumes: | ||
- ${WP_FILES}:/var/www/html | ||
depends_on: | ||
- new-site-db | ||
entrypoint: wp | ||
wpcli: | ||
image: tatemz/wp-cli | ||
volumes: | ||
- ${SITE_FILES}:/var/www/html | ||
depends_on: | ||
- new-site-db | ||
entrypoint: wp | ||
|
||
networks: | ||
default: | ||
external: | ||
name: ${NETWORK} | ||
default: | ||
external: | ||
name: ${NETWORK} |