9ea1902e2b
Remove the overwritehost and overwrite.cli.url settings that were forcing Nextcloud to generate URLs with localhost:8080 regardless of the incoming request's Host header. This was breaking Dynamic Client Registration (DCR) from the mcp-oauth container, which needs to reach Nextcloud at http://app:80 but was getting discovery documents with http://localhost:8080 URLs that are unreachable from inside the Docker network. Now Nextcloud respects the Host header: - Browser requests to localhost:8080 → returns localhost:8080 URLs - Container requests to app:80 → returns app:80 URLs 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
11 lines
387 B
Bash
Executable File
11 lines
387 B
Bash
Executable File
#!/bin/bash
|
|
|
|
set -euox pipefail
|
|
|
|
php /var/www/html/occ config:system:set trusted_domains 2 --value=host.docker.internal
|
|
|
|
# Do NOT set overwritehost/overwrite.cli.url - let Nextcloud use the request's Host header
|
|
# This allows:
|
|
# - Browser requests to localhost:8080 → returns localhost:8080 URLs
|
|
# - Container requests to app:80 → returns app:80 URLs (for DCR, token exchange, etc.)
|