gitops-operator icon indicating copy to clipboard operation
gitops-operator copied to clipboard

ApplicationSet Controller throw 'application spec is invalid: InvalidSpecError: Destination server missing from app spec' when destination cluster is microshift

Open wangjun1974 opened this issue 3 years ago • 0 comments

Describe the bug Environment

Red Hat OpenShift 4.9.18 Red Hat Advanced Cluster Management for Kubernetes 2.4.1 Red Hat OpenShift GitOps 1.4.3 microshift quay.io/microshift/microshift:4.8.0-0.microshift-2022-02-04-005920

ACM is setup and both local-cluster and microshift is added as managed cluster into acm.

ApplicationSet Controller throw 'application spec is invalid: InvalidSpecError: Destination server missing from app spec' when destination cluster is microshift.

To Reproduce Steps to reproduce the behavior:

  1. ACM is up and running.
  2. Both 'local-cluster' and 'microshift' is added as managed cluster with status 'Ready'.
  3. create applicationset refer 'https://rcarrata.com/openshift/argo-and-acm/'
  4. See error “error occurred during application generation: application spec is invalid: InvalidSpecError: Destination server missing from app spec” in logs of pod ‘openshift-gitops-applicationset-controller’ in hub.
time="2022-03-12T03:06:53Z" level=info msg="Kind.Group/Version Reference" kind.apiVersion=placementdecisions.cluster.open-cluster-management.io/v1alpha1
time="2022-03-12T03:06:53Z" level=info msg="selection type" listOptions.LabelSelector="cluster.open-cluster-management.io/placement=gitops-openshift-clusters"
time="2022-03-12T03:06:53Z" level=info msg="Number of decisions found: 2"
time="2022-03-12T03:06:53Z" level=info msg="cluster: map[clusterName:edge-1 reason:]"
time="2022-03-12T03:06:53Z" level=info msg="matched cluster in ArgoCD" clusterName=edge-1
time="2022-03-12T03:06:53Z" level=info msg="cluster: map[clusterName:local-cluster reason:]"
time="2022-03-12T03:06:53Z" level=info msg="matched cluster in ArgoCD" clusterName=local-cluster
time="2022-03-12T03:06:53Z" level=info msg="generated 2 applications" generator="{<nil> <nil> <nil> <nil> <nil> 0xc000318ea0}"
time="2022-03-12T03:06:53Z" level=error msg="error occurred during application generation: application spec is invalid: InvalidSpecError: Destination server missing from app spec"

Expected behavior no InvalidSpecError error

Screenshots n/a

Additional context n/a

wangjun1974 avatar Mar 14 '22 02:03 wangjun1974