Skip to content

Commit

Permalink
deploy: indent all yaml files
Browse files Browse the repository at this point in the history
Signed-off-by: Niels de Vos <[email protected]>
  • Loading branch information
nixpanic authored and mergify[bot] committed Jun 16, 2023
1 parent 44ba223 commit ef6efbd
Show file tree
Hide file tree
Showing 51 changed files with 490 additions and 482 deletions.
10 changes: 6 additions & 4 deletions config/certmanager/certificate.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,16 @@ spec:
apiVersion: cert-manager.io/v1
kind: Certificate
metadata:
name: serving-cert # this name should match the one appeared in kustomizeconfig.yaml
# this name should match the one appeared in kustomizeconfig.yaml
name: serving-cert
namespace: system
spec:
# $(SERVICE_NAME) and $(SERVICE_NAMESPACE) will be substituted by kustomize
dnsNames:
- $(SERVICE_NAME).$(SERVICE_NAMESPACE).svc
- $(SERVICE_NAME).$(SERVICE_NAMESPACE).svc.cluster.local
- $(SERVICE_NAME).$(SERVICE_NAMESPACE).svc
- $(SERVICE_NAME).$(SERVICE_NAMESPACE).svc.cluster.local
issuerRef:
kind: Issuer
name: selfsigned-issuer
secretName: webhook-server-cert # this secret will not be prefixed, since it's not managed by kustomize
# this secret will not be prefixed, since it's not managed by kustomize
secretName: webhook-server-cert
4 changes: 2 additions & 2 deletions config/certmanager/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ namespace: csi-addons-system
namePrefix: csi-addons-

resources:
- certificate.yaml
- certificate.yaml

configurations:
- kustomizeconfig.yaml
- kustomizeconfig.yaml
24 changes: 12 additions & 12 deletions config/certmanager/kustomizeconfig.yaml
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
---
# This configuration is for teaching kustomize how to update name ref and var substitution
# This configuration is for teaching kustomize how to update name ref and var substitution
nameReference:
- kind: Issuer
group: cert-manager.io
fieldSpecs:
- kind: Certificate
- kind: Issuer
group: cert-manager.io
path: spec/issuerRef/name
fieldSpecs:
- kind: Certificate
group: cert-manager.io
path: spec/issuerRef/name

varReference:
- kind: Certificate
group: cert-manager.io
path: spec/commonName
- kind: Certificate
group: cert-manager.io
path: spec/dnsNames
- kind: Certificate
group: cert-manager.io
path: spec/commonName
- kind: Certificate
group: cert-manager.io
path: spec/dnsNames
41 changes: 22 additions & 19 deletions config/crd/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,33 +1,36 @@
---
# yamllint disable rule:comments rule:comments-indentation
#
# This kustomization.yaml is not intended to be run by itself,
# since it depends on service name and namespace that are out of this kustomize package.
# It should be run by config/default
resources:
- bases/csiaddons.openshift.io_csiaddonsnodes.yaml
- bases/csiaddons.openshift.io_reclaimspacecronjobs.yaml
- bases/csiaddons.openshift.io_reclaimspacejobs.yaml
- bases/csiaddons.openshift.io_networkfences.yaml
- bases/replication.storage.openshift.io_volumereplications.yaml
- bases/replication.storage.openshift.io_volumereplicationclasses.yaml
- bases/csiaddons.openshift.io_csiaddonsnodes.yaml
- bases/csiaddons.openshift.io_reclaimspacecronjobs.yaml
- bases/csiaddons.openshift.io_reclaimspacejobs.yaml
- bases/csiaddons.openshift.io_networkfences.yaml
- bases/replication.storage.openshift.io_volumereplications.yaml
- bases/replication.storage.openshift.io_volumereplicationclasses.yaml
# yamllint disable-line rule:comments
#+kubebuilder:scaffold:crdkustomizeresource

patchesStrategicMerge:
# [WEBHOOK] To enable webhook, uncomment all the sections with [WEBHOOK] prefix.
# patches here are for enabling the conversion webhook for each CRD
#- patches/webhook_in_csiaddonsnodes.yaml
#- patches/webhook_in_reclaimspacejobs.yaml
#- patches/webhook_in_volumereplications.yaml
#- patches/webhook_in_volumereplicationclasses.yaml
# [WEBHOOK] To enable webhook, uncomment all the sections with [WEBHOOK] prefix.
# patches here are for enabling the conversion webhook for each CRD
#- patches/webhook_in_csiaddonsnodes.yaml
#- patches/webhook_in_reclaimspacejobs.yaml
#- patches/webhook_in_volumereplications.yaml
#- patches/webhook_in_volumereplicationclasses.yaml
#+kubebuilder:scaffold:crdkustomizewebhookpatch

# [CERTMANAGER] To enable cert-manager, uncomment all the sections with [CERTMANAGER] prefix.
# patches here are for enabling the CA injection for each CRD
#- patches/cainjection_in_csiaddonsnodes.yaml
#- patches/cainjection_in_reclaimspacejobs.yaml
#- patches/cainjection_in_volumereplications.yaml
#- patches/cainjection_in_volumereplicationclasses.yaml
# [CERTMANAGER] To enable cert-manager, uncomment all the sections with [CERTMANAGER] prefix.
# patches here are for enabling the CA injection for each CRD
#- patches/cainjection_in_csiaddonsnodes.yaml
#- patches/cainjection_in_reclaimspacejobs.yaml
#- patches/cainjection_in_volumereplications.yaml
#- patches/cainjection_in_volumereplicationclasses.yaml
#+kubebuilder:scaffold:crdkustomizecainjectionpatch

# the following config is for teaching kustomize how to do kustomization for CRDs.
configurations:
- kustomizeconfig.yaml
- kustomizeconfig.yaml
24 changes: 12 additions & 12 deletions config/crd/kustomizeconfig.yaml
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
---
# This file is for teaching kustomize how to substitute name and namespace reference in CRD
nameReference:
- kind: Service
version: v1
fieldSpecs:
- kind: CustomResourceDefinition
- kind: Service
version: v1
group: apiextensions.k8s.io
path: spec/conversion/webhook/clientConfig/service/name
fieldSpecs:
- kind: CustomResourceDefinition
version: v1
group: apiextensions.k8s.io
path: spec/conversion/webhook/clientConfig/service/name

namespace:
- kind: CustomResourceDefinition
version: v1
group: apiextensions.k8s.io
path: spec/conversion/webhook/clientConfig/service/namespace
create: false
- kind: CustomResourceDefinition
version: v1
group: apiextensions.k8s.io
path: spec/conversion/webhook/clientConfig/service/namespace
create: false

varReference:
- path: metadata/annotations
- path: metadata/annotations
2 changes: 1 addition & 1 deletion config/crd/patches/webhook_in_csiaddonsnodes.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ spec:
name: webhook-service
path: /convert
conversionReviewVersions:
- v1
- v1
2 changes: 1 addition & 1 deletion config/crd/patches/webhook_in_networkfences.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ spec:
name: webhook-service
path: /convert
conversionReviewVersions:
- v1
- v1
2 changes: 1 addition & 1 deletion config/crd/patches/webhook_in_reclaimspacejobs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ spec:
name: webhook-service
path: /convert
conversionReviewVersions:
- v1
- v1
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ spec:
name: webhook-service
path: /convert
conversionReviewVersions:
- v1
- v1
2 changes: 1 addition & 1 deletion config/crd/patches/webhook_in_volumereplications.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ spec:
name: webhook-service
path: /convert
conversionReviewVersions:
- v1
- v1
86 changes: 44 additions & 42 deletions config/default/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
---
# yamllint disable rule:comments rule:comments-indentation
#
# Labels to add to all resources and selectors.
#commonLabels:
# someName: someValue
Expand All @@ -13,54 +15,54 @@
#- ../prometheus

patchesStrategicMerge:
# Mount the controller config file for loading manager configurations
# through a ComponentConfig type
#- manager_config_patch.yaml
# Mount the controller config file for loading manager configurations
# through a ComponentConfig type
#- manager_config_patch.yaml

# [WEBHOOK] To enable webhook, uncomment all the sections with [WEBHOOK] prefix including the one in
# crd/kustomization.yaml
- manager_webhook_patch.yaml
# [WEBHOOK] To enable webhook, uncomment all the sections with [WEBHOOK] prefix including the one in
# crd/kustomization.yaml
- manager_webhook_patch.yaml

# [CERTMANAGER] To enable cert-manager, uncomment all sections with 'CERTMANAGER'.
# Uncomment 'CERTMANAGER' sections in crd/kustomization.yaml to enable the CA injection in the admission webhooks.
# 'CERTMANAGER' needs to be enabled to use ca injection
- webhookcainjection_patch.yaml
# [CERTMANAGER] To enable cert-manager, uncomment all sections with 'CERTMANAGER'.
# Uncomment 'CERTMANAGER' sections in crd/kustomization.yaml to enable the CA injection in the admission webhooks.
# 'CERTMANAGER' needs to be enabled to use ca injection
- webhookcainjection_patch.yaml

# the following config is for teaching kustomize how to do var substitution
vars:
# [CERTMANAGER] To enable cert-manager, uncomment all sections with 'CERTMANAGER' prefix.
- name: CERTIFICATE_NAMESPACE # namespace of the certificate CR
objref:
kind: Certificate
group: cert-manager.io
version: v1
name: serving-cert # this name should match the one in certificate.yaml
fieldref:
fieldpath: metadata.namespace
- name: CERTIFICATE_NAME
objref:
kind: Certificate
group: cert-manager.io
version: v1
name: serving-cert # this name should match the one in certificate.yaml
- name: SERVICE_NAMESPACE # namespace of the service
objref:
kind: Service
version: v1
name: webhook-service
fieldref:
fieldpath: metadata.namespace
- name: SERVICE_NAME
objref:
kind: Service
version: v1
name: webhook-service
# [CERTMANAGER] To enable cert-manager, uncomment all sections with 'CERTMANAGER' prefix.
- name: CERTIFICATE_NAMESPACE # namespace of the certificate CR
objref:
kind: Certificate
group: cert-manager.io
version: v1
name: serving-cert # this name should match the one in certificate.yaml
fieldref:
fieldpath: metadata.namespace
- name: CERTIFICATE_NAME
objref:
kind: Certificate
group: cert-manager.io
version: v1
name: serving-cert # this name should match the one in certificate.yaml
- name: SERVICE_NAMESPACE # namespace of the service
objref:
kind: Service
version: v1
name: webhook-service
fieldref:
fieldpath: metadata.namespace
- name: SERVICE_NAME
objref:
kind: Service
version: v1
name: webhook-service

apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- ../crd
- ../rbac
- ../manager
- ../webhook
- ../certmanager
- ../crd
- ../rbac
- ../manager
- ../webhook
- ../certmanager
20 changes: 10 additions & 10 deletions config/default/manager_config_patch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@ spec:
template:
spec:
containers:
- name: manager
args:
- "--config=controller_manager_config.yaml"
volumeMounts:
- name: manager-config
mountPath: /controller_manager_config.yaml
subPath: controller_manager_config.yaml
- name: manager
args:
- "--config=controller_manager_config.yaml"
volumeMounts:
- name: manager-config
mountPath: /controller_manager_config.yaml
subPath: controller_manager_config.yaml
volumes:
- name: manager-config
configMap:
name: manager-config
- name: manager-config
configMap:
name: manager-config
26 changes: 13 additions & 13 deletions config/default/manager_webhook_patch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,17 @@ spec:
template:
spec:
containers:
- name: manager
ports:
- containerPort: 9443
name: webhook-server
protocol: TCP
volumeMounts:
- mountPath: /tmp/k8s-webhook-server/serving-certs
name: cert
readOnly: true
- name: manager
ports:
- containerPort: 9443
name: webhook-server
protocol: TCP
volumeMounts:
- mountPath: /tmp/k8s-webhook-server/serving-certs
name: cert
readOnly: true
volumes:
- name: cert
secret:
defaultMode: 420
secretName: webhook-server-cert
- name: cert
secret:
defaultMode: 420
secretName: webhook-server-cert
1 change: 0 additions & 1 deletion config/manager/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
---
# Adds namespace to all resources.
namespace: csi-addons-system

Expand Down
Loading

0 comments on commit ef6efbd

Please sign in to comment.