Skip to content

Commit f1ce876

Browse files
committed
Add basic authentication for ArgoCD with a ingress configuration
1 parent 6aee266 commit f1ce876

File tree

3 files changed

+45
-0
lines changed

3 files changed

+45
-0
lines changed
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
---
2+
apiVersion: bitnami.com/v1alpha1
3+
kind: SealedSecret
4+
metadata:
5+
creationTimestamp: null
6+
name: basic-auth
7+
namespace: argocd
8+
spec:
9+
encryptedData:
10+
auth: AgAKQU2fjI1PAfa2OfgBO73tPtnHgPqRVb7aS77Kox6OUM4vr2wo6fEdAl4qlBAbWRV00g3VB6gVH3zRmGlYI25SY97tOc2NI8v+upLQhWZKbDHAqbpUWAWqIRVXw2Em7nhup4pyN0hVXdknlj+3l2iXNyEYfwi+9ZB9PqyBIHno0ENkMOtHS8inRuYdsT0daeiPSvnohXYxRQHQGS8DK0QA/o0OMXSFp6zvd60f/n++5RaxPUu9f6isn4ie68uX6zfK+gGg4NnM+6IZatUdNPIox2BEVPoogRNH+oVILHeu799FpT7CByV2S/MSfQbwD3tFJV+Ej/4OTQ6UKrfnJKveMkfselAd8qnNbbcBrcJYTRI6kWGxtzvYaDQuCYTNG9hbZW2UOecCt5c3CRQvYU1nrdOnjnzVGxhvWoS8FHtAbU0r/3F8Qk5Dzgs2oWdnkEbz95WFGAC9VuU9THxPr4BiJ3VNo15bnDfkUFZYaZPszSqzaOEI3qPbkRJvRuo3TK2WfL1CV6baPlazv3lkXaL3Iw+dEHIURuqLq+VSx4GDji9OlofhcApK7JMqfsMF5K73IbxollFzM3DwYzcuGQjNTXG5Ab4ccC3wIhrpxChNfveHR+KrtWBR61C70wca0kH/V65kR/uGlW+bWVLAep/jRpXyrjheCtitc/wD3t+hrS6mQVnVXx0WohJdnvgdgwuFDjMvfY31UFgfHzeTnBz3TvKaXHzkGsh0DD4MWwrpwAuZkWTuyEOjUvqSi/YROQ==
11+
template:
12+
metadata:
13+
creationTimestamp: null
14+
name: basic-auth
15+
namespace: argocd
16+
type: Opaque

infra/argocd/ingress.yaml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
apiVersion: networking.k8s.io/v1
2+
kind: Ingress
3+
metadata:
4+
name: argocd
5+
labels:
6+
app.kubernetes.io/name: argocd
7+
annotations:
8+
"nginx.ingress.kubernetes.io/auth-type": basic
9+
"nginx.ingress.kubernetes.io/auth-secret": basic-auth
10+
"nginx.ingress.kubernetes.io/auth-realm": "Authentication Required - internal"
11+
"cert-manager.io/cluster-issuer": letsencrypt
12+
spec:
13+
rules:
14+
- host: cd.code4.ro
15+
http:
16+
paths:
17+
- pathType: Prefix
18+
path: "/"
19+
backend:
20+
service:
21+
name: argocd-server
22+
port:
23+
number: 80
24+
tls:
25+
- hosts:
26+
- cd.code4.ro
27+
secretName: web-ssl

infra/argocd/kustomization.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ resources:
77
- namespace.yaml
88
- project.yaml
99
- sealed-secret.yaml
10+
- ingress.yaml
11+
- basic-auth-sealed-secret.yaml
1012

1113
patches:
1214
- path: argocd-rbac-cm.yaml

0 commit comments

Comments
 (0)