-
Notifications
You must be signed in to change notification settings - Fork 149
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue of ngnix with docker-compose #5
Comments
Make sure |
I'm not sure then |
What should I do? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I am not able to setup my backend with ngnix.
I am using the same commands in docker-comppose.yml and mysite.template as shown in video
docker-compose.yml
version: '3'
services:
redis:
image: redis
networks:
- webnet
db:
image: postgres
volumes:
- ./pgdata:/var/lib/postgresql/data
networks:
- webnet
environment:
POSTGRES_PASSWORD: postgres
POSTGRES_USER: postgres
POSTGRES_DB: slack
ports:
- '3030:5432'
web:
image: slack-clone-server
networks:
- webnet
environment:
DB_HOST: db
REDIS_HOST: redis
depends_on:
- db
- redis
command: ['node', 'app.js']
nginx:
image: nginx
volumes:
- ./mysite.template:/etc/nginx/conf.d/mysite.template
ports:
- '8081:80'
networks:
- webnet
depends_on:
- web
command: /bin/bash -c "envsubst < /etc/nginx/conf.d/mysite.template > /etc/nginx/conf.d/default.conf && nginx -g 'daemon off;'"
networks:
webnet:
AND mysite.template
server {
location / {
proxy_pass http://web:8081;
}
}
I am getting ERROR : cat: /etc/nginx/conf.d/mysite.template: Is a directory
server_nginx_1 exited with code 1
Please help me anyone
The text was updated successfully, but these errors were encountered: