Fix FB integration not picked up + OO mixed content behind HTTPS proxy
- SyncFileBrowserMounts: use --force-recreate so FB always picks up config.yaml changes (bind mount not detected by docker compose up) - OnlyOffice compose template: add Traefik middleware to forward X-Forwarded-Proto=https (fixes mixed content errors in browser) - Nextcloud handler: add StorageUrl=http://nextcloud for internal file download callbacks from OO Document Server Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -49,6 +49,10 @@ func (h *OnlyOfficeNextcloudHandler) Apply(ac *ApplyContext) error {
|
||||
{
|
||||
args: []string{"docker", "exec", "-u", "www-data", "nextcloud", "php", "occ", "config:app:set", "onlyoffice", "jwt_secret", "--value=" + jwtSecret},
|
||||
},
|
||||
{
|
||||
// StorageUrl: tells OO Document Server where to reach Nextcloud internally for file callbacks
|
||||
args: []string{"docker", "exec", "-u", "www-data", "nextcloud", "php", "occ", "config:app:set", "onlyoffice", "StorageUrl", "--value=http://nextcloud"},
|
||||
},
|
||||
}
|
||||
|
||||
for _, cmd := range commands {
|
||||
|
||||
@@ -1620,7 +1620,7 @@ func (s *Server) SyncFileBrowserMounts() {
|
||||
// Recreate container — H16: use 60s timeout to prevent hanging indefinitely.
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 60*time.Second)
|
||||
defer cancel()
|
||||
cmd := exec.CommandContext(ctx, "docker", "compose", "up", "-d", "--remove-orphans")
|
||||
cmd := exec.CommandContext(ctx, "docker", "compose", "up", "-d", "--force-recreate", "--remove-orphans")
|
||||
cmd.Dir = stackDir
|
||||
if out, err := cmd.CombinedOutput(); err != nil {
|
||||
s.logger.Printf("[ERROR] Failed to recreate FileBrowser: %s — %v", string(out), err)
|
||||
|
||||
Reference in New Issue
Block a user