diff --git a/.gitea/workflows/main.yaml b/.gitea/workflows/main.yaml index 8b7d320..f5d393d 100644 --- a/.gitea/workflows/main.yaml +++ b/.gitea/workflows/main.yaml @@ -40,7 +40,7 @@ jobs: with: context: . file: ./Dockerfile - push: false + push: true tags: | lerentis/canada-kaktus:${{ github.sha }} # - name: Sign the published Docker image diff --git a/internal/k8s.go b/internal/k8s.go index dd1e8e8..e83535e 100644 --- a/internal/k8s.go +++ b/internal/k8s.go @@ -61,7 +61,13 @@ func RecreateIPPoolCrd(cfg *Config, name string, ips []string) error { decode := scheme.Codecs.UniversalDeserializer().Decode - obj, _, err := decode([]byte(body), nil, nil) + versionKind := schema.GroupVersionKind{ + Group: "cilium.io", + Version: "v2alpha1", + Kind: "CiliumLoadBalancerIPPool", + } + + obj, _, err := decode([]byte(body), &versionKind, nil) if err != nil { return fmt.Errorf("could not deserialize CRD: %v", err.Error()) }