Answer the question
In order to leave comments, you need to log in
Why doesn't Nginx work with docker-compose?
server {
listen 80;
server_name tnd.zaoios.ru;
location / {
uwsgi_pass django:2021;
include /container/tnd/docker/uwsgi_params;
}
location ~ ^/(static|media) {
root /container/tnd/;
gzip_static on;
gzip_types text/plain text/xml text/css text/comma-separated-values
text/javascript application/x-javascript application/atom+xml;
access_log off;
expires 30d;
}
}
nginx:
image: nginx
restart: always
volumes:
- ../:/container/tnd
- ./nginx:/etc/nginx/conf.d
ports:
- "8080:80"
depends_on:
- django
command: /bin/bash -c '/container/tnd/docker/run_nginx.sh'
container_name: container-nginx
Answer the question
In order to leave comments, you need to log in
Because compose thinks for you and without it you need to think for yourself :)
Study the documentation for the tools https://docs.docker.com/network/links/#communicati...
section Communication across links
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question