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

    HAProxy: 2 Front-End Pointing to same IP?

    Scheduled Pinned Locked Moved Cache/Proxy
    2 Posts 2 Posters 325 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.
    • O
      oguruma
      last edited by

      I am trying to use HAProxy to send traffic (One external IP) to 2 different internal IPs. Both are in the same DMZ.

      10.1.1.2:80 -> staging.mydomain.com ->Development webserver
      10.1.1.5:80 -> nextcloud.mydomain.com -> Nextcloud (haven't set up LetsEncrypt Yet)

      I have created a Shared Frontend and 2 sub-front ends (one for each domain). Each domain has its own backend.

      The ACLs are: contains "staging.mydomain.com" and contains "nextcloud.mydomain.com" respectively.

      The problem is that when I added the "Nextcloud" sub-front, traffic from either domain is sent to that IP.

      So staging.mydomain.com should go to 10.1.1.2, and nextcloud.mydomain.com should go to 10.1.1.5, however both domains are going to 10.1.1.5.

      P 1 Reply Last reply Reply Quote 0
      • P
        PiBa @oguruma
        last edited by

        @oguruma
        Besides defining ACL's have you used those acls behind use-backend 'actions'.?

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