Open atulmy opened 4 years ago
I've the following additional 3 services with following configuration:
version: "3" volumes: CONFD: VHOSTD: NGINX-HTML: services: nginx: image: nginx ports: - 80:80 - 443:443 - 5000:5000 ... nginx-gen: image: jwilder/docker-gen ... letsencrypt-nginx-proxy-companion: image: jrcs/letsencrypt-nginx-proxy-companion ... api: image: api build: ./api expose: - 3000 environment: - VIRTUAL_HOST=api.example.com - VIRTUAL_NETWORK=nginx-proxy - VIRTUAL_PORT=3000 - LETSENCRYPT_HOST=api.example.com - LETSENCRYPT_EMAIL=email@example.com web: image: web build: ./web expose: - 4000 environment: - VIRTUAL_HOST=web.example.com - VIRTUAL_NETWORK=nginx-proxy - VIRTUAL_PORT=4000 - LETSENCRYPT_HOST=web.example.com - LETSENCRYPT_EMAIL=email@example.com admin: restart: always image: admin build: ./admin expose: - 5000
I want to map domains to api and web, however for admin, I'd just like to run it on IP:PORT (eg: http://178.10.10.5:5000)
api
web
admin
http://178.10.10.5:5000
Is there a way to do this?
The default.conf should contain following to make it work:
default.conf
# rest of automatically generated nginx code by nginx.tmpl upstream admin { server admin:5000; } server { listen 5000; listen [::]:5000; location / { proxy_pass http://admin; } }
Any help would be highly appreciated!
CC: @gilyes, just wanted to get your help on this
I've the following additional 3 services with following configuration:
I want to map domains to
api
andweb
, however foradmin
, I'd just like to run it on IP:PORT (eg:http://178.10.10.5:5000
)Is there a way to do this?
The
default.conf
should contain following to make it work:Any help would be highly appreciated!