Page MenuHomeVyOS Platform

Incorrect HAProxy config generated for reverse-proxy rules with url-path
Closed, ResolvedPublicBUG

Description

URL path for this configuration does nothing:

set load-balancing reverse-proxy service foo port '4443'
set load-balancing reverse-proxy service foo rule 10 set backend 'bk01'
set load-balancing reverse-proxy service foo rule 10 url-path end '/local'
set load-balancing reverse-proxy backend bk01 server s1 address '192.0.2.1'
set load-balancing reverse-proxy backend bk01 server s1 port '4443'

We get empty rule 10 # rule 10 for the frontend

cat /run/haproxy/haproxy.cfg


# Frontend
frontend foo
    bind :::4443 v4v6  
    # rule 10


# Backend
backend bk01
    balance roundrobin
    option forwardfor
    http-request set-header X-Forwarded-Port %[dst_port]
    http-request add-header X-Forwarded-Proto https if { ssl_fc }
    server s1 192.0.2.1:4443

It should either - works only with redirect (xxx rule 10 set redirect-location ) or something is not implemented

Details

Version
VyOS 1.5-rolling-202403250019
Is it a breaking change?
Perfectly compatible
Issue type
Bug (incorrect behavior)

Event Timeline

Viacheslav triaged this task as Normal priority.
Viacheslav changed the task status from Open to Needs testing.May 1 2024, 7:16 AM
Viacheslav assigned this task to nvollmar.
Viacheslav moved this task from Open to Finished on the VyOS 1.5 Circinus board.
Viacheslav moved this task from Need Triage to Finished on the VyOS 1.4 Sagitta (1.4.0-epa3) board.
dmbaturin renamed this task from Reverse-proxy configuration rule url-path looks incomplete to Incorrect HAProxy config generated for reverse-proxy rules with url-path.May 11 2024, 8:03 PM
dmbaturin removed a project: VyOS 1.5 Circinus.
dmbaturin changed Is it a breaking change? from Unspecified (possibly destroys the router) to Perfectly compatible.