Ticket: Issue with Nginx Proxy Manager Setup
@Rhazar Just created a ticket
Question: Hi! I'm trying to install for the first time. I think everything is working locally bacause I can access via localhost:5000, but its not working when I try with nginx proxy manager.
Attempted: I've already verified the docker compose and it looks everything is correct ( based on the exemple you have on documentation. I'm noob in the self-hosted world). Maybe I've missed some custom options about nginx integration on postiz docker compose? Btw, I don't know if its mandatory, but when I try to change network to external, I cannot run docker.
Working On: nothing
Take it from here @Postiz
Question: Hi! I'm trying to install for the first time. I think everything is working locally bacause I can access via localhost:5000, but its not working when I try with nginx proxy manager.
Attempted: I've already verified the docker compose and it looks everything is correct ( based on the exemple you have on documentation. I'm noob in the self-hosted world). Maybe I've missed some custom options about nginx integration on postiz docker compose? Btw, I don't know if its mandatory, but when I try to change network to external, I cannot run docker.
Working On: nothing
Take it from here @Postiz
8 Replies
@Postiz please help @Rhazar
Heya
So, can you please share what's happening at the moment, what's "not working"
Any error messages or screenshots that you can share?
Yes sure. When I open the url where nginx redirect says "502 Bad Gateway
openresty"
Here is my configs on nginx:
Here is my docekr compose config:
services:
postiz:
image: ghcr.io/gitroomhq/postiz-app:latest
container_name: postiz
restart: always
environment:
# You must change these. Replace
postiz.your-server.com
with your DNS name - what your web browser sees.
MAIN_URL: "https://my.domain.pt"
FRONTEND_URL: "https://my.domain.pt"
NEXT_PUBLIC_BACKEND_URL: "https://my.domain.pt/api"
JWT_SECRET: "asd34fvdg653sdrasd"
# These defaults are probably fine, but if you change your user/password, update it in the
# postiz-postgres or postiz-redis services below.
DATABASE_URL: "postgresql://postiz-user:postiz-password@postiz-postgres:5432/postiz-db-local"
REDIS_URL: "redis://postiz-redis:6379"
BACKEND_INTERNAL_URL: "http://localhost:3000"
IS_GENERAL: "true" # Required for self-hosting.
# The container images are pre-configured to use /uploads for file storage.
# You probably should not change this unless you have a really good reason!
STORAGE_PROVIDER: "local"
UPLOAD_DIRECTORY: "/uploads"
NEXT_PUBLIC_UPLOAD_DIRECTORY: "/uploads"
volumes:
- postiz-config:/config/
- postiz-uploads:/uploads/
ports:
- 5000:5000
networks:
- postiz-network
depends_on:
postiz-postgres:
condition: service_healthy
postiz-redis:
condition: service_healthy
postiz-postgres:
image: postgres:17-alpine
container_name: postiz-postgres
restart: always
environment:
POSTGRES_PASSWORD: postiz-password
POSTGRES_USER: postiz-user
POSTGRES_DB: postiz-db-local
volumes:
- postgres-volume:/var/lib/postgresql/data
networks:
- postiz-network
healthcheck:
test: pg_isready -U postiz-user -d postiz-db-local
interval: 10s
timeout: 3s
retries: 3
postiz-redis:
image: redis:7.2
container_name: postiz-redis
restart: always
healthcheck:
test: redis-cli ping
interval: 10s
timeout: 3s
retries: 3
volumes:
- postiz-redis-data:/data
networks:
- postiz-network
volumes:
postgres-volume:
external: false
postiz-redis-data:
external: false
postiz-config:
external: false
postiz-uploads:
external: false
networks:
postiz-network:
external: false
Sorry for the spam, hope it helpsPostiz normally doesnt run on https, try to change https to http in details
Thanks for your reply. I've already tried and nothing
Solution: add "name: nginx"
Hmm that won't change much to be honest
Only if your NPM config is matching based on network name?