- operator-sdk init + create api (QueueService kind, group sqs, v1alpha1) - Стандартная kubebuilder структура: cmd/, internal/controller/, config/ - CRD types с kubebuilder маркерами (validation, defaults, printcolumns) - Reconciler перенесён из ручного кода в internal/controller/ - controller-gen v0.17.0 (совместимость с Go 1.26.1) - Автогенерация: deepcopy, CRD YAML, RBAC ClusterRole - Удалены все ручные файлы (controllers/, main.go, deployments/)
23 lines
941 B
YAML
23 lines
941 B
YAML
# 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/sqs.kube5s.ru_queueservices.yaml
|
|
#+kubebuilder:scaffold:crdkustomizeresource
|
|
|
|
patches:
|
|
# [WEBHOOK] To enable webhook, uncomment all the sections with [WEBHOOK] prefix.
|
|
# patches here are for enabling the conversion webhook for each CRD
|
|
#+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
|
|
#- path: patches/cainjection_in_queueservices.yaml
|
|
#+kubebuilder:scaffold:crdkustomizecainjectionpatch
|
|
|
|
# [WEBHOOK] To enable webhook, uncomment the following section
|
|
# the following config is for teaching kustomize how to do kustomization for CRDs.
|
|
|
|
#configurations:
|
|
#- kustomizeconfig.yaml
|