Skip to content

Commit b8cf7ed

Browse files
Merge branch 'redhat-developer:master' into track_codecov
2 parents 47437b6 + 8aa2f88 commit b8cf7ed

File tree

137 files changed

+25780
-4927
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

137 files changed

+25780
-4927
lines changed

.github/cherry-pick-bot.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
enabled: true
2+
preservePullRequestTitle: true
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Trigger openshift-ci automation
2+
on:
3+
create
4+
jobs:
5+
build:
6+
runs-on: ubuntu-latest
7+
8+
steps:
9+
- name: Test
10+
run: |
11+
export BRANCH=${{ github.event.ref }}
12+
echo $BRANCH
13+
# check if version starts with v or not
14+
if [[ $BRANCH = v* ]];then
15+
curl -L \
16+
-H "Accept: application/vnd.github+json" \
17+
-H "Authorization: Bearer ${{ secrets.ACTIONS_KEY }}" \
18+
-H "X-GitHub-Api-Version: 2022-11-28" \
19+
https://api.github.com/repos/kamuserbot/release/dispatches \
20+
-d '{"event_type":"Trigger workflow for '"$BRANCH"'","client_payload":{"branch": "'"$BRANCH"'"}}'
21+
echo "Request sent!"
22+
else
23+
echo "skipping Workflow activation"
24+
fi

Makefile

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -154,14 +154,17 @@ docker-push: ## Push docker image with the manager.
154154
##@ Deployment
155155

156156
install: manifests kustomize ## Install CRDs into the K8s cluster specified in ~/.kube/config.
157-
$(KUSTOMIZE) build config/crd | kubectl apply -f -
157+
## TODO: Remove sed usage after all v1alpha1 references are updated to v1beta1 in codebase.
158+
## For local testing, conversion webhook defined in crd makes call to webhook for each v1alpha1 reference
159+
## causing failures as we don't set up the webhook for local testing.
160+
$(KUSTOMIZE) build config/crd | sed '/conversion:/,/- v1beta1/d' |kubectl apply --server-side=true -f -
158161

159162
uninstall: manifests kustomize ## Uninstall CRDs from the K8s cluster specified in ~/.kube/config.
160163
$(KUSTOMIZE) build config/crd | kubectl delete --ignore-not-found=true -f -
161164

162165
deploy: manifests kustomize ## Deploy controller to the K8s cluster specified in ~/.kube/config.
163166
cd config/manager && $(KUSTOMIZE) edit set image controller=${IMG}
164-
$(KUSTOMIZE) build config/default | kubectl apply -f -
167+
$(KUSTOMIZE) build config/default | kubectl apply --server-side=true -f -
165168

166169
undeploy: ## Undeploy controller from the K8s cluster specified in ~/.kube/config.
167170
$(KUSTOMIZE) build config/default | kubectl delete --ignore-not-found=true -f -

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ spec:
2727

2828
![a relative link](docs/assets/operatorhub-listing.png)
2929

30-
3. Install the operator using the defaults in the wizard, and wait for it to show up in the list of "Installed Operators". If it doesn't install properly, you can check on its status in the "Installed Operators" tab in the `openshift-operators` namespace.
30+
3. Install the operator in the `openshift-gitops-operator` namesapce using the defaults in the wizard, and optionally, select the checkbox to enable cluster monitoring on the namesapce. Wait for it to show up in the list of "Installed Operators". If it doesn't install properly, you can check on its status in the "Installed Operators" tab in the `openshift-gitops-operator` namespace.
3131

3232
![a relative link](docs/assets/installed-operator.png)
3333

bundle/manifests/argoproj.io_applications.yaml

Lines changed: 154 additions & 14 deletions
Large diffs are not rendered by default.

bundle/manifests/argoproj.io_applicationsets.yaml

Lines changed: 3898 additions & 1896 deletions
Large diffs are not rendered by default.

bundle/manifests/argoproj.io_argocds.yaml

Lines changed: 6412 additions & 26 deletions
Large diffs are not rendered by default.

bundle/manifests/gitops-operator-controller-manager-metrics-service_v1_service.yaml

Lines changed: 0 additions & 16 deletions
This file was deleted.

bundle/manifests/gitops-operator-metrics-reader_rbac.authorization.k8s.io_v1_clusterrole.yaml

Lines changed: 0 additions & 10 deletions
This file was deleted.

bundle/manifests/gitops-operator.clusterserviceversion.yaml

Lines changed: 67 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,8 @@ metadata:
137137
containerImage: quay.io/redhat-developer/gitops-operator
138138
description: Enables teams to adopt GitOps principles for managing cluster configurations
139139
and application delivery across hybrid multi-cluster Kubernetes environments.
140+
operatorframework.io/cluster-monitoring: "true"
141+
operatorframework.io/suggested-namespace: openshift-gitops-operator
140142
operators.openshift.io/infrastructure-features: '["disconnected"]'
141143
operators.operatorframework.io/builder: operator-sdk-v1.10.0+git
142144
operators.operatorframework.io/project_layout: go.kubebuilder.io/v3
@@ -221,6 +223,9 @@ spec:
221223
name: ""
222224
version: v1
223225
version: v1alpha1
226+
- kind: ArgoCD
227+
name: argocds.argoproj.io
228+
version: v1beta1
224229
- kind: ClusterAnalysisTemplate
225230
name: clusteranalysistemplates.argoproj.io
226231
version: v1alpha1
@@ -865,28 +870,34 @@ spec:
865870
- subjectaccessreviews
866871
verbs:
867872
- create
868-
serviceAccountName: gitops-operator-controller-manager
873+
serviceAccountName: openshift-gitops-operator-controller-manager
869874
deployments:
870-
- name: gitops-operator-controller-manager
875+
- name: openshift-gitops-operator-controller-manager
871876
spec:
872877
replicas: 1
873878
selector:
874879
matchLabels:
875-
control-plane: argocd-operator
880+
control-plane: gitops-operator
876881
strategy: {}
877882
template:
878883
metadata:
879884
labels:
880-
control-plane: argocd-operator
885+
control-plane: gitops-operator
881886
spec:
882887
containers:
883-
- command:
888+
- args:
889+
- --health-probe-bind-address=:8081
890+
- --metrics-bind-address=127.0.0.1:8080
891+
- --leader-elect
892+
command:
884893
- /usr/local/bin/manager
885894
env:
886895
- name: ARGOCD_CLUSTER_CONFIG_NAMESPACES
887896
value: openshift-gitops
888897
- name: OPERATOR_NAME
889898
value: gitops-operator
899+
- name: ENABLE_CONVERSION_WEBHOOK
900+
value: "true"
890901
image: quay.io/redhat-developer/gitops-operator:latest
891902
livenessProbe:
892903
httpGet:
@@ -895,6 +906,10 @@ spec:
895906
initialDelaySeconds: 15
896907
periodSeconds: 20
897908
name: manager
909+
ports:
910+
- containerPort: 9443
911+
name: webhook-server
912+
protocol: TCP
898913
readinessProbe:
899914
httpGet:
900915
path: /readyz
@@ -909,10 +924,42 @@ spec:
909924
- ALL
910925
readOnlyRootFilesystem: true
911926
runAsNonRoot: true
927+
- args:
928+
- --secure-listen-address=0.0.0.0:8443
929+
- --upstream=http://127.0.0.1:8080
930+
- --tls-cert-file=/etc/tls/private/tls.crt
931+
- --tls-private-key-file=/etc/tls/private/tls.key
932+
- --logtostderr=true
933+
- --allow-paths=/metrics
934+
image: registry.redhat.io/openshift4/ose-kube-rbac-proxy@sha256:da5d5061dbc2ec5082cf14b6c600fb5400b83cf91d7ccebfa80680a238d275db
935+
name: kube-rbac-proxy
936+
ports:
937+
- containerPort: 8443
938+
name: metrics
939+
resources:
940+
limits:
941+
cpu: 500m
942+
memory: 128Mi
943+
requests:
944+
cpu: 1m
945+
memory: 15Mi
946+
securityContext:
947+
allowPrivilegeEscalation: false
948+
capabilities:
949+
drop:
950+
- ALL
951+
volumeMounts:
952+
- mountPath: /etc/tls/private
953+
name: kube-rbac-proxy-tls
954+
readOnly: true
912955
securityContext:
913956
runAsNonRoot: true
914-
serviceAccountName: gitops-operator-controller-manager
957+
serviceAccountName: openshift-gitops-operator-controller-manager
915958
terminationGracePeriodSeconds: 10
959+
volumes:
960+
- name: kube-rbac-proxy-tls
961+
secret:
962+
secretName: kube-rbac-proxy-tls
916963
permissions:
917964
- rules:
918965
- apiGroups:
@@ -946,7 +993,7 @@ spec:
946993
verbs:
947994
- create
948995
- patch
949-
serviceAccountName: gitops-operator-controller-manager
996+
serviceAccountName: openshift-gitops-operator-controller-manager
950997
strategy: deployment
951998
installModes:
952999
- supported: false
@@ -974,3 +1021,16 @@ spec:
9741021
name: Red Hat Inc
9751022
replaces: gitops-operator.v1.7.3
9761023
version: 1.8.0
1024+
webhookdefinitions:
1025+
- admissionReviewVersions:
1026+
- v1alpha1
1027+
- v1beta1
1028+
containerPort: 443
1029+
conversionCRDs:
1030+
- argocds.argoproj.io
1031+
deploymentName: openshift-gitops-operator-controller-manager
1032+
generateName: cargocds.kb.io
1033+
sideEffects: None
1034+
targetPort: 9443
1035+
type: ConversionWebhook
1036+
webhookPath: /convert

0 commit comments

Comments
 (0)