refactor: remove strict bind configuration from BGP templates and update related logic. Eliminate 'strict bind on' from both IPv4 and IPv6 templates to simplify BGP peer rendering. Adjust OpenAPI documentation and internal handling of BGP source addresses to reflect these changes, enhancing clarity and compatibility.
CI / changes (push) Successful in 7s
CI / openapi (push) Successful in 23s
CI / go (push) Successful in 24s
CI / docker-web (deploy/docker/evobgp-web/Dockerfile, , evobgp-web) (push) Successful in 1m7s
CI / docker-web (deploy/docker/evobgp-web/Dockerfile, evobgp-all, evobgp-web-all) (push) Successful in 1m2s
CI / docker-bird (push) Has been skipped
CI / bird2 (push) Successful in 55s
CI / docker-go (deploy/docker/evobgp-agent/Dockerfile, , evobgp-agent) (push) Successful in 54s
CI / docker-go (evobgp-all, 1, deploy/docker/gobinary/Dockerfile, , evobgp-all) (push) Successful in 2m19s
CI / docker-go (evobgp-api, 1, deploy/docker/gobinary/Dockerfile, , evobgp-api) (push) Successful in 2m27s
CI / docker-go (evobgp-deploy, 0, deploy/docker/gobinary/Dockerfile, , evobgp-deploy) (push) Successful in 1m22s
CI / docker-go (evobgp-ingest, 0, deploy/docker/gobinary/Dockerfile, , evobgp-ingest) (push) Successful in 1m26s
CI / docker-go (evobgp-node, 0, deploy/docker/gobinary/Dockerfile, , evobgp-node) (push) Successful in 1m9s
CI / docker-go (evobgp-render, 0, deploy/docker/gobinary/Dockerfile, , evobgp-render) (push) Successful in 1m19s
CI / docker-go (evobgp-scheduler, 0, deploy/docker/gobinary/Dockerfile, , evobgp-scheduler) (push) Successful in 1m19s

This commit is contained in:
Denozordec
2026-04-06 14:03:25 +07:00
parent dc5e20e9b2
commit 482eeb122d
8 changed files with 29 additions and 72 deletions
+5 -10
View File
@@ -37,11 +37,10 @@ func TestRenderBGPTemplates_Validation(t *testing.T) {
func TestRenderProtocolBGPFromTemplate_MultihopPassive(t *testing.T) {
got, err := RenderProtocolBGPFromTemplate(BGPPeerFromTemplateOptions{
ProtocolName: "evobgp_p_x",
TemplateName: BGPTemplateNameV4,
NeighborIP: "94.142.140.141",
NeighborASN: 65002,
SourceAddress: "77.232.38.173",
ProtocolName: "evobgp_p_x",
TemplateName: BGPTemplateNameV4,
NeighborIP: "94.142.140.141",
NeighborASN: 65002,
})
if err != nil {
t.Fatal(err)
@@ -52,10 +51,7 @@ func TestRenderProtocolBGPFromTemplate_MultihopPassive(t *testing.T) {
if !strings.Contains(got, "multihop;") || !strings.Contains(got, "passive;") {
t.Fatal(got)
}
if !strings.Contains(got, "source address 77.232.38.173;") {
t.Fatal(got)
}
if !strings.Contains(got, "strict bind on;") {
if strings.Contains(got, "source address") || strings.Contains(got, "strict bind") {
t.Fatal(got)
}
}
@@ -66,7 +62,6 @@ func TestRenderProtocolBGPFromTemplate_OverrideLocal(t *testing.T) {
TemplateName: BGPTemplateNameV4,
NeighborIP: "192.0.2.2",
NeighborASN: 2,
SourceAddress: "10.0.0.1",
OverrideLocalIP: "10.0.0.1",
OverrideLocalASN: 65099,
})