소스 검색

Document the base domain proxy host in the Nginx Proxy Manager example

The example only covered `matrix.example.com` and the federation stream,
so people who make the playbook serve the base domain were left without a
proxy host for it. Requests for the `/.well-known/matrix/*` files on the
base domain then never reach Traefik and Nginx Proxy Manager answers with
a 404 error of its own, breaking federation and client discovery.

The nginx example already covers this by listing `example.com` in its
`server_name` directive. Serving the base domain from the Matrix server
is optional though, so the new section says so and points people whose
base domain lives elsewhere to the server delegation documentation.

Also note that a `*.example.com` wildcard certificate does not cover the
base domain itself, which is easy to get wrong when setting this up.

Related to https://github.com/spantaleev/matrix-docker-ansible-deploy/issues/5465

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
master
Slavi Pantaleev 10 시간 전
부모
커밋
906e457fcb
1개의 변경된 파일25개의 추가작업 그리고 1개의 파일을 삭제
  1. +25
    -1
      examples/reverse-proxies/nginx-proxy-manager/README.md

+ 25
- 1
examples/reverse-proxies/nginx-proxy-manager/README.md 파일 보기

@@ -1,7 +1,7 @@
<!-- <!--
SPDX-FileCopyrightText: 2024 Gouthaman Raveendran SPDX-FileCopyrightText: 2024 Gouthaman Raveendran
SPDX-FileCopyrightText: 2024 MDAD project contributors SPDX-FileCopyrightText: 2024 MDAD project contributors
SPDX-FileCopyrightText: 2024 Slavi Pantaleev
SPDX-FileCopyrightText: 2024 - 2026 Slavi Pantaleev
SPDX-FileCopyrightText: 2024 Suguru Hirahara SPDX-FileCopyrightText: 2024 Suguru Hirahara


SPDX-License-Identifier: AGPL-3.0-or-later SPDX-License-Identifier: AGPL-3.0-or-later
@@ -60,3 +60,27 @@ SSL Certificate: matrix.example.com or *.example.com
``` ```


Also note, NPM would need to be configured for whatever other services you are using. For example, you would need to create additional proxy hosts for `element.example.com` or `jitsi.example.com`, which would use the forwarding port `81`. Also note, NPM would need to be configured for whatever other services you are using. For example, you would need to create additional proxy hosts for `element.example.com` or `jitsi.example.com`, which would use the forwarding port `81`.

## Serving the base domain (optional)

The configuration above only covers `matrix.example.com`. Many people serve their base domain (`example.com`) from somewhere else entirely, in which case there is nothing more to do here. Arrange [server delegation](../../../docs/howto-server-delegation.md) on whichever server hosts the base domain instead.

If you have made this Matrix server responsible for the base domain as well (by [serving the base domain](../../../docs/configuring-playbook-base-domain-serving.md) with `matrix_static_files_container_labels_base_domain_enabled: true`), then the base domain needs a proxy host of its own. Without it, requests for `https://example.com/.well-known/matrix/server` and `https://example.com/.well-known/matrix/client` never reach Traefik, NPM answers with a `404` error of its own, and both [Federation Server Discovery](../../../docs/configuring-well-known.md#federation-server-discovery) and [Client-Server discovery](../../../docs/configuring-well-known.md#client-server-discovery) break.

Add another proxy host, this time for the base domain:

```md
# Details
# Base domain proxy config
Domain Names: example.com
Scheme: http
Forward Hostname/IP: IP-ADDRESS-OF-YOUR-MATRIX
Forward Port: 81

# SSL
# Note that a `*.example.com` wildcard certificate does not cover the base domain itself,
# so the certificate you use here needs to include `example.com`
SSL Certificate: example.com
Force SSL: true
HTTP/2 Support: true
```

불러오는 중...
취소
저장