Suggestion for docs: please add docker-compose instructions
Opened this issue · 0 comments
pluseg commented
It's just a reminder for all people who try to run this project with docker-compose. I got errors
- WebSocket connection to 'ws://127.0.0.1:1337/' failed: Connection closed before receiving a handshake response
- Disconnected for Connection could not be established. with code 3
Solution: you should specify HOST=0.0.0.0 instead of 127.0.0.1.
Here is a sample docker-compose file:
version: '3.2'
services:
web:
build: app/docker/php
ports:
- 9000:9000
- 1337:1337
volumes:
- ./:/var/www/html
environment:
SYMFONY_ENV: dev
entrypoint: app/docker/php/docker-entrypoint.sh
nginx:
image: nginx:latest
ports:
- 80:80
environment:
- NGINX_PORT=80
- WWW_DIR=/var/www/html/public
volumes:
- ./app/docker/nginx:/etc/nginx/conf.d
- ./:/var/www/html
- ./var/logs/nginx:/var/log/nginx
command: /bin/bash -c "exec nginx -g 'daemon off;'"
networks:
default:
I could provide files that I have in "app/docker" folder if needed. Or could create a Pull request if you'd like.