Deactivate nginx from seafile 13.x

Hi

I want to deploy Seafile 13.0.25 in my localhost (WSL2) as docker container using Ansible but I recieve the 502 Bad Gateway error from nginx.

Is there an option to deactivate the nginx in order to be able to access the service using my local ip:port or localhost:port?
I did not find any solution on Google :frowning:

Here is my docker-compose file

networks:
seafile-net:
name: seafile_network
driver: bridge

services:
db:
image: mariadb:10.11
container_name: seafile-mysql
restart: unless-stopped
volumes:
- /opt/seafile/db:/var/lib/mysql
logging:
driver: json-file
options:
max-file: “3”
max-size: “10m”
environment:
- MARIADB_AUTO_UPGRADE=1
- MYSQL_LOG_CONSOLE=true
- MYSQL_ROOT_PASSWORD=${MYSQL_ROOT_PASSWORD}
- MYSQL_DATABASE=seafile_db
- MYSQL_USER=seafile
- MYSQL_PASSWORD=${MYSQL_DB_PASSWORD}
healthcheck:
interval: 20s
retries: 10
start_period: 30s
test:
- CMD
- /usr/local/bin/healthcheck.sh
- --connect
- --mariadbupgrade
- --innodb_initialized
timeout: 5s
ports:
- “3306:3306”
networks:
- seafile-net

seafile:
image: seafileltd/seafile-mc:13.0.25
container_name: seafile
restart: unless-stopped
volumes:
- /opt/seafile:/shared/seafile
# - /opt/seafile/storage:/opt/seafile/seafile-data
logging:
driver: json-file
options:
max-file: “3”
max-size: “10m”
environment:
- INIT_SEAFILE_ADMIN_EMAIL=admin@example.com
- INIT_SEAFILE_ADMIN_PASSWORD=${SEAFILE_ADMIN_PASSWORD}
- INIT_SEAFILE_MYSQL_ROOT_PASSWORD=${MYSQL_ROOT_PASSWORD}
- JWT_PRIVATE_KEY=${JWT_PRIVATE_KEY}
- SEAFILE_MYSQL_DB_HOST=db
- SEAFILE_MYSQL_DB_USER=seafile
- SEAFILE_MYSQL_DB_PASSWORD=${MYSQL_DB_PASSWORD}
- SEAFILE_MYSQL_DB_CCNET_DB_NAME=ccnet_db
- SEAFILE_MYSQL_DB_SEAHUB_DB_NAME=seahub_db
- SEAFILE_MYSQL_DB_SEAFILE_DB_NAME=seafile_db
- SEAFILE_SERVER_HOSTNAME=127.0.0.1
- SEAFILE_SERVER_LETSENCRYPT=False
- SEAFILE_SERVER_PROTOCOL=http
- TIME_ZONE=Etc/UTC
healthcheck:
interval: 30s
retries: 3
start_period: 10s
test: [“CMD-SHELL”, “curl -f http://localhost:80 || exit 1”]
timeout: 10s
depends_on:
db:
condition: service_healthy
ports:
- “8081:80”
networks:
- seafile-net

Thank you!

Seafile 13.x single-node Docker deployment does not provide a supported way to disable the bundled reverse proxy entirely. The documented approach is to keep the reverse-proxy layer in place and adjust the exposed ports and proxy configuration instead.

For the single-node Docker setup, please keep the reverse proxy model and verify these points:

  • map the Seafile service port correctly in Docker,
  • keep the reverse proxy configuration in place,
  • make sure the service URL values match the address you actually use to reach the server.

The manual for Docker reverse-proxy changes explains that if you want to use another proxy, you should modify the relevant configuration files and port mappings rather than removing the proxy service:

A related manual section also shows that the frontend is designed to listen on local port 8000 and be reverse-proxied for external access:

So in your case, the 502 is more likely a deployment/proxy configuration issue than something that can be solved by turning nginx off.