How to correctly specify the address and port of the apt-cacher-ng server?

When using snapcraft + LXD, I want to use my apt-cacher-ng on a local network.

How to correctly specify the address and port of the apt-cacher-ng server inside the container created by snapcraft?