From 139bbbb87c0130ab4f5e0b4a69b617a59b17cfa9 Mon Sep 17 00:00:00 2001 From: Stefan Prodan Date: Wed, 23 Mar 2022 11:55:35 +0200 Subject: [PATCH] Use absolute domain name for the events address Add ending dot to the events address to be consistent with source controller address. This will affect bootstrap and install by setting `--events-addr=http://notification-controller.flux-system.svc.cluster.local./`. Signed-off-by: Stefan Prodan --- manifests/bases/helm-controller/patch.yaml | 2 +- manifests/bases/image-automation-controller/patch.yaml | 2 +- manifests/bases/image-reflector-controller/patch.yaml | 2 +- manifests/bases/kustomize-controller/patch.yaml | 2 +- manifests/bases/source-controller/patch.yaml | 2 +- pkg/manifestgen/install/manifests.go | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/manifests/bases/helm-controller/patch.yaml b/manifests/bases/helm-controller/patch.yaml index 59ea939b..fe49320a 100644 --- a/manifests/bases/helm-controller/patch.yaml +++ b/manifests/bases/helm-controller/patch.yaml @@ -1,6 +1,6 @@ - op: add path: /spec/template/spec/containers/0/args/0 - value: --events-addr=http://notification-controller/ + value: --events-addr=http://notification-controller.flux-system.svc.cluster.local./ - op: add path: /spec/template/spec/serviceAccountName value: helm-controller diff --git a/manifests/bases/image-automation-controller/patch.yaml b/manifests/bases/image-automation-controller/patch.yaml index 4015f0f8..63d261ed 100644 --- a/manifests/bases/image-automation-controller/patch.yaml +++ b/manifests/bases/image-automation-controller/patch.yaml @@ -1,6 +1,6 @@ - op: add path: /spec/template/spec/containers/0/args/0 - value: --events-addr=http://notification-controller/ + value: --events-addr=http://notification-controller.flux-system.svc.cluster.local./ - op: add path: /spec/template/spec/serviceAccountName value: image-automation-controller diff --git a/manifests/bases/image-reflector-controller/patch.yaml b/manifests/bases/image-reflector-controller/patch.yaml index 39814a23..1db56bf2 100644 --- a/manifests/bases/image-reflector-controller/patch.yaml +++ b/manifests/bases/image-reflector-controller/patch.yaml @@ -1,6 +1,6 @@ - op: add path: /spec/template/spec/containers/0/args/0 - value: --events-addr=http://notification-controller/ + value: --events-addr=http://notification-controller.flux-system.svc.cluster.local./ - op: add path: /spec/template/spec/serviceAccountName value: image-reflector-controller diff --git a/manifests/bases/kustomize-controller/patch.yaml b/manifests/bases/kustomize-controller/patch.yaml index 380cdfbd..aa588b2b 100644 --- a/manifests/bases/kustomize-controller/patch.yaml +++ b/manifests/bases/kustomize-controller/patch.yaml @@ -1,6 +1,6 @@ - op: add path: /spec/template/spec/containers/0/args/0 - value: --events-addr=http://notification-controller/ + value: --events-addr=http://notification-controller.flux-system.svc.cluster.local./ - op: add path: /spec/template/spec/serviceAccountName value: kustomize-controller diff --git a/manifests/bases/source-controller/patch.yaml b/manifests/bases/source-controller/patch.yaml index 15c1d28e..911d1865 100644 --- a/manifests/bases/source-controller/patch.yaml +++ b/manifests/bases/source-controller/patch.yaml @@ -1,6 +1,6 @@ - op: add path: /spec/template/spec/containers/0/args/0 - value: --events-addr=http://notification-controller/ + value: --events-addr=http://notification-controller.flux-system.svc.cluster.local./ - op: add path: /spec/template/spec/serviceAccountName value: source-controller diff --git a/pkg/manifestgen/install/manifests.go b/pkg/manifestgen/install/manifests.go index 23d6a3cc..3a584ba1 100644 --- a/pkg/manifestgen/install/manifests.go +++ b/pkg/manifestgen/install/manifests.go @@ -73,7 +73,7 @@ func generate(base string, options Options) error { // traffic from going through http proxy. Without fully specified // domain they need to mention `notifications-controller` explicitly in // `no_proxy` variable after debugging http proxy logs. - options.EventsAddr = fmt.Sprintf("http://%s.%s.svc.%s/", options.NotificationController, options.Namespace, options.ClusterDomain) + options.EventsAddr = fmt.Sprintf("http://%s.%s.svc.%s./", options.NotificationController, options.Namespace, options.ClusterDomain) } if err := execTemplate(options, namespaceTmpl, path.Join(base, "namespace.yaml")); err != nil {