Add Dockerfile

The Dockerfile is used to build a Docker image with all MaxScale
dependencied included. A short readme for using the image is attached.
This commit is contained in:
Esa Korhonen
2017-08-15 10:30:19 +03:00
parent 8b08d61487
commit e2fb5b4ddf
4 changed files with 271 additions and 0 deletions

View File

@ -0,0 +1,61 @@
# Server definitions
# Set the address of the server to the network address of a MySQL server.
[server1]
type=server
address=127.0.0.1
port=3306
protocol=MySQLBackend
# Monitor for the servers
# This will keep MaxScale aware of the state of the servers.
# MySQL Monitor documentation:
# https://github.com/mariadb-corporation/MaxScale/blob/develop/Documentation/Monitors/MySQL-Monitor.md
[MySQL-Monitor]
type=monitor
module=mysqlmon
servers=server1
user=myuser
passwd=mypwd
monitor_interval=1000
# Service definitions
# Service Definition for a read-only service and a read/write splitting service.
# ReadConnRoute documentation:
# https://github.com/mariadb-corporation/MaxScale/blob/develop/Documentation/Routers/ReadConnRoute.md
[Read-Only-Service]
type=service
router=readconnroute
servers=server1
user=myuser
passwd=mypwd
router_options=slave
# ReadWriteSplit documentation:
# https://github.com/mariadb-corporation/MaxScale/blob/develop/Documentation/Routers/ReadWriteSplit.md
[Read-Write-Service]
type=service
router=readwritesplit
servers=server1
user=myuser
passwd=mypwd
max_slave_connections=100%
# Listener definitions for the services
# Listeners represent the ports the services will listen on.
[Read-Only-Listener]
type=listener
service=Read-Only-Service
protocol=MySQLClient
port=4008
[Read-Write-Listener]
type=listener
service=Read-Write-Service
protocol=MySQLClient
port=4006