Open exocode opened 2 years ago
I'm using argocd to apply its own configuration. My AppProject and Applications yams only have the "name" field in destination, I omit "server". When applied, they stay the same without populating the empty "server". Maybe the "server" field in destination only gets populated when creating an application or project though the UI.
@rodrigo14miguel following your advice on this and use the name-field instead of server i get certificate errors towards my remote cluster that i'm not getting when i specify the url directly. 🤔
Am using automation to setup argocd project and application. Each Project is specific for a cluster. Cluster is also added dynamically. its hard to to setup dynamic cluster URL to match the project. It would be nice if cluster name is used to match the rules and assign applications to this project with server name.
Also RBAC uses the URL instead of the name..
Applications do work with a server name.
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: foo
spec:
destination:
name: sbx-eks-cluster
namespace: default
No need to specify the server endpoint Other than that, yeah, is not support
Applications do work with a server name.
apiVersion: argoproj.io/v1alpha1 kind: Application metadata: name: foo spec: destination: name: sbx-eks-cluster namespace: default
No need to specify the server endpoint Other than that, yeah, is not support
What version area you using? This didn't work last time I tried it
Applications do work with a server name.
apiVersion: argoproj.io/v1alpha1 kind: Application metadata: name: foo spec: destination: name: sbx-eks-cluster namespace: default
No need to specify the server endpoint Other than that, yeah, is not support
What version area you using? This didn't work last time I tried it
I, personally, discovered it not so long ago (v2.10.1+a79e0ea
), but my colleague has v2.6.7+5bcd846
and it works fine for him as well
Applications do work with a server name.
apiVersion: argoproj.io/v1alpha1 kind: Application metadata: name: foo spec: destination: name: sbx-eks-cluster namespace: default
No need to specify the server endpoint Other than that, yeah, is not support
What version area you using? This didn't work last time I tried it
I, personally, discovered it not so long ago (
v2.10.1+a79e0ea
), but my colleague hasv2.6.7+5bcd846
and it works fine for him as well
Interesting, I was on 2.9.0 when I tried but perhaps I'm conflating something similar or didn't do it right or something, will have to test again later. Thanks
Good thing I found this ticket. I only ever used name
in my Application yamls and was assuming that an applicationSet just uses the same fields for its template under the hood. Until it didn't and I started searching what I was doing wrong.
@proligde But ApplicationSet does use the same fields for it's template under the hood and it supports using the name
.
I'm already using them with a name
as destination and it works
apiVersion: argoproj.io/v1alpha1
kind: ApplicationSet
metadata:
name: aws-load-balancer-controller
finalizers: [resources-finalizer.argocd.argoproj.io]
spec:
generators:
- list:
elements:
- environment: sbx
cluster: sbx-eks-cluster
...
template:
metadata:
name: '{{ environment }}-aws-load-balancer-controller'
finalizers: [resources-finalizer.argocd.argoproj.io]
spec:
destination:
name: '{{ cluster }}'
namespace: kube-system
Summary
Applications
andAppProjects
should be able to accessCluster
by it'sServerName
instead ofURL
to be less redundant.Motivation
In ArgoCD I can add
clusters
by manifests. These manifests already contain aname
. ButAppProjects
andApplications
need to pass the server IP You have to change allAppProject
andApplication
manifests when the Cluster IP is changing which is not good when practicing GitOps.Proposal
Clusters have
serverIP
s, but also have aname
. Why not simply referencing the ArgoCDclusterName
inAppProject
andApplication
manifests? Why only using redundant and error prone repetiton of cluster IPs?