Reputation: 2711
So if I run ngrok outside of docker, the tunnel connects fine. However when I add it to my docker-compose up i get
failed to complete tunnel connection
Here is my docker-compose:
services:
local.box:
image: nginx:1.21
ports:
- "8888:80"
volumes:
- .:/app
ngrok:
image: ngrok/ngrok:alpine
depends_on:
- local.box
environment:
- NGROK_AUTHTOKEN=<my_token>
command: "http local.box:8888"
volumes:
- .:/app
networks:
default:
name: dev-dev
external: true
I have tried host header rewrites, as well as editing my nginx.conf to not use default server. The nginx stuff starts up just fine as well.
Upvotes: 2
Views: 1228
Reputation: 224
Try to use this command to image ngrox:
services:
local.box:
image: nginx:1.21
ports:
- "8888:80"
volumes:
- .:/app
ngrok:
image: ngrok:alpine
depends_on:
- local.box
environment:
- NGROK_AUTHTOKEN=<my_token>
command: "http local.box:8888"
volumes:
- .:/app
networks:
default:
name: dev-dev
external: true
Upvotes: 1