Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Cockpit is not reachable via HAProxy

    Scheduled Pinned Locked Moved General pfSense Questions
    2 Posts 1 Posters 328 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • S
      sigulete
      last edited by

      Hi,

      I'm struggling trying to access cockpit server using HAProxy as a reverse proxy.
      The setup is as follows:

      Frontend
      Bind to <my-ip>:443
      Rules:
      subdomain1.mydonaim.com -> backend_subdomain1
      subdomain2.mydonaim.com -> backend_subdomain2

      Backends:
      backend_subdomain1: 192.168.100:9090
      backend_subdomain2: 192.168.100:8080

      When trying to connect from inside the firewall using IPs:

      • 192.168.100.2:9090 -> Works (cockpit)
      • 192.168.100.2:8080 -> Works

      When trying to connect from inside or outside the firewall using FQDN:

      • subdomain1.mydonaim.com -> NOT Work (error 400 - incorrect request)
      • subdomain2.mydonaim.com -> Works

      Because one always works, I can confirm that firewall rules and firewall settings in my server are correct.
      I have tried almost everything, so any clue on what could be the issue will be very appreciated !!

      1 Reply Last reply Reply Quote 0
      • S
        sigulete
        last edited by

        Well Ok, I resolved it.

        The backend for cockpit (port 9090) must be encrypted. And the only acceptable healthcheck is Basic.
        Also, once the backend is updated, I had to change its name and reallocate it to the front-end rule with the new name. There must be an issue with the cache.

        1 Reply Last reply Reply Quote 0
        • First post
          Last post
        Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.