Hi,
I’m setting up a custom Wordpress build as the catalogue version has some issues with the way I’m using it.
So I’ve used the standard docker Wordpress and MariaDB images, and it’s working fine.
When I add the standard load-balancer in front of it, I get 503 errors. Can anyone help me get to the bottom of this please? I’ve tried every combination I can think of for mapping ports, with no resolution.
docker-compose.yml
version: '2’
services:
mariadb:
image: mariadb
environment:
MYSQL_ROOT_PASSWORD: XXXX
MYSQL_DATABASE: wordpress
MYSQL_USER: root
MYSQL_PASSWORD: XXXX
stdin_open: true
tty: true
labels:
io.rancher.container.pull_image: always
wordpress-lb:
image: rancher/lb-service-haproxy:v0.7.15
ports:
- 80:80/tcp
labels:
io.rancher.container.agent.role: environmentAdmin,agent
io.rancher.container.agent_service.drain_provider: 'true’
io.rancher.container.create_agent: 'true’
wordpress:
image: wordpress
environment:
WORDPRESS_DB_HOST: mariadb
WORDPRESS_DB_USER: XXXX
WORDPRESS_DB_PASSWORD: XXXXX
WORDPRESS_DB_NAME: wordpress
stdin_open: true
tty: true
labels:
io.rancher.container.pull_image: always
rancher-compose.yml
version: '2’
services:
mariadb:
scale: 1
start_on_create: true
wordpress-lb:
scale: 1
start_on_create: true
lb_config:
certs: []
port_rules:
- hostname: XXXX.com
path: ''
priority: 1
protocol: http
service: wordpress/wordpress
source_port: 80
target_port: 80
health_check:
healthy_threshold: 2
response_timeout: 2000
port: 42
unhealthy_threshold: 3
initializing_timeout: 60000
interval: 2000
reinitializing_timeout: 60000
wordpress:
scale: 1
start_on_create: true