stremio-beamup
stremio-beamup copied to clipboard
self-configuring NGINX as a docker image
NOTE: if the rust proxy that Martin is working on comes before this, the same needs to be done, but for it rather than for NGINX
Rather than configuring NGINX via swarm-syncer
, make it a Docker image that configures itself, similar to nginx-proxy.
The reason we can't use nginx-proxy itself is that it configures based on running containers, while we need it to configure based on running services (using the /services
API endpoint): see the beamup-sync-swarm
script itself. However, this can still be done.
An added benefit from this is that we automatically scale it to all swarm nodes by using mode: global
Important: we need to mount an external cache directory, so that NGINX cache is persistent