Skip to content

fsockopen doesnt resolve behind synology reverse proxy #19

Description

@opicron

When I open the resourcespace url w/o config.php prefilled I get /pages/setup.php but I can not save. It always returns to /pages/setup.php with this error:

[Mon Jan 19 20:00:14.460832 2026] [php:warn] [pid 17] [client 172.27.0.1:52466] PHP Warning: fsockopen(): Unable to connect to ssl://[mydomain]:443 (Connection timed out) in /var/www/html/pages/setup.php on line 80, referer: http://[mydomain]:8222/pages/setup.php

I am running a reverse proxy to get this working. Which works for all my other dockers. Somehow this docker doesnt like a reverse proxy?

Activity

  1. opicron commented on Jan 19, 2026

    @opicron
    Author

    Edit: no matter how I configured the reverse proxy or the firewall (also disabled the firewall) I could not make it work. What eventually worked was to change url_exists function in setup.php and return true.

    Only then I could pass the setup and the setup works. E.g. I am logged in now.. Maybe the websocket check in setup should be overridable?

  2. changed the title [-]Error?[/-] [+]fsockopen doesnt resolve behind synology reverse proxy[/+] on Jan 20, 2026
  3. opicron commented on Jan 20, 2026

    @opicron
    Author

    Alright, I was able to loopback the domain to synology with this docker-compose.override.yml:

    services:
      resourcespace:
        ports: !override
          - "8222:80"
        extra_hosts:
          - "[reverse proxy domain]:host-gateway"
    
    

    Hopefully this will help someone too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions