Skip to content

Commit

Permalink
chore: Remove specification of user id for the Redis workload (argopr…
Browse files Browse the repository at this point in the history
…oj#5863)

* fix: avoid specifying redis user

Signed-off-by: Shoubhik Bose <shbose@redhat.com>

* fix: generate manifests

Signed-off-by: Shoubhik Bose <shbose@redhat.com>

* chore: one less manifest

Signed-off-by: Shoubhik Bose <shbose@redhat.com>
  • Loading branch information
sbose78 committed Apr 2, 2021
1 parent 8eeb9a0 commit dc4eaff
Show file tree
Hide file tree
Showing 11 changed files with 2 additions and 151 deletions.
3 changes: 0 additions & 3 deletions manifests/base/redis/argocd-redis-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,6 @@ spec:
app.kubernetes.io/name: argocd-redis
spec:
securityContext:
runAsUser: 1000
runAsGroup: 1000
fsGroup: 1000
runAsNonRoot: true
serviceAccountName: argocd-redis
containers:
Expand Down
17 changes: 0 additions & 17 deletions manifests/base/redis/argocd-redis-role.yaml

This file was deleted.

1 change: 0 additions & 1 deletion manifests/base/redis/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ kind: Kustomization

resources:
- argocd-redis-deployment.yaml
- argocd-redis-role.yaml
- argocd-redis-rolebinding.yaml
- argocd-redis-sa.yaml
- argocd-redis-service.yaml
Expand Down
16 changes: 1 addition & 15 deletions manifests/ha/base/redis-ha/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,21 +11,7 @@ patchesJson6902:
kind: ConfigMap
name: argocd-redis-ha-configmap
namespace: argocd
path: overlays/remove-namespace.yaml
- target:
group: rbac.authorization.k8s.io
version: v1
kind: Role
name: argocd-redis-ha
namespace: argocd
path: overlays/add-openshift-nonroot-scc.yaml
- target:
group: rbac.authorization.k8s.io
version: v1
kind: Role
name: argocd-redis-ha-haproxy
namespace: argocd
path: overlays/add-openshift-nonroot-scc.yaml
path: overlays/remove-namespace.yaml
- target:
version: v1
group: ""
Expand Down
11 changes: 0 additions & 11 deletions manifests/ha/base/redis-ha/overlays/add-openshift-nonroot-scc.yaml

This file was deleted.

29 changes: 0 additions & 29 deletions manifests/ha/base/redis-ha/overlays/redis-ha-haproxy.yaml

This file was deleted.

16 changes: 0 additions & 16 deletions manifests/ha/install.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2136,14 +2136,6 @@ rules:
- endpoints
verbs:
- get
- apiGroups:
- security.openshift.io
resourceNames:
- nonroot
resources:
- securitycontextconstraints
verbs:
- use
---
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
Expand All @@ -2162,14 +2154,6 @@ rules:
- endpoints
verbs:
- get
- apiGroups:
- security.openshift.io
resourceNames:
- nonroot
resources:
- securitycontextconstraints
verbs:
- use
---
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
Expand Down
16 changes: 0 additions & 16 deletions manifests/ha/namespace-install.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2136,14 +2136,6 @@ rules:
- endpoints
verbs:
- get
- apiGroups:
- security.openshift.io
resourceNames:
- nonroot
resources:
- securitycontextconstraints
verbs:
- use
---
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
Expand All @@ -2162,14 +2154,6 @@ rules:
- endpoints
verbs:
- get
- apiGroups:
- security.openshift.io
resourceNames:
- nonroot
resources:
- securitycontextconstraints
verbs:
- use
---
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
Expand Down
21 changes: 0 additions & 21 deletions manifests/install.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2114,24 +2114,6 @@ rules:
---
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
labels:
app.kubernetes.io/component: redis
app.kubernetes.io/name: argocd-redis
app.kubernetes.io/part-of: argocd
name: argocd-redis
rules:
- apiGroups:
- security.openshift.io
resourceNames:
- nonroot
resources:
- securitycontextconstraints
verbs:
- use
---
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
labels:
app.kubernetes.io/component: server
Expand Down Expand Up @@ -2599,10 +2581,7 @@ spec:
ports:
- containerPort: 6379
securityContext:
fsGroup: 1000
runAsGroup: 1000
runAsNonRoot: true
runAsUser: 1000
serviceAccountName: argocd-redis
---
apiVersion: apps/v1
Expand Down
21 changes: 0 additions & 21 deletions manifests/namespace-install.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2114,24 +2114,6 @@ rules:
---
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
labels:
app.kubernetes.io/component: redis
app.kubernetes.io/name: argocd-redis
app.kubernetes.io/part-of: argocd
name: argocd-redis
rules:
- apiGroups:
- security.openshift.io
resourceNames:
- nonroot
resources:
- securitycontextconstraints
verbs:
- use
---
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
labels:
app.kubernetes.io/component: server
Expand Down Expand Up @@ -2514,10 +2496,7 @@ spec:
ports:
- containerPort: 6379
securityContext:
fsGroup: 1000
runAsGroup: 1000
runAsNonRoot: true
runAsUser: 1000
serviceAccountName: argocd-redis
---
apiVersion: apps/v1
Expand Down
2 changes: 1 addition & 1 deletion reposerver/repository/repository_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ func TestGenerateYamlManifestInDir(t *testing.T) {
q := apiclient.ManifestRequest{Repo: &argoappv1.Repository{}, ApplicationSource: &src}

// update this value if we add/remove manifests
const countOfManifests = 29
const countOfManifests = 28

res1, err := service.GenerateManifest(context.Background(), &q)

Expand Down

0 comments on commit dc4eaff

Please sign in to comment.