From 33f9bb9db29a779c447ff10b3e4f77e27bd4affc Mon Sep 17 00:00:00 2001 From: Simon Murray Date: Mon, 30 Sep 2024 14:36:31 +0100 Subject: [PATCH] Fix Router Provision Bug Error is not getting propagated, and annoyingly the linter didn't pick this up, meaning we say it's okay when a router fails to provision e.g. no more IP addresses, and we get a SIGSEGV. --- charts/region/Chart.yaml | 4 ++-- pkg/providers/openstack/provider.go | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/charts/region/Chart.yaml b/charts/region/Chart.yaml index be03b10..630b2e1 100644 --- a/charts/region/Chart.yaml +++ b/charts/region/Chart.yaml @@ -4,8 +4,8 @@ description: A Helm chart for deploying Unikorn's Region Controller type: application -version: v0.1.40 -appVersion: v0.1.40 +version: v0.1.41 +appVersion: v0.1.41 icon: https://raw.githubusercontent.com/unikorn-cloud/assets/main/images/logos/dark-on-light/icon.png diff --git a/pkg/providers/openstack/provider.go b/pkg/providers/openstack/provider.go index b86e35b..e33df8c 100644 --- a/pkg/providers/openstack/provider.go +++ b/pkg/providers/openstack/provider.go @@ -936,7 +936,7 @@ func (p *Provider) createRouter(ctx context.Context, networkService *NetworkClie router, err := networkService.CreateRouter(ctx, "unikorn-openstack-region-provider-router") if err != nil { - return nil + return err } openstackPhysicalNetwork.Spec.RouterID = &router.ID