Created
July 23, 2015 16:10
-
-
Save borjaburgos/22106410394540ca905d to your computer and use it in GitHub Desktop.
A Stackfile for a load-balanced and horizontally scalable Wordpress with volume synchronization using btsync
This file contains hidden or 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
# The load-balancer, gets deployed anywhere | |
lb: | |
image: 'tutum/haproxy:latest' | |
links: | |
- wordpress | |
ports: | |
- '80:80' | |
restart: always | |
roles: | |
- global | |
# The MySQL DB, gets deployed to a node tagged as DB | |
# Change the default "password" | |
db: | |
image: 'tutum/mysql:5.5' | |
environment: | |
- MYSQL_PASS=password | |
restart: always | |
tags: | |
- db | |
# The horizontally scaling Wordpress | |
# Follows the every_node strategy, so that it automatically scales when new | |
# nodes tagged as "wordpress" are deployed | |
# Change the default "password" | |
wordpress: | |
image: 'tutum/wordpress-stackable:latest' | |
deployment_strategy: every_node | |
environment: | |
- DB_NAME=wordpress | |
- DB_PASS=password | |
- DB_USER=admin | |
links: | |
- db | |
restart: always | |
tags: | |
- wordpress | |
volumes: | |
- /app/wp-content | |
# The BitTorrent Sync service to keep /wp-content in sync across all WPs | |
# Also follows the every_node strategy, and it's deployed alongside | |
# every wordpress container | |
btsync: | |
image: 'tutum/btsync:latest' | |
deployment_strategy: every_node | |
restart: always | |
roles: | |
- global | |
tags: | |
- wordpress | |
volumes_from: | |
- wordpress |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
does not seem to pass YML lint