Skip to content

Commit e27114e

Browse files
committed
chore(crd): prepare for release
Signed-off-by: Denis Karpelevich <[email protected]>
1 parent dcd8f7d commit e27114e

34 files changed

+1055
-165
lines changed

Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ help: ## Display this help.
8282

8383
.PHONY: manifests
8484
manifests: controller-gen ## Generate WebhookConfiguration, ClusterRole and CustomResourceDefinition objects.
85-
$(CONTROLLER_GEN) rbac:roleName=manager-role crd webhook paths="./..." output:crd:artifacts:config=config/crd/bases
85+
$(CONTROLLER_GEN) rbac:roleName=argocd-image-updater-manager-role crd webhook paths="./..." output:crd:artifacts:config=config/crd/bases
8686

8787
.PHONY: generate
8888
generate: controller-gen ## Generate code containing DeepCopy, DeepCopyInto, and DeepCopyObject method implementations.
@@ -160,7 +160,7 @@ docker-buildx: ## Build and push docker image for the manager for cross-platform
160160
.PHONY: build-installer
161161
build-installer: manifests generate kustomize ## Generate a consolidated YAML with CRDs and deployment.
162162
mkdir -p dist
163-
cd config/manager && $(KUSTOMIZE) edit set image controller=${IMG}
163+
cd config/manager && $(KUSTOMIZE) edit set image argocd-image-updater-controller=${IMG}
164164
$(KUSTOMIZE) build config/default > dist/install.yaml
165165

166166
.PHONY: release-binaries
@@ -196,7 +196,7 @@ uninstall: manifests kustomize ## Uninstall CRDs from the K8s cluster specified
196196

197197
.PHONY: deploy
198198
deploy: manifests kustomize ## Deploy controller to the K8s cluster specified in ~/.kube/config.
199-
cd config/manager && $(KUSTOMIZE) edit set image controller=${IMG}
199+
cd config/manager && $(KUSTOMIZE) edit set image argocd-image-updater-controller=${IMG}
200200
$(KUSTOMIZE) build config/default | $(KUBECTL) apply -f -
201201

202202
.PHONY: undeploy

api/v1alpha1/imageupdater_types.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -274,6 +274,7 @@ type ImageApplicationLastUpdated struct {
274274

275275
// +kubebuilder:object:root=true
276276
// +kubebuilder:subresource:status
277+
// +kubebuilder:resource:scope=Cluster
277278

278279
// ImageUpdater is the Schema for the imageupdaters API
279280
type ImageUpdater struct {

config/crd/bases/argocd-image-updater.argoproj.io_imageupdaters.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ spec:
1212
listKind: ImageUpdaterList
1313
plural: imageupdaters
1414
singular: imageupdater
15-
scope: Namespaced
15+
scope: Cluster
1616
versions:
1717
- name: v1alpha1
1818
schema:
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
apiVersion: v1
2+
kind: ConfigMap
3+
metadata:
4+
name: argocd-image-updater-config
5+
labels:
6+
app.kubernetes.io/name: argocd-image-updater-config
7+
app.kubernetes.io/part-of: argocd-image-updater-controller
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
apiVersion: v1
2+
kind: Secret
3+
metadata:
4+
name: argocd-image-updater-secret
5+
labels:
6+
app.kubernetes.io/name: argocd-image-updater-secret
7+
app.kubernetes.io/part-of: argocd-image-updater-controller
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
apiVersion: v1
2+
kind: ConfigMap
3+
metadata:
4+
name: argocd-image-updater-ssh-config
5+
labels:
6+
app.kubernetes.io/name: argocd-image-updater-ssh-config
7+
app.kubernetes.io/part-of: argocd-image-updater-controller

config/default/image-updater-cm.yaml

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

config/default/image-updater-secret.yaml

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

config/default/image-updater-ssh-config.yaml

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

config/default/kustomization.yaml

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,5 @@
11
# Adds namespace to all resources.
2-
namespace: image-updater-system
3-
4-
# Value of this field is prepended to the
5-
# names of all resources, e.g. a deployment named
6-
# "wordpress" becomes "alices-wordpress".
7-
# Note that it should also match with the prefix (text before '-') of the namespace
8-
# field above.
9-
namePrefix: image-updater-
2+
namespace: argocd-image-updater-system
103

114
# Labels to add to all resources and selectors.
125
#labels:
@@ -15,9 +8,9 @@ namePrefix: image-updater-
158
# someName: someValue
169

1710
resources:
18-
- image-updater-cm.yaml
19-
- image-updater-secret.yaml
20-
- image-updater-ssh-config.yaml
11+
- argocd-image-updater-cm.yaml
12+
- argocd-image-updater-secret.yaml
13+
- argocd-image-updater-ssh-config.yaml
2114
- ../crd
2215
- ../rbac
2316
- ../manager
@@ -29,7 +22,7 @@ resources:
2922
# [PROMETHEUS] To enable prometheus monitor, uncomment all sections with 'PROMETHEUS'.
3023
#- ../prometheus
3124
# [METRICS] Expose the controller manager metrics service.
32-
- metrics_service.yaml
25+
#- metrics_service.yaml
3326
# [NETWORK POLICY] Protect the /metrics endpoint and Webhook Server with NetworkPolicy.
3427
# Only Pod(s) running a namespace labeled with 'metrics: enabled' will be able to gather the metrics.
3528
# Only CR(s) which requires webhooks and are applied on namespaces labeled with 'webhooks: enabled' will

0 commit comments

Comments
 (0)