fix: [ISSUE] Bad gateway returned when access http://frontend.unstract.localhost on Mac OS Ventura 13.7.6
After executed /run-platform.sh. All services and containers were started. But 'Bad Gateway' returned when I try to access http://frontend.unstract.localhost
I think you need to wait a little while for the services to start. I faced the same issue initially. I checked the logs to make sure everything was running properly, then refreshed the page, and it worked. This was on Ubuntu
@alameen1999 Thanks for the info! Could you please let me know approximately how long you waited? I'm also using Ubuntu, and I waited for over an hour, but the page still shows a "Bad Gateway" error when I try to access http://frontend.unstract.localhost/.
just cloned and started this on windows with bad gateway as well
I was also running into this issue on a Mac.
I found the issue to be related to the ports of traefik and the frontend, which are setup as port 3000 in the docker-compose.yaml but are showing as 80 after starting everything through docker.
>> docker exec -it unstract-frontend sh
/ $ netstat -tulpn
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 [0.0.0.0:80](http://0.0.0.0/) 0.0.0.0:* LISTEN 1/nginx: master pro
tcp 0 0 [127.0.0.11:38171](http://127.0.0.11:38171/) 0.0.0.0:* LISTEN -
udp 0 0 [127.0.0.11:41514](http://127.0.0.11:41514/) 0.0.0.0:* -
I fixed it by modifying the following to use port 80 in docker/docker-compose.yaml:
# Frontend React app
frontend:
image: unstract/frontend:${VERSION}
container_name: unstract-frontend
restart: unless-stopped
ports:
- "3000:80"
depends_on:
- backend
- reverse-proxy
environment:
- ENVIRONMENT=development
labels:
- traefik.enable=true
- traefik.http.routers.frontend.rule=Host(`frontend.unstract.localhost`) && !PathPrefix(`/api/v1`, `/deployment`)
- traefik.http.services.frontend.loadbalancer.server.port=80
When I run run-platform.sh after that modification, I am able to access the Unstract interface at http://frontend.unstract.localhost.