Freika / dawarich

Self-hosted alternative to Google Location History (Google Maps Timeline)
https://dawarich.app
GNU Affero General Public License v3.0
2.13k stars 48 forks source link

Nginx Proxy Manager in docker issue #230

Closed hartmark closed 1 month ago

hartmark commented 1 month ago

Describe the bug I fail to get dawarich to accept connections from my reverse proxy. https://github.com/NginxProxyManager/nginx-proxy-manager

Version docker-compose version

To Reproduce Steps to reproduce the behavior:

  1. Setup the nginx reverse proxy by creating this docker-compose.yml file
services:
  app:
    image: 'jc21/nginx-proxy-manager:latest'
    restart: unless-stopped
    ports:
      - '80:80'
      - '81:81'
      - '443:443'
    volumes:
      - ./data:/data
      - ./letsencrypt:/etc/letsencrypt
  1. Surf into localhost:81 and setup foohost.mydomain.com
  2. Then I use https://github.com/Freika/dawarich/blob/master/docker-compose.yml
  3. I remove the lines with APPLICATION_HOSTS
  4. and change APPLICATION_HOST to have foohost.mydomain.com
  5. When surfing into foohost.mydomain.com I'm met with just a json-response:

{"status":"OK","version":{"major":2,"minor":11,"revision":3}}

Expected behavior If I surf into http://localhost:3000 it works as expected but I want it to behave the same for foohost.mydomain.com

hartmark commented 1 month ago

This is the response from the foohost.mydomain.com:

HTTP/2 200 
server: openresty
date: Sat, 07 Sep 2024 01:04:35 GMT
content-type: application/json; charset=utf-8
content-length: 61
x-xss-protection: 1; mode=block
x-content-type-options: nosniff
x-frame-options: DENY
cache-control: no-cache, no-store, max-age=0, must-revalidate
pragma: no-cache
expires: 0
etag: W/"3d-GIt6zoiIT9nDRBCauiicZcxECTE"
vary: Accept-Encoding
strict-transport-security: max-age=63072000; preload
x-served-by: foohost.mydomain.com
X-Firefox-Spdy: h2
hartmark commented 1 month ago

I found the problem. I'm running dawarich and npm on same host and localhost was incorrect to use.

image

<host of dawarich> is the name of my host running the docker container.