k8s-manifests/ops/110-proxysql
2026-07-23 15:54:27 +08:00
..
00-host-mysql-entrypoints.yaml deploy: add 110 proxysql canary manifests 2026-07-23 15:02:21 +08:00
10-proxysql.yaml fix: use preloaded proxysql image on 110 2026-07-23 15:07:16 +08:00
20-production-entrypoint.yaml deploy: cut 110 mysql entrypoint to proxysql 2026-07-23 15:54:27 +08:00
create-config-secret.sh deploy: add proxysql secret renderer for 110 2026-07-23 15:17:02 +08:00
proxysql.cnf.template deploy: add 110 proxysql canary manifests 2026-07-23 15:02:21 +08:00
README.md deploy: add 110 proxysql host canary entrypoint 2026-07-23 15:53:07 +08:00

110 ProxySQL canary

This directory contains the manually applied ProxySQL resources for the 10.10.11.110 production cluster. The topology matches the 10.10.11.10 cluster: MySQL runs natively on the hosts and two stateless ProxySQL pods run in Kubernetes.

Backends

Hostgroup Role Endpoint
10 Writer 192.168.110.208:3316
20 Reader 1 192.168.110.73:3306
20 Reader 2 192.168.110.13:3306
excluded Backup replica 192.168.110.64:3306

The writer is also present in hostgroup 20 at weight 1, matching the existing 10-cluster configuration. The backup replica is deliberately excluded from ProxySQL traffic.

The worker-local ProxySQL image tag is imported from and must match registry manifest digest sha256:7082d349bfe4e9ac7341bd43833ef085bac6b414a7a3d58bdb6f58c5887cccaf (image config ID sha256:77bfbfc3d21c173bab94768b49bebc932d4f6ffd829437d362202851ebfbed9b). The tag-only reference avoids a runtime pull because the registry is HTTP and the production Docker daemons are not restarted to change registry settings.

Deployment safety

Create proxysql-prd-config from proxysql.cnf.template outside Git. Replace both password placeholders and never commit the rendered file. Apply the selectorless MySQL Services first, then the ProxySQL Deployment and canary Service.

./create-config-secret.sh prd ./proxysql.cnf.template /path/to/mysql-password
kubectl apply -f 00-host-mysql-entrypoints.yaml
kubectl apply -f 10-proxysql.yaml

Use 20-production-entrypoint.yaml first with the temporary external port 192.168.110.208:14006. After SQL routing passes, change that same Service to port 4006, stop maxscale-container, and apply the pushed production revision. Existing clients keep their original 192.168.110.208:4006 configuration.

Rollback uses the pushed 14006 revision to remove the Service's 4006 mapping, followed by docker start maxscale-container.