# Documentation for docker deployment?

**URL:** <https://forums.percona.com/t/documentation-for-docker-deployment/37522>\
**Category:** ProxySQL\
**Created:** [April 7, 2025, 6:39pm UTC](https://forums.percona.com/t/documentation-for-docker-deployment/37522 "2025-04-07T18:39:46Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Bolk](https://avatars.discourse-cdn.com/v4/letter/b/2bfe46/32.png) [@Bolk](https://forums.percona.com/u/Bolk)\
**Post date:** [April 7, 2025, 6:39pm UTC](https://forums.percona.com/t/documentation-for-docker-deployment/37522/1 "2025-04-07T18:39:46Z")

</div>

Hi,

I have PXC running on a docker swarm cluster and I’d like to add proxysql2 for read/write splitting. However I cannot find any documentation on this. In a perfect world, the proxysql container would be stateless but I have no idea where to start. Can I use environment var’s for this? If somebody can point me into the right direction that would be highly appreciated! Thanks

---

<div class="post-metadata">

**Author:** ![matthewb](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/matthewb/32/34_2.png) [@matthewb](https://forums.percona.com/u/matthewb)\
**Post date:** [April 8, 2025, 11:51am UTC](https://forums.percona.com/t/documentation-for-docker-deployment/37522/2 "2025-04-08T11:51:10Z")

</div>

Hi @Bolk,  
ProxySQL is configured via `/etc/proxysql.cnf` on first boot. ProxySQL has no knowledge of your environment on startup. You must configure knowledge of the PXC hosts, user accounts, and any routing rules. ProxySQL does not ‘auto discover’ anything about your network/topology.

I understand you said Docker Swarm, but have you considered (and I can’t believe I’m saying this…) Kubernetes? We have a native K8S operator for PXC that manages the pods, and manages ProxySQL as well.

---

<div class="post-metadata">

**Author:** ![Bolk](https://avatars.discourse-cdn.com/v4/letter/b/2bfe46/32.png) [@Bolk](https://forums.percona.com/u/Bolk)\
**Post date:** [April 9, 2025, 9:35am UTC](https://forums.percona.com/t/documentation-for-docker-deployment/37522/3 "2025-04-09T09:35:01Z")

</div>

Thanks Matthew, this helps. I agree that K8s is the way to go.

---

<div class="post-metadata">

**Author:** ![matthewb](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/matthewb/32/34_2.png) [@matthewb](https://forums.percona.com/u/matthewb)\
**Post date:** [April 9, 2025, 12:00pm UTC](https://forums.percona.com/t/documentation-for-docker-deployment/37522/4 "2025-04-09T12:00:15Z")

</div>

You might look at some more light-weight options like [GitHub - k3s-io/k3s: Lightweight Kubernetes](https://github.com/k3s-io/k3s) as K8S can be extremely overwhelming. Good Luck!

---

<div class="post-metadata">

**Author:** ![Bolk](https://avatars.discourse-cdn.com/v4/letter/b/2bfe46/32.png) [@Bolk](https://forums.percona.com/u/Bolk)\
**Post date:** [April 10, 2025, 7:27am UTC](https://forums.percona.com/t/documentation-for-docker-deployment/37522/5 "2025-04-10T07:27:39Z")

</div>

Yep thanks for the tip. I am running cluster based on k3s now.
