Full Code of kubernetes-sigs/kubebuilder for AI

master c32187afc7ef cached
1314 files
7.0 MB
1.9M tokens
2817 symbols
1 requests
Download .txt
Showing preview only (7,664K chars total). Download the full file or copy to clipboard to get everything.
Repository: kubernetes-sigs/kubebuilder
Branch: master
Commit: c32187afc7ef
Files: 1314
Total size: 7.0 MB

Directory structure:
gitextract_fvvnmo3k/

├── .github/
│   ├── ISSUE_TEMPLATE/
│   │   ├── bug_report.yaml
│   │   ├── config.yml
│   │   └── feature_request.yaml
│   ├── PULL_REQUEST_TEMPLATE.md
│   ├── SECURITY.md
│   ├── dependabot.yml
│   ├── instructions/
│   │   └── kubebuilder.instructions.md
│   └── workflows/
│       ├── apidiff.yml
│       ├── codeql.yml
│       ├── coverage.yml
│       ├── cross-platform-tests.yml
│       ├── external-plugin.yml
│       ├── legacy-webhook-path.yml
│       ├── lint-sample.yml
│       ├── lint.yml
│       ├── release-version-ci.yml
│       ├── release.yml
│       ├── scorecard.yml
│       ├── spaces.yml
│       ├── test-alpha-generate.yml
│       ├── test-book.yml
│       ├── test-devcontainer.yml
│       ├── test-e2e-samples.yml
│       ├── test-helm-book.yml
│       ├── test-helm-samples.yml
│       ├── testdata.yml
│       └── verify.yml
├── .gitignore
├── .golangci.yml
├── .yamllint
├── .yamllint-helm
├── AGENTS.md
├── CONTRIBUTING.md
├── DESIGN.md
├── LICENSE
├── Makefile
├── OWNERS
├── OWNERS_ALIASES
├── README.md
├── RELEASE.md
├── SECURITY_CONTACTS
├── VERSIONING.md
├── build/
│   └── .goreleaser.yml
├── code-of-conduct.md
├── designs/
│   ├── README.md
│   ├── code-generate-image-plugin.md
│   ├── crd_version_conversion.md
│   ├── discontinue_usage_of_kube_rbac_proxy.md
│   ├── extensible-cli-and-scaffolding-plugins-phase-1-5.md
│   ├── extensible-cli-and-scaffolding-plugins-phase-1.md
│   ├── extensible-cli-and-scaffolding-plugins-phase-2.md
│   ├── helm-chart-autogenerate-plugin.md
│   ├── helper_to_upgrade_projects_by_rescaffolding.md
│   ├── integrating-kubebuilder-and-osdk.md
│   ├── simplified-scaffolding.md
│   ├── template.md
│   └── update_action.md
├── docs/
│   ├── CONTRIBUTING-ROLES.md
│   ├── README.md
│   ├── book/
│   │   ├── .firebaserc
│   │   ├── book.toml
│   │   ├── functions/
│   │   │   └── handle-version.js
│   │   ├── install-and-build.sh
│   │   ├── litgo.sh
│   │   ├── markerdocs.sh
│   │   ├── src/
│   │   │   ├── SUMMARY.md
│   │   │   ├── TODO.md
│   │   │   ├── architecture.md
│   │   │   ├── cronjob-tutorial/
│   │   │   │   ├── api-design.md
│   │   │   │   ├── basic-project.md
│   │   │   │   ├── cert-manager.md
│   │   │   │   ├── controller-implementation.md
│   │   │   │   ├── controller-overview.md
│   │   │   │   ├── cronjob-tutorial.md
│   │   │   │   ├── empty-main.md
│   │   │   │   ├── gvks.md
│   │   │   │   ├── main-revisited.md
│   │   │   │   ├── new-api.md
│   │   │   │   ├── other-api-files.md
│   │   │   │   ├── running-webhook.md
│   │   │   │   ├── running.md
│   │   │   │   ├── testdata/
│   │   │   │   │   ├── emptyapi.go
│   │   │   │   │   ├── emptycontroller.go
│   │   │   │   │   ├── emptymain.go
│   │   │   │   │   ├── finalizer_example.go
│   │   │   │   │   └── project/
│   │   │   │   │       ├── .custom-gcl.yml
│   │   │   │   │       ├── .devcontainer/
│   │   │   │   │       │   ├── devcontainer.json
│   │   │   │   │       │   └── post-install.sh
│   │   │   │   │       ├── .dockerignore
│   │   │   │   │       ├── .github/
│   │   │   │   │       │   └── workflows/
│   │   │   │   │       │       ├── lint.yml
│   │   │   │   │       │       ├── test-chart.yml
│   │   │   │   │       │       ├── test-e2e.yml
│   │   │   │   │       │       └── test.yml
│   │   │   │   │       ├── .gitignore
│   │   │   │   │       ├── .golangci.yml
│   │   │   │   │       ├── AGENTS.md
│   │   │   │   │       ├── Dockerfile
│   │   │   │   │       ├── Makefile
│   │   │   │   │       ├── PROJECT
│   │   │   │   │       ├── README.md
│   │   │   │   │       ├── api/
│   │   │   │   │       │   └── v1/
│   │   │   │   │       │       ├── cronjob_types.go
│   │   │   │   │       │       ├── groupversion_info.go
│   │   │   │   │       │       └── zz_generated.deepcopy.go
│   │   │   │   │       ├── cmd/
│   │   │   │   │       │   └── main.go
│   │   │   │   │       ├── config/
│   │   │   │   │       │   ├── certmanager/
│   │   │   │   │       │   │   ├── certificate-metrics.yaml
│   │   │   │   │       │   │   ├── certificate-webhook.yaml
│   │   │   │   │       │   │   ├── issuer.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   └── kustomizeconfig.yaml
│   │   │   │   │       │   ├── crd/
│   │   │   │   │       │   │   ├── bases/
│   │   │   │   │       │   │   │   └── batch.tutorial.kubebuilder.io_cronjobs.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   └── kustomizeconfig.yaml
│   │   │   │   │       │   ├── default/
│   │   │   │   │       │   │   ├── cert_metrics_manager_patch.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   ├── manager_metrics_patch.yaml
│   │   │   │   │       │   │   ├── manager_webhook_patch.yaml
│   │   │   │   │       │   │   └── metrics_service.yaml
│   │   │   │   │       │   ├── manager/
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   └── manager.yaml
│   │   │   │   │       │   ├── network-policy/
│   │   │   │   │       │   │   ├── allow-metrics-traffic.yaml
│   │   │   │   │       │   │   ├── allow-webhook-traffic.yaml
│   │   │   │   │       │   │   └── kustomization.yaml
│   │   │   │   │       │   ├── prometheus/
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   ├── monitor.yaml
│   │   │   │   │       │   │   └── monitor_tls_patch.yaml
│   │   │   │   │       │   ├── rbac/
│   │   │   │   │       │   │   ├── cronjob_admin_role.yaml
│   │   │   │   │       │   │   ├── cronjob_editor_role.yaml
│   │   │   │   │       │   │   ├── cronjob_viewer_role.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   ├── leader_election_role.yaml
│   │   │   │   │       │   │   ├── leader_election_role_binding.yaml
│   │   │   │   │       │   │   ├── metrics_auth_role.yaml
│   │   │   │   │       │   │   ├── metrics_auth_role_binding.yaml
│   │   │   │   │       │   │   ├── metrics_reader_role.yaml
│   │   │   │   │       │   │   ├── role.yaml
│   │   │   │   │       │   │   ├── role_binding.yaml
│   │   │   │   │       │   │   └── service_account.yaml
│   │   │   │   │       │   ├── samples/
│   │   │   │   │       │   │   ├── batch_v1_cronjob.yaml
│   │   │   │   │       │   │   └── kustomization.yaml
│   │   │   │   │       │   └── webhook/
│   │   │   │   │       │       ├── kustomization.yaml
│   │   │   │   │       │       ├── manifests.yaml
│   │   │   │   │       │       └── service.yaml
│   │   │   │   │       ├── dist/
│   │   │   │   │       │   ├── chart/
│   │   │   │   │       │   │   ├── .helmignore
│   │   │   │   │       │   │   ├── Chart.yaml
│   │   │   │   │       │   │   ├── templates/
│   │   │   │   │       │   │   │   ├── NOTES.txt
│   │   │   │   │       │   │   │   ├── _helpers.tpl
│   │   │   │   │       │   │   │   ├── cert-manager/
│   │   │   │   │       │   │   │   │   ├── metrics-certs.yaml
│   │   │   │   │       │   │   │   │   ├── selfsigned-issuer.yaml
│   │   │   │   │       │   │   │   │   └── serving-cert.yaml
│   │   │   │   │       │   │   │   ├── crd/
│   │   │   │   │       │   │   │   │   └── cronjobs.batch.tutorial.kubebuilder.io.yaml
│   │   │   │   │       │   │   │   ├── manager/
│   │   │   │   │       │   │   │   │   └── manager.yaml
│   │   │   │   │       │   │   │   ├── metrics/
│   │   │   │   │       │   │   │   │   └── controller-manager-metrics-service.yaml
│   │   │   │   │       │   │   │   ├── prometheus/
│   │   │   │   │       │   │   │   │   └── controller-manager-metrics-monitor.yaml
│   │   │   │   │       │   │   │   ├── rbac/
│   │   │   │   │       │   │   │   │   ├── controller-manager.yaml
│   │   │   │   │       │   │   │   │   ├── cronjob-admin-role.yaml
│   │   │   │   │       │   │   │   │   ├── cronjob-editor-role.yaml
│   │   │   │   │       │   │   │   │   ├── cronjob-viewer-role.yaml
│   │   │   │   │       │   │   │   │   ├── leader-election-role.yaml
│   │   │   │   │       │   │   │   │   ├── leader-election-rolebinding.yaml
│   │   │   │   │       │   │   │   │   ├── manager-role.yaml
│   │   │   │   │       │   │   │   │   ├── manager-rolebinding.yaml
│   │   │   │   │       │   │   │   │   ├── metrics-auth-role.yaml
│   │   │   │   │       │   │   │   │   ├── metrics-auth-rolebinding.yaml
│   │   │   │   │       │   │   │   │   └── metrics-reader.yaml
│   │   │   │   │       │   │   │   └── webhook/
│   │   │   │   │       │   │   │       ├── mutating-webhook-configuration.yaml
│   │   │   │   │       │   │   │       ├── validating-webhook-configuration.yaml
│   │   │   │   │       │   │   │       └── webhook-service.yaml
│   │   │   │   │       │   │   └── values.yaml
│   │   │   │   │       │   └── install.yaml
│   │   │   │   │       ├── go.mod
│   │   │   │   │       ├── go.sum
│   │   │   │   │       ├── hack/
│   │   │   │   │       │   └── boilerplate.go.txt
│   │   │   │   │       ├── internal/
│   │   │   │   │       │   ├── controller/
│   │   │   │   │       │   │   ├── cronjob_controller.go
│   │   │   │   │       │   │   ├── cronjob_controller_test.go
│   │   │   │   │       │   │   └── suite_test.go
│   │   │   │   │       │   └── webhook/
│   │   │   │   │       │       └── v1/
│   │   │   │   │       │           ├── cronjob_webhook.go
│   │   │   │   │       │           ├── cronjob_webhook_test.go
│   │   │   │   │       │           └── webhook_suite_test.go
│   │   │   │   │       └── test/
│   │   │   │   │           ├── e2e/
│   │   │   │   │           │   ├── e2e_suite_test.go
│   │   │   │   │           │   └── e2e_test.go
│   │   │   │   │           └── utils/
│   │   │   │   │               └── utils.go
│   │   │   │   ├── webhook-implementation.md
│   │   │   │   └── writing-tests.md
│   │   │   ├── faq.md
│   │   │   ├── getting-started/
│   │   │   │   └── testdata/
│   │   │   │       └── project/
│   │   │   │           ├── .custom-gcl.yml
│   │   │   │           ├── .devcontainer/
│   │   │   │           │   ├── devcontainer.json
│   │   │   │           │   └── post-install.sh
│   │   │   │           ├── .dockerignore
│   │   │   │           ├── .github/
│   │   │   │           │   └── workflows/
│   │   │   │           │       ├── auto_update.yml
│   │   │   │           │       ├── lint.yml
│   │   │   │           │       ├── test-chart.yml
│   │   │   │           │       ├── test-e2e.yml
│   │   │   │           │       └── test.yml
│   │   │   │           ├── .gitignore
│   │   │   │           ├── .golangci.yml
│   │   │   │           ├── AGENTS.md
│   │   │   │           ├── Dockerfile
│   │   │   │           ├── Makefile
│   │   │   │           ├── PROJECT
│   │   │   │           ├── README.md
│   │   │   │           ├── api/
│   │   │   │           │   └── v1alpha1/
│   │   │   │           │       ├── groupversion_info.go
│   │   │   │           │       ├── memcached_types.go
│   │   │   │           │       └── zz_generated.deepcopy.go
│   │   │   │           ├── cmd/
│   │   │   │           │   └── main.go
│   │   │   │           ├── config/
│   │   │   │           │   ├── crd/
│   │   │   │           │   │   ├── bases/
│   │   │   │           │   │   │   └── cache.example.com_memcacheds.yaml
│   │   │   │           │   │   ├── kustomization.yaml
│   │   │   │           │   │   └── kustomizeconfig.yaml
│   │   │   │           │   ├── default/
│   │   │   │           │   │   ├── cert_metrics_manager_patch.yaml
│   │   │   │           │   │   ├── kustomization.yaml
│   │   │   │           │   │   ├── manager_metrics_patch.yaml
│   │   │   │           │   │   └── metrics_service.yaml
│   │   │   │           │   ├── manager/
│   │   │   │           │   │   ├── kustomization.yaml
│   │   │   │           │   │   └── manager.yaml
│   │   │   │           │   ├── network-policy/
│   │   │   │           │   │   ├── allow-metrics-traffic.yaml
│   │   │   │           │   │   └── kustomization.yaml
│   │   │   │           │   ├── prometheus/
│   │   │   │           │   │   ├── kustomization.yaml
│   │   │   │           │   │   ├── monitor.yaml
│   │   │   │           │   │   └── monitor_tls_patch.yaml
│   │   │   │           │   ├── rbac/
│   │   │   │           │   │   ├── kustomization.yaml
│   │   │   │           │   │   ├── leader_election_role.yaml
│   │   │   │           │   │   ├── leader_election_role_binding.yaml
│   │   │   │           │   │   ├── memcached_admin_role.yaml
│   │   │   │           │   │   ├── memcached_editor_role.yaml
│   │   │   │           │   │   ├── memcached_viewer_role.yaml
│   │   │   │           │   │   ├── metrics_auth_role.yaml
│   │   │   │           │   │   ├── metrics_auth_role_binding.yaml
│   │   │   │           │   │   ├── metrics_reader_role.yaml
│   │   │   │           │   │   ├── role.yaml
│   │   │   │           │   │   ├── role_binding.yaml
│   │   │   │           │   │   └── service_account.yaml
│   │   │   │           │   └── samples/
│   │   │   │           │       ├── cache_v1alpha1_memcached.yaml
│   │   │   │           │       └── kustomization.yaml
│   │   │   │           ├── dist/
│   │   │   │           │   ├── chart/
│   │   │   │           │   │   ├── .helmignore
│   │   │   │           │   │   ├── Chart.yaml
│   │   │   │           │   │   ├── templates/
│   │   │   │           │   │   │   ├── NOTES.txt
│   │   │   │           │   │   │   ├── _helpers.tpl
│   │   │   │           │   │   │   ├── crd/
│   │   │   │           │   │   │   │   └── memcacheds.cache.example.com.yaml
│   │   │   │           │   │   │   ├── manager/
│   │   │   │           │   │   │   │   └── manager.yaml
│   │   │   │           │   │   │   ├── metrics/
│   │   │   │           │   │   │   │   └── controller-manager-metrics-service.yaml
│   │   │   │           │   │   │   ├── monitoring/
│   │   │   │           │   │   │   │   └── servicemonitor.yaml
│   │   │   │           │   │   │   └── rbac/
│   │   │   │           │   │   │       ├── controller-manager.yaml
│   │   │   │           │   │   │       ├── leader-election-role.yaml
│   │   │   │           │   │   │       ├── leader-election-rolebinding.yaml
│   │   │   │           │   │   │       ├── manager-role.yaml
│   │   │   │           │   │   │       ├── manager-rolebinding.yaml
│   │   │   │           │   │   │       ├── memcached-admin-role.yaml
│   │   │   │           │   │   │       ├── memcached-editor-role.yaml
│   │   │   │           │   │   │       ├── memcached-viewer-role.yaml
│   │   │   │           │   │   │       ├── metrics-auth-role.yaml
│   │   │   │           │   │   │       ├── metrics-auth-rolebinding.yaml
│   │   │   │           │   │   │       └── metrics-reader.yaml
│   │   │   │           │   │   └── values.yaml
│   │   │   │           │   └── install.yaml
│   │   │   │           ├── go.mod
│   │   │   │           ├── go.sum
│   │   │   │           ├── hack/
│   │   │   │           │   └── boilerplate.go.txt
│   │   │   │           ├── internal/
│   │   │   │           │   └── controller/
│   │   │   │           │       ├── memcached_controller.go
│   │   │   │           │       ├── memcached_controller_test.go
│   │   │   │           │       └── suite_test.go
│   │   │   │           └── test/
│   │   │   │               ├── e2e/
│   │   │   │               │   ├── e2e_suite_test.go
│   │   │   │               │   └── e2e_test.go
│   │   │   │               └── utils/
│   │   │   │                   └── utils.go
│   │   │   ├── getting-started.md
│   │   │   ├── introduction.md
│   │   │   ├── logos/
│   │   │   │   └── README.md
│   │   │   ├── migration/
│   │   │   │   ├── ai-helpers.md
│   │   │   │   ├── discovery-commands.md
│   │   │   │   ├── manual-process.md
│   │   │   │   ├── multi-group.md
│   │   │   │   ├── namespace-scoped.md
│   │   │   │   ├── port-code.md
│   │   │   │   └── reorganize-layout.md
│   │   │   ├── migrations.md
│   │   │   ├── multiversion-tutorial/
│   │   │   │   ├── api-changes.md
│   │   │   │   ├── conversion-concepts.md
│   │   │   │   ├── conversion.md
│   │   │   │   ├── deployment.md
│   │   │   │   ├── testdata/
│   │   │   │   │   └── project/
│   │   │   │   │       ├── .custom-gcl.yml
│   │   │   │   │       ├── .devcontainer/
│   │   │   │   │       │   ├── devcontainer.json
│   │   │   │   │       │   └── post-install.sh
│   │   │   │   │       ├── .dockerignore
│   │   │   │   │       ├── .github/
│   │   │   │   │       │   └── workflows/
│   │   │   │   │       │       ├── lint.yml
│   │   │   │   │       │       ├── test-chart.yml
│   │   │   │   │       │       ├── test-e2e.yml
│   │   │   │   │       │       └── test.yml
│   │   │   │   │       ├── .gitignore
│   │   │   │   │       ├── .golangci.yml
│   │   │   │   │       ├── AGENTS.md
│   │   │   │   │       ├── Dockerfile
│   │   │   │   │       ├── Makefile
│   │   │   │   │       ├── PROJECT
│   │   │   │   │       ├── README.md
│   │   │   │   │       ├── api/
│   │   │   │   │       │   ├── v1/
│   │   │   │   │       │   │   ├── cronjob_conversion.go
│   │   │   │   │       │   │   ├── cronjob_types.go
│   │   │   │   │       │   │   ├── groupversion_info.go
│   │   │   │   │       │   │   └── zz_generated.deepcopy.go
│   │   │   │   │       │   └── v2/
│   │   │   │   │       │       ├── cronjob_conversion.go
│   │   │   │   │       │       ├── cronjob_types.go
│   │   │   │   │       │       ├── groupversion_info.go
│   │   │   │   │       │       └── zz_generated.deepcopy.go
│   │   │   │   │       ├── cmd/
│   │   │   │   │       │   └── main.go
│   │   │   │   │       ├── config/
│   │   │   │   │       │   ├── certmanager/
│   │   │   │   │       │   │   ├── certificate-metrics.yaml
│   │   │   │   │       │   │   ├── certificate-webhook.yaml
│   │   │   │   │       │   │   ├── issuer.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   └── kustomizeconfig.yaml
│   │   │   │   │       │   ├── crd/
│   │   │   │   │       │   │   ├── bases/
│   │   │   │   │       │   │   │   └── batch.tutorial.kubebuilder.io_cronjobs.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   ├── kustomizeconfig.yaml
│   │   │   │   │       │   │   └── patches/
│   │   │   │   │       │   │       └── webhook_in_cronjobs.yaml
│   │   │   │   │       │   ├── default/
│   │   │   │   │       │   │   ├── cert_metrics_manager_patch.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   ├── manager_metrics_patch.yaml
│   │   │   │   │       │   │   ├── manager_webhook_patch.yaml
│   │   │   │   │       │   │   └── metrics_service.yaml
│   │   │   │   │       │   ├── manager/
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   └── manager.yaml
│   │   │   │   │       │   ├── network-policy/
│   │   │   │   │       │   │   ├── allow-metrics-traffic.yaml
│   │   │   │   │       │   │   ├── allow-webhook-traffic.yaml
│   │   │   │   │       │   │   └── kustomization.yaml
│   │   │   │   │       │   ├── prometheus/
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   ├── monitor.yaml
│   │   │   │   │       │   │   └── monitor_tls_patch.yaml
│   │   │   │   │       │   ├── rbac/
│   │   │   │   │       │   │   ├── cronjob_admin_role.yaml
│   │   │   │   │       │   │   ├── cronjob_editor_role.yaml
│   │   │   │   │       │   │   ├── cronjob_viewer_role.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   ├── leader_election_role.yaml
│   │   │   │   │       │   │   ├── leader_election_role_binding.yaml
│   │   │   │   │       │   │   ├── metrics_auth_role.yaml
│   │   │   │   │       │   │   ├── metrics_auth_role_binding.yaml
│   │   │   │   │       │   │   ├── metrics_reader_role.yaml
│   │   │   │   │       │   │   ├── role.yaml
│   │   │   │   │       │   │   ├── role_binding.yaml
│   │   │   │   │       │   │   └── service_account.yaml
│   │   │   │   │       │   ├── samples/
│   │   │   │   │       │   │   ├── batch_v1_cronjob.yaml
│   │   │   │   │       │   │   ├── batch_v2_cronjob.yaml
│   │   │   │   │       │   │   └── kustomization.yaml
│   │   │   │   │       │   └── webhook/
│   │   │   │   │       │       ├── kustomization.yaml
│   │   │   │   │       │       ├── manifests.yaml
│   │   │   │   │       │       └── service.yaml
│   │   │   │   │       ├── dist/
│   │   │   │   │       │   ├── chart/
│   │   │   │   │       │   │   ├── .helmignore
│   │   │   │   │       │   │   ├── Chart.yaml
│   │   │   │   │       │   │   ├── templates/
│   │   │   │   │       │   │   │   ├── NOTES.txt
│   │   │   │   │       │   │   │   ├── _helpers.tpl
│   │   │   │   │       │   │   │   ├── cert-manager/
│   │   │   │   │       │   │   │   │   ├── metrics-certs.yaml
│   │   │   │   │       │   │   │   │   ├── selfsigned-issuer.yaml
│   │   │   │   │       │   │   │   │   └── serving-cert.yaml
│   │   │   │   │       │   │   │   ├── crd/
│   │   │   │   │       │   │   │   │   └── cronjobs.batch.tutorial.kubebuilder.io.yaml
│   │   │   │   │       │   │   │   ├── manager/
│   │   │   │   │       │   │   │   │   └── manager.yaml
│   │   │   │   │       │   │   │   ├── metrics/
│   │   │   │   │       │   │   │   │   └── controller-manager-metrics-service.yaml
│   │   │   │   │       │   │   │   ├── prometheus/
│   │   │   │   │       │   │   │   │   └── controller-manager-metrics-monitor.yaml
│   │   │   │   │       │   │   │   ├── rbac/
│   │   │   │   │       │   │   │   │   ├── controller-manager.yaml
│   │   │   │   │       │   │   │   │   ├── cronjob-admin-role.yaml
│   │   │   │   │       │   │   │   │   ├── cronjob-editor-role.yaml
│   │   │   │   │       │   │   │   │   ├── cronjob-viewer-role.yaml
│   │   │   │   │       │   │   │   │   ├── leader-election-role.yaml
│   │   │   │   │       │   │   │   │   ├── leader-election-rolebinding.yaml
│   │   │   │   │       │   │   │   │   ├── manager-role.yaml
│   │   │   │   │       │   │   │   │   ├── manager-rolebinding.yaml
│   │   │   │   │       │   │   │   │   ├── metrics-auth-role.yaml
│   │   │   │   │       │   │   │   │   ├── metrics-auth-rolebinding.yaml
│   │   │   │   │       │   │   │   │   └── metrics-reader.yaml
│   │   │   │   │       │   │   │   └── webhook/
│   │   │   │   │       │   │   │       ├── mutating-webhook-configuration.yaml
│   │   │   │   │       │   │   │       ├── validating-webhook-configuration.yaml
│   │   │   │   │       │   │   │       └── webhook-service.yaml
│   │   │   │   │       │   │   └── values.yaml
│   │   │   │   │       │   └── install.yaml
│   │   │   │   │       ├── go.mod
│   │   │   │   │       ├── go.sum
│   │   │   │   │       ├── hack/
│   │   │   │   │       │   └── boilerplate.go.txt
│   │   │   │   │       ├── internal/
│   │   │   │   │       │   ├── controller/
│   │   │   │   │       │   │   ├── cronjob_controller.go
│   │   │   │   │       │   │   ├── cronjob_controller_test.go
│   │   │   │   │       │   │   └── suite_test.go
│   │   │   │   │       │   └── webhook/
│   │   │   │   │       │       ├── v1/
│   │   │   │   │       │       │   ├── cronjob_webhook.go
│   │   │   │   │       │       │   ├── cronjob_webhook_test.go
│   │   │   │   │       │       │   └── webhook_suite_test.go
│   │   │   │   │       │       └── v2/
│   │   │   │   │       │           ├── cronjob_webhook.go
│   │   │   │   │       │           ├── cronjob_webhook_test.go
│   │   │   │   │       │           └── webhook_suite_test.go
│   │   │   │   │       └── test/
│   │   │   │   │           ├── e2e/
│   │   │   │   │           │   ├── e2e_suite_test.go
│   │   │   │   │           │   └── e2e_test.go
│   │   │   │   │           └── utils/
│   │   │   │   │               └── utils.go
│   │   │   │   ├── tutorial.md
│   │   │   │   └── webhooks.md
│   │   │   ├── plugins/
│   │   │   │   ├── available/
│   │   │   │   │   ├── autoupdate-v1-alpha.md
│   │   │   │   │   ├── deploy-image-plugin-v1-alpha.md
│   │   │   │   │   ├── go-v4-plugin.md
│   │   │   │   │   ├── grafana-v1-alpha.md
│   │   │   │   │   ├── helm-v1-alpha.md
│   │   │   │   │   ├── helm-v2-alpha.md
│   │   │   │   │   └── kustomize-v2.md
│   │   │   │   ├── available-plugins.md
│   │   │   │   ├── extending/
│   │   │   │   │   ├── custom-markers.md
│   │   │   │   │   ├── extending_cli_features_and_plugins.md
│   │   │   │   │   ├── external-plugins.md
│   │   │   │   │   └── testing-plugins.md
│   │   │   │   ├── extending.md
│   │   │   │   ├── kustomize-v2.md
│   │   │   │   ├── plugins-versioning.md
│   │   │   │   ├── plugins.md
│   │   │   │   ├── to-add-optional-features.md
│   │   │   │   ├── to-be-extended.md
│   │   │   │   └── to-scaffold-project.md
│   │   │   ├── quick-start.md
│   │   │   ├── reference/
│   │   │   │   ├── admission-webhook.md
│   │   │   │   ├── alpha_commands.md
│   │   │   │   ├── artifacts.md
│   │   │   │   ├── commands/
│   │   │   │   │   ├── alpha_generate.md
│   │   │   │   │   └── alpha_update.md
│   │   │   │   ├── completion.md
│   │   │   │   ├── controller-gen.md
│   │   │   │   ├── crd-scope.md
│   │   │   │   ├── envtest.md
│   │   │   │   ├── generating-crd.md
│   │   │   │   ├── good-practices.md
│   │   │   │   ├── kind-config.yaml
│   │   │   │   ├── kind.md
│   │   │   │   ├── manager-scope.md
│   │   │   │   ├── markers/
│   │   │   │   │   ├── crd-processing.md
│   │   │   │   │   ├── crd-validation.md
│   │   │   │   │   ├── crd.md
│   │   │   │   │   ├── object.md
│   │   │   │   │   ├── rbac.md
│   │   │   │   │   ├── scaffold.md
│   │   │   │   │   └── webhook.md
│   │   │   │   ├── markers.md
│   │   │   │   ├── metrics-reference.md
│   │   │   │   ├── metrics.md
│   │   │   │   ├── platform.md
│   │   │   │   ├── pprof-tutorial.md
│   │   │   │   ├── project-config.md
│   │   │   │   ├── raising-events.md
│   │   │   │   ├── reference.md
│   │   │   │   ├── scopes.md
│   │   │   │   ├── submodule-layouts.md
│   │   │   │   ├── using-finalizers.md
│   │   │   │   ├── using_an_external_resource.md
│   │   │   │   ├── watching-resources/
│   │   │   │   │   ├── predicates-with-watch.md
│   │   │   │   │   ├── secondary-owned-resources.md
│   │   │   │   │   └── secondary-resources-not-owned.md
│   │   │   │   ├── watching-resources.md
│   │   │   │   ├── webhook-bootstrap-problem.md
│   │   │   │   └── webhook-overview.md
│   │   │   └── versions_compatibility_supportability.md
│   │   ├── theme/
│   │   │   ├── css/
│   │   │   │   ├── custom.css
│   │   │   │   ├── markers.css
│   │   │   │   └── version-dropdown.css
│   │   │   └── index.hbs
│   │   └── utils/
│   │       ├── go.mod
│   │       ├── go.sum
│   │       ├── litgo/
│   │       │   └── literate.go
│   │       ├── markerdocs/
│   │       │   ├── doctypes.go
│   │       │   ├── html.go
│   │       │   └── main.go
│   │       └── plugin/
│   │           ├── input.go
│   │           ├── plugin.go
│   │           └── utils.go
│   ├── kubebuilder_annotation.md
│   ├── kubebuilder_v0_v1_difference.md
│   ├── migration_guide.md
│   ├── testing/
│   │   ├── e2e.md
│   │   └── integration.md
│   └── windows.md
├── go.mod
├── go.sum
├── hack/
│   ├── docs/
│   │   ├── check.sh
│   │   ├── generate.sh
│   │   ├── generate_samples.go
│   │   └── internal/
│   │       ├── cronjob-tutorial/
│   │       │   ├── api_design.go
│   │       │   ├── controller_implementation.go
│   │       │   ├── e2e_implementation.go
│   │       │   ├── generate_cronjob.go
│   │       │   ├── main_revisited.go
│   │       │   ├── other_api_files.go
│   │       │   ├── sample.go
│   │       │   ├── webhook_implementation.go
│   │       │   ├── writing_tests_controller.go
│   │       │   └── writing_tests_env.go
│   │       ├── getting-started/
│   │       │   └── generate_getting_started.go
│   │       ├── multiversion-tutorial/
│   │       │   ├── controller_tests_code.go
│   │       │   ├── cronjob_v1.go
│   │       │   ├── cronjob_v2.go
│   │       │   ├── generate_multiversion.go
│   │       │   ├── hub.go
│   │       │   ├── samples.go
│   │       │   └── webhook_v2_implementaton.go
│   │       └── utils/
│   │           └── utils.go
│   └── test/
│       └── check_go_module.go
├── internal/
│   ├── cli/
│   │   ├── alpha/
│   │   │   ├── generate.go
│   │   │   ├── generate_test.go
│   │   │   ├── internal/
│   │   │   │   ├── common/
│   │   │   │   │   ├── common.go
│   │   │   │   │   ├── common_test.go
│   │   │   │   │   └── suite_test.go
│   │   │   │   ├── generate.go
│   │   │   │   ├── generate_test.go
│   │   │   │   ├── update/
│   │   │   │   │   ├── helpers/
│   │   │   │   │   │   ├── conflict.go
│   │   │   │   │   │   ├── conflict_test.go
│   │   │   │   │   │   ├── download.go
│   │   │   │   │   │   ├── download_test.go
│   │   │   │   │   │   ├── git_commands.go
│   │   │   │   │   │   ├── open_gh_issue.go
│   │   │   │   │   │   ├── open_gh_issue_test.go
│   │   │   │   │   │   └── suite_test.go
│   │   │   │   │   ├── integration_test.go
│   │   │   │   │   ├── prepare.go
│   │   │   │   │   ├── prepare_test.go
│   │   │   │   │   ├── suite_test.go
│   │   │   │   │   ├── update.go
│   │   │   │   │   ├── update_test.go
│   │   │   │   │   ├── validate.go
│   │   │   │   │   └── validate_test.go
│   │   │   │   └── update.go
│   │   │   ├── suite_test.go
│   │   │   ├── update.go
│   │   │   └── update_test.go
│   │   ├── cmd/
│   │   │   └── cmd.go
│   │   └── version/
│   │       ├── version.go
│   │       └── version_test.go
│   └── logging/
│       └── handler.go
├── main.go
├── netlify.toml
├── pkg/
│   ├── cli/
│   │   ├── alpha.go
│   │   ├── api.go
│   │   ├── cli.go
│   │   ├── cli_test.go
│   │   ├── cmd_helpers.go
│   │   ├── cmd_helpers_test.go
│   │   ├── completion.go
│   │   ├── completion_test.go
│   │   ├── create.go
│   │   ├── doc.go
│   │   ├── edit.go
│   │   ├── init.go
│   │   ├── init_test.go
│   │   ├── options.go
│   │   ├── options_test.go
│   │   ├── resource.go
│   │   ├── resource_test.go
│   │   ├── root.go
│   │   ├── suite_test.go
│   │   ├── version.go
│   │   ├── version_test.go
│   │   ├── webhook.go
│   │   └── webhook_test.go
│   ├── config/
│   │   ├── errors.go
│   │   ├── errors_test.go
│   │   ├── interface.go
│   │   ├── registry.go
│   │   ├── registry_test.go
│   │   ├── store/
│   │   │   ├── errors.go
│   │   │   ├── errors_test.go
│   │   │   ├── interface.go
│   │   │   └── yaml/
│   │   │       ├── store.go
│   │   │       └── store_test.go
│   │   ├── suite_test.go
│   │   ├── v3/
│   │   │   ├── config.go
│   │   │   └── config_test.go
│   │   ├── version.go
│   │   └── version_test.go
│   ├── machinery/
│   │   ├── errors.go
│   │   ├── errors_test.go
│   │   ├── file.go
│   │   ├── filesystem.go
│   │   ├── funcmap.go
│   │   ├── funcmap_test.go
│   │   ├── injector.go
│   │   ├── injector_test.go
│   │   ├── interfaces.go
│   │   ├── machinery_suite_test.go
│   │   ├── marker.go
│   │   ├── marker_test.go
│   │   ├── mixins.go
│   │   ├── mixins_delim_test.go
│   │   ├── mixins_test.go
│   │   ├── scaffold.go
│   │   └── scaffold_test.go
│   ├── model/
│   │   ├── resource/
│   │   │   ├── api.go
│   │   │   ├── api_test.go
│   │   │   ├── gvk.go
│   │   │   ├── gvk_test.go
│   │   │   ├── resource.go
│   │   │   ├── resource_test.go
│   │   │   ├── suite_test.go
│   │   │   ├── utils.go
│   │   │   ├── utils_test.go
│   │   │   ├── webhooks.go
│   │   │   ├── webhooks_copy_test.go
│   │   │   └── webhooks_test.go
│   │   └── stage/
│   │       ├── stage.go
│   │       └── stage_test.go
│   ├── plugin/
│   │   ├── bundle.go
│   │   ├── bundle_test.go
│   │   ├── errors.go
│   │   ├── errors_test.go
│   │   ├── external/
│   │   │   └── types.go
│   │   ├── filter.go
│   │   ├── filter_test.go
│   │   ├── helpers.go
│   │   ├── helpers_test.go
│   │   ├── metadata.go
│   │   ├── plugin.go
│   │   ├── subcommand.go
│   │   ├── suite_test.go
│   │   ├── util/
│   │   │   ├── exec.go
│   │   │   ├── exec_test.go
│   │   │   ├── stdin.go
│   │   │   ├── stdin_test.go
│   │   │   ├── suite_test.go
│   │   │   ├── util.go
│   │   │   └── util_test.go
│   │   ├── version.go
│   │   └── version_test.go
│   └── plugins/
│       ├── common/
│       │   └── kustomize/
│       │       └── v2/
│       │           ├── api.go
│       │           ├── create.go
│       │           ├── create_test.go
│       │           ├── init.go
│       │           ├── init_test.go
│       │           ├── plugin.go
│       │           ├── plugin_test.go
│       │           ├── scaffolds/
│       │           │   ├── api.go
│       │           │   ├── edit.go
│       │           │   ├── init.go
│       │           │   ├── internal/
│       │           │   │   └── templates/
│       │           │   │       └── config/
│       │           │   │           ├── certmanager/
│       │           │   │           │   ├── certificate_metrics.go
│       │           │   │           │   ├── certificate_webhook.go
│       │           │   │           │   ├── issuer.go
│       │           │   │           │   ├── kustomization.go
│       │           │   │           │   └── kustomizeconfig.go
│       │           │   │           ├── crd/
│       │           │   │           │   ├── kustomization.go
│       │           │   │           │   ├── kustomizeconfig.go
│       │           │   │           │   └── patches/
│       │           │   │           │       ├── enablecainjection_patch.go
│       │           │   │           │       └── enablewebhook_patch.go
│       │           │   │           ├── kdefault/
│       │           │   │           │   ├── cert_metrics_manager_patch.go
│       │           │   │           │   ├── kustomization.go
│       │           │   │           │   ├── kustomization_conversion_updater.go
│       │           │   │           │   ├── manager_metrics_patch.go
│       │           │   │           │   ├── metrics_service.go
│       │           │   │           │   └── webhook_manager_patch.go
│       │           │   │           ├── manager/
│       │           │   │           │   ├── config.go
│       │           │   │           │   └── kustomization.go
│       │           │   │           ├── network-policy/
│       │           │   │           │   ├── allow-metrics-traffic.go
│       │           │   │           │   ├── allow-webhook-traffic.go
│       │           │   │           │   └── kustomization.go
│       │           │   │           ├── prometheus/
│       │           │   │           │   ├── kustomization.go
│       │           │   │           │   ├── monitor.go
│       │           │   │           │   └── monitor_tls_patch.go
│       │           │   │           ├── rbac/
│       │           │   │           │   ├── cluster_role.go
│       │           │   │           │   ├── cluster_role_binding.go
│       │           │   │           │   ├── crd_admin_role.go
│       │           │   │           │   ├── crd_editor_role.go
│       │           │   │           │   ├── crd_viewer_role.go
│       │           │   │           │   ├── kustomization.go
│       │           │   │           │   ├── leader_election_role.go
│       │           │   │           │   ├── leader_election_role_binding.go
│       │           │   │           │   ├── metrics_auth_role.go
│       │           │   │           │   ├── metrics_auth_role_binding.go
│       │           │   │           │   ├── metrics_reader_role.go
│       │           │   │           │   ├── namespaced_role.go
│       │           │   │           │   ├── namespaced_role_binding.go
│       │           │   │           │   └── service_account.go
│       │           │   │           ├── samples/
│       │           │   │           │   ├── crd_sample.go
│       │           │   │           │   └── kustomization.go
│       │           │   │           └── webhook/
│       │           │   │               ├── kustomization.go
│       │           │   │               └── service.go
│       │           │   └── webhook.go
│       │           ├── suite_test.go
│       │           └── webhook.go
│       ├── domain.go
│       ├── external/
│       │   ├── api.go
│       │   ├── edit.go
│       │   ├── external_test.go
│       │   ├── helpers.go
│       │   ├── helpers_test.go
│       │   ├── init.go
│       │   ├── plugin.go
│       │   └── webhook.go
│       ├── golang/
│       │   ├── deploy-image/
│       │   │   └── v1alpha1/
│       │   │       ├── api.go
│       │   │       ├── api_test.go
│       │   │       ├── plugin.go
│       │   │       ├── plugin_test.go
│       │   │       ├── scaffolds/
│       │   │       │   ├── api.go
│       │   │       │   └── internal/
│       │   │       │       └── templates/
│       │   │       │           ├── api/
│       │   │       │           │   └── types.go
│       │   │       │           ├── config/
│       │   │       │           │   └── samples/
│       │   │       │           │       └── crd_sample.go
│       │   │       │           └── controllers/
│       │   │       │               ├── controller-test.go
│       │   │       │               └── controller.go
│       │   │       └── suite_test.go
│       │   ├── domain.go
│       │   ├── go_version.go
│       │   ├── go_version_test.go
│       │   ├── options.go
│       │   ├── options_test.go
│       │   ├── repository.go
│       │   ├── repository_test.go
│       │   ├── suite_test.go
│       │   └── v4/
│       │       ├── api.go
│       │       ├── api_test.go
│       │       ├── edit.go
│       │       ├── edit_test.go
│       │       ├── init.go
│       │       ├── init_test.go
│       │       ├── plugin.go
│       │       ├── plugin_test.go
│       │       ├── scaffolds/
│       │       │   ├── api.go
│       │       │   ├── doc.go
│       │       │   ├── edit.go
│       │       │   ├── edit_integration_test.go
│       │       │   ├── init.go
│       │       │   ├── init_integration_test.go
│       │       │   ├── internal/
│       │       │   │   └── templates/
│       │       │   │       ├── agents.go
│       │       │   │       ├── api/
│       │       │   │       │   ├── group.go
│       │       │   │       │   ├── hub.go
│       │       │   │       │   ├── spoke.go
│       │       │   │       │   ├── types.go
│       │       │   │       │   └── types_updater.go
│       │       │   │       ├── cmd/
│       │       │   │       │   └── main.go
│       │       │   │       ├── controllers/
│       │       │   │       │   ├── controller.go
│       │       │   │       │   ├── controller_suitetest.go
│       │       │   │       │   └── controller_test_template.go
│       │       │   │       ├── customgcl.go
│       │       │   │       ├── devcontainer.go
│       │       │   │       ├── dockerfile.go
│       │       │   │       ├── dockerignore.go
│       │       │   │       ├── github/
│       │       │   │       │   ├── lint.go
│       │       │   │       │   ├── test-e2e.go
│       │       │   │       │   └── test.go
│       │       │   │       ├── gitignore.go
│       │       │   │       ├── golangci.go
│       │       │   │       ├── gomod.go
│       │       │   │       ├── hack/
│       │       │   │       │   └── boilerplate.go
│       │       │   │       ├── makefile.go
│       │       │   │       ├── readme.go
│       │       │   │       ├── test/
│       │       │   │       │   ├── e2e/
│       │       │   │       │   │   ├── suite.go
│       │       │   │       │   │   └── test.go
│       │       │   │       │   └── utils/
│       │       │   │       │       └── utils.go
│       │       │   │       └── webhooks/
│       │       │   │           ├── webhook.go
│       │       │   │           ├── webhook_suitetest.go
│       │       │   │           ├── webhook_test_template.go
│       │       │   │           ├── webhook_test_updater.go
│       │       │   │           └── webhook_updater.go
│       │       │   ├── suite_test.go
│       │       │   ├── webhook.go
│       │       │   └── webhook_test.go
│       │       ├── suite_test.go
│       │       ├── webhook.go
│       │       └── webhook_test.go
│       ├── optional/
│       │   ├── autoupdate/
│       │   │   └── v1alpha/
│       │   │       ├── edit.go
│       │   │       ├── edit_test.go
│       │   │       ├── init.go
│       │   │       ├── plugin.go
│       │   │       ├── plugin_test.go
│       │   │       ├── scaffolds/
│       │   │       │   ├── init.go
│       │   │       │   └── internal/
│       │   │       │       └── github/
│       │   │       │           └── auto_update.go
│       │   │       └── suite_test.go
│       │   ├── grafana/
│       │   │   └── v1alpha/
│       │   │       ├── commons.go
│       │   │       ├── constants.go
│       │   │       ├── edit.go
│       │   │       ├── init.go
│       │   │       ├── plugin.go
│       │   │       └── scaffolds/
│       │   │           ├── edit.go
│       │   │           ├── edit_test.go
│       │   │           ├── init.go
│       │   │           ├── init_test.go
│       │   │           ├── internal/
│       │   │           │   └── templates/
│       │   │           │       ├── custom.go
│       │   │           │       ├── custom_metrics.go
│       │   │           │       ├── resources.go
│       │   │           │       └── runtime.go
│       │   │           ├── scaffolds_test.go
│       │   │           └── suite_test.go
│       │   └── helm/
│       │       ├── v1alpha/
│       │       │   ├── commons.go
│       │       │   ├── edit.go
│       │       │   ├── plugin.go
│       │       │   └── scaffolds/
│       │       │       ├── edit.go
│       │       │       └── internal/
│       │       │           └── templates/
│       │       │               ├── chart-templates/
│       │       │               │   ├── cert-manager/
│       │       │               │   │   └── certificate.go
│       │       │               │   ├── helpers_tpl.go
│       │       │               │   ├── manager/
│       │       │               │   │   └── manager.go
│       │       │               │   ├── metrics/
│       │       │               │   │   └── metrics_service.go
│       │       │               │   ├── prometheus/
│       │       │               │   │   └── monitor.go
│       │       │               │   └── webhook/
│       │       │               │       ├── service.go
│       │       │               │       └── webhook.go
│       │       │               ├── chart.go
│       │       │               ├── github/
│       │       │               │   └── test_chart.go
│       │       │               ├── helmignore.go
│       │       │               └── values.go
│       │       └── v2alpha/
│       │           ├── edit.go
│       │           ├── edit_test.go
│       │           ├── makefile_test.go
│       │           ├── plugin.go
│       │           ├── plugin_test.go
│       │           ├── scaffolds/
│       │           │   ├── chart_generation_integration_test.go
│       │           │   ├── chart_never_overwrite_test.go
│       │           │   ├── edit_kustomize.go
│       │           │   ├── extras_integration_test.go
│       │           │   ├── force_integration_test.go
│       │           │   ├── internal/
│       │           │   │   ├── kustomize/
│       │           │   │   │   ├── chart_converter.go
│       │           │   │   │   ├── chart_converter_test.go
│       │           │   │   │   ├── chart_writer.go
│       │           │   │   │   ├── helm_templater.go
│       │           │   │   │   ├── helm_templater_test.go
│       │           │   │   │   ├── parser.go
│       │           │   │   │   ├── parser_test.go
│       │           │   │   │   ├── resource_organizer.go
│       │           │   │   │   └── suite_test.go
│       │           │   │   └── templates/
│       │           │   │       ├── chart-templates/
│       │           │   │       │   ├── consts.go
│       │           │   │       │   ├── helpers_tpl.go
│       │           │   │       │   ├── notes.go
│       │           │   │       │   ├── notes_test.go
│       │           │   │       │   ├── servicemonitor.go
│       │           │   │       │   └── suite_test.go
│       │           │   │       ├── chart.go
│       │           │   │       ├── github/
│       │           │   │       │   └── test_chart.go
│       │           │   │       ├── helmignore.go
│       │           │   │       ├── suite_test.go
│       │           │   │       ├── values_basic.go
│       │           │   │       └── values_basic_test.go
│       │           │   └── suite_test.go
│       │           └── suite_test.go
│       └── scaffolder.go
├── roadmap/
│   ├── README.md
│   ├── roadmap_2024.md
│   ├── roadmap_2025.md
│   └── roadmap_2026.md
├── test/
│   ├── check-docs-only.sh
│   ├── check-license.sh
│   ├── check_spaces.sh
│   ├── common.sh
│   ├── e2e/
│   │   ├── all/
│   │   │   ├── e2e_suite_test.go
│   │   │   ├── plugin_deployimage_test.go
│   │   │   ├── plugin_helm_test.go
│   │   │   └── plugin_v4_test.go
│   │   ├── ci.sh
│   │   ├── internal/
│   │   │   └── helpers/
│   │   │       ├── generate_v4.go
│   │   │       ├── plugin_test_helper.go
│   │   │       └── plugin_test_metrics.go
│   │   ├── kind-config.yaml
│   │   ├── local.sh
│   │   ├── setup.sh
│   │   └── utils/
│   │       ├── kubectl.go
│   │       ├── kubectl_test.go
│   │       ├── suite_test.go
│   │       ├── test_context.go
│   │       └── webhooks.go
│   └── testdata/
│       ├── check.sh
│       ├── generate.sh
│       ├── legacy-webhook-path.sh
│       ├── test.sh
│       └── test_legacy.sh
├── test.sh
├── test_e2e.sh
└── testdata/
    ├── project-v4/
    │   ├── .custom-gcl.yml
    │   ├── .devcontainer/
    │   │   ├── devcontainer.json
    │   │   └── post-install.sh
    │   ├── .dockerignore
    │   ├── .github/
    │   │   └── workflows/
    │   │       ├── lint.yml
    │   │       ├── test-e2e.yml
    │   │       └── test.yml
    │   ├── .gitignore
    │   ├── .golangci.yml
    │   ├── AGENTS.md
    │   ├── Dockerfile
    │   ├── Makefile
    │   ├── PROJECT
    │   ├── README.md
    │   ├── api/
    │   │   ├── v1/
    │   │   │   ├── admiral_types.go
    │   │   │   ├── captain_types.go
    │   │   │   ├── firstmate_conversion.go
    │   │   │   ├── firstmate_types.go
    │   │   │   ├── groupversion_info.go
    │   │   │   ├── sailor_types.go
    │   │   │   └── zz_generated.deepcopy.go
    │   │   └── v2/
    │   │       ├── firstmate_conversion.go
    │   │       ├── firstmate_types.go
    │   │       ├── groupversion_info.go
    │   │       └── zz_generated.deepcopy.go
    │   ├── cmd/
    │   │   └── main.go
    │   ├── config/
    │   │   ├── certmanager/
    │   │   │   ├── certificate-metrics.yaml
    │   │   │   ├── certificate-webhook.yaml
    │   │   │   ├── issuer.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   └── kustomizeconfig.yaml
    │   │   ├── crd/
    │   │   │   ├── bases/
    │   │   │   │   ├── crew.testproject.org_admirales.yaml
    │   │   │   │   ├── crew.testproject.org_captains.yaml
    │   │   │   │   ├── crew.testproject.org_firstmates.yaml
    │   │   │   │   └── crew.testproject.org_sailors.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── kustomizeconfig.yaml
    │   │   │   └── patches/
    │   │   │       └── webhook_in_firstmates.yaml
    │   │   ├── default/
    │   │   │   ├── cert_metrics_manager_patch.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── manager_metrics_patch.yaml
    │   │   │   ├── manager_webhook_patch.yaml
    │   │   │   └── metrics_service.yaml
    │   │   ├── manager/
    │   │   │   ├── kustomization.yaml
    │   │   │   └── manager.yaml
    │   │   ├── network-policy/
    │   │   │   ├── allow-metrics-traffic.yaml
    │   │   │   ├── allow-webhook-traffic.yaml
    │   │   │   └── kustomization.yaml
    │   │   ├── prometheus/
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── monitor.yaml
    │   │   │   └── monitor_tls_patch.yaml
    │   │   ├── rbac/
    │   │   │   ├── admiral_admin_role.yaml
    │   │   │   ├── admiral_editor_role.yaml
    │   │   │   ├── admiral_viewer_role.yaml
    │   │   │   ├── captain_admin_role.yaml
    │   │   │   ├── captain_editor_role.yaml
    │   │   │   ├── captain_viewer_role.yaml
    │   │   │   ├── firstmate_admin_role.yaml
    │   │   │   ├── firstmate_editor_role.yaml
    │   │   │   ├── firstmate_viewer_role.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── leader_election_role.yaml
    │   │   │   ├── leader_election_role_binding.yaml
    │   │   │   ├── metrics_auth_role.yaml
    │   │   │   ├── metrics_auth_role_binding.yaml
    │   │   │   ├── metrics_reader_role.yaml
    │   │   │   ├── role.yaml
    │   │   │   ├── role_binding.yaml
    │   │   │   ├── sailor_admin_role.yaml
    │   │   │   ├── sailor_editor_role.yaml
    │   │   │   ├── sailor_viewer_role.yaml
    │   │   │   └── service_account.yaml
    │   │   ├── samples/
    │   │   │   ├── crew_v1_admiral.yaml
    │   │   │   ├── crew_v1_captain.yaml
    │   │   │   ├── crew_v1_firstmate.yaml
    │   │   │   ├── crew_v1_sailor.yaml
    │   │   │   ├── crew_v2_firstmate.yaml
    │   │   │   └── kustomization.yaml
    │   │   └── webhook/
    │   │       ├── kustomization.yaml
    │   │       ├── manifests.yaml
    │   │       └── service.yaml
    │   ├── dist/
    │   │   └── install.yaml
    │   ├── go.mod
    │   ├── hack/
    │   │   └── boilerplate.go.txt
    │   ├── internal/
    │   │   ├── controller/
    │   │   │   ├── admiral_controller.go
    │   │   │   ├── admiral_controller_test.go
    │   │   │   ├── captain_controller.go
    │   │   │   ├── captain_controller_test.go
    │   │   │   ├── certificate_controller.go
    │   │   │   ├── certificate_controller_test.go
    │   │   │   ├── firstmate_controller.go
    │   │   │   ├── firstmate_controller_test.go
    │   │   │   ├── sailor_controller.go
    │   │   │   ├── sailor_controller_test.go
    │   │   │   └── suite_test.go
    │   │   └── webhook/
    │   │       └── v1/
    │   │           ├── admiral_webhook.go
    │   │           ├── admiral_webhook_test.go
    │   │           ├── captain_webhook.go
    │   │           ├── captain_webhook_test.go
    │   │           ├── deployment_webhook.go
    │   │           ├── deployment_webhook_test.go
    │   │           ├── firstmate_webhook.go
    │   │           ├── firstmate_webhook_test.go
    │   │           ├── issuer_webhook.go
    │   │           ├── issuer_webhook_test.go
    │   │           ├── pod_webhook.go
    │   │           ├── pod_webhook_test.go
    │   │           ├── sailor_webhook.go
    │   │           ├── sailor_webhook_test.go
    │   │           └── webhook_suite_test.go
    │   └── test/
    │       ├── e2e/
    │       │   ├── e2e_suite_test.go
    │       │   └── e2e_test.go
    │       └── utils/
    │           └── utils.go
    ├── project-v4-multigroup/
    │   ├── .custom-gcl.yml
    │   ├── .devcontainer/
    │   │   ├── devcontainer.json
    │   │   └── post-install.sh
    │   ├── .dockerignore
    │   ├── .github/
    │   │   └── workflows/
    │   │       ├── lint.yml
    │   │       ├── test-e2e.yml
    │   │       └── test.yml
    │   ├── .gitignore
    │   ├── .golangci.yml
    │   ├── AGENTS.md
    │   ├── Dockerfile
    │   ├── Makefile
    │   ├── PROJECT
    │   ├── README.md
    │   ├── api/
    │   │   ├── crew/
    │   │   │   └── v1/
    │   │   │       ├── captain_types.go
    │   │   │       ├── groupversion_info.go
    │   │   │       └── zz_generated.deepcopy.go
    │   │   ├── example.com/
    │   │   │   ├── v1/
    │   │   │   │   ├── groupversion_info.go
    │   │   │   │   ├── wordpress_conversion.go
    │   │   │   │   ├── wordpress_types.go
    │   │   │   │   └── zz_generated.deepcopy.go
    │   │   │   ├── v1alpha1/
    │   │   │   │   ├── busybox_types.go
    │   │   │   │   ├── groupversion_info.go
    │   │   │   │   ├── memcached_types.go
    │   │   │   │   └── zz_generated.deepcopy.go
    │   │   │   └── v2/
    │   │   │       ├── groupversion_info.go
    │   │   │       ├── wordpress_conversion.go
    │   │   │       ├── wordpress_types.go
    │   │   │       └── zz_generated.deepcopy.go
    │   │   ├── fiz/
    │   │   │   └── v1/
    │   │   │       ├── bar_types.go
    │   │   │       ├── groupversion_info.go
    │   │   │       └── zz_generated.deepcopy.go
    │   │   ├── foo/
    │   │   │   └── v1/
    │   │   │       ├── bar_types.go
    │   │   │       ├── groupversion_info.go
    │   │   │       └── zz_generated.deepcopy.go
    │   │   ├── foo.policy/
    │   │   │   └── v1/
    │   │   │       ├── groupversion_info.go
    │   │   │       ├── healthcheckpolicy_types.go
    │   │   │       └── zz_generated.deepcopy.go
    │   │   ├── sea-creatures/
    │   │   │   ├── v1beta1/
    │   │   │   │   ├── groupversion_info.go
    │   │   │   │   ├── kraken_types.go
    │   │   │   │   └── zz_generated.deepcopy.go
    │   │   │   └── v1beta2/
    │   │   │       ├── groupversion_info.go
    │   │   │       ├── leviathan_types.go
    │   │   │       └── zz_generated.deepcopy.go
    │   │   └── ship/
    │   │       ├── v1/
    │   │       │   ├── destroyer_types.go
    │   │       │   ├── groupversion_info.go
    │   │       │   └── zz_generated.deepcopy.go
    │   │       ├── v1beta1/
    │   │       │   ├── frigate_types.go
    │   │       │   ├── groupversion_info.go
    │   │       │   └── zz_generated.deepcopy.go
    │   │       └── v2alpha1/
    │   │           ├── cruiser_types.go
    │   │           ├── groupversion_info.go
    │   │           └── zz_generated.deepcopy.go
    │   ├── cmd/
    │   │   └── main.go
    │   ├── config/
    │   │   ├── certmanager/
    │   │   │   ├── certificate-metrics.yaml
    │   │   │   ├── certificate-webhook.yaml
    │   │   │   ├── issuer.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   └── kustomizeconfig.yaml
    │   │   ├── crd/
    │   │   │   ├── bases/
    │   │   │   │   ├── crew.testproject.org_captains.yaml
    │   │   │   │   ├── example.com.testproject.org_busyboxes.yaml
    │   │   │   │   ├── example.com.testproject.org_memcacheds.yaml
    │   │   │   │   ├── example.com.testproject.org_wordpresses.yaml
    │   │   │   │   ├── fiz.testproject.org_bars.yaml
    │   │   │   │   ├── foo.policy.testproject.org_healthcheckpolicies.yaml
    │   │   │   │   ├── foo.testproject.org_bars.yaml
    │   │   │   │   ├── sea-creatures.testproject.org_krakens.yaml
    │   │   │   │   ├── sea-creatures.testproject.org_leviathans.yaml
    │   │   │   │   ├── ship.testproject.org_cruisers.yaml
    │   │   │   │   ├── ship.testproject.org_destroyers.yaml
    │   │   │   │   └── ship.testproject.org_frigates.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── kustomizeconfig.yaml
    │   │   │   └── patches/
    │   │   │       └── webhook_in_example.com_wordpresses.yaml
    │   │   ├── default/
    │   │   │   ├── cert_metrics_manager_patch.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── manager_metrics_patch.yaml
    │   │   │   ├── manager_webhook_patch.yaml
    │   │   │   └── metrics_service.yaml
    │   │   ├── manager/
    │   │   │   ├── kustomization.yaml
    │   │   │   └── manager.yaml
    │   │   ├── network-policy/
    │   │   │   ├── allow-metrics-traffic.yaml
    │   │   │   ├── allow-webhook-traffic.yaml
    │   │   │   └── kustomization.yaml
    │   │   ├── prometheus/
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── monitor.yaml
    │   │   │   └── monitor_tls_patch.yaml
    │   │   ├── rbac/
    │   │   │   ├── crew_captain_admin_role.yaml
    │   │   │   ├── crew_captain_editor_role.yaml
    │   │   │   ├── crew_captain_viewer_role.yaml
    │   │   │   ├── example.com_busybox_admin_role.yaml
    │   │   │   ├── example.com_busybox_editor_role.yaml
    │   │   │   ├── example.com_busybox_viewer_role.yaml
    │   │   │   ├── example.com_memcached_admin_role.yaml
    │   │   │   ├── example.com_memcached_editor_role.yaml
    │   │   │   ├── example.com_memcached_viewer_role.yaml
    │   │   │   ├── example.com_wordpress_admin_role.yaml
    │   │   │   ├── example.com_wordpress_editor_role.yaml
    │   │   │   ├── example.com_wordpress_viewer_role.yaml
    │   │   │   ├── fiz_bar_admin_role.yaml
    │   │   │   ├── fiz_bar_editor_role.yaml
    │   │   │   ├── fiz_bar_viewer_role.yaml
    │   │   │   ├── foo.policy_healthcheckpolicy_admin_role.yaml
    │   │   │   ├── foo.policy_healthcheckpolicy_editor_role.yaml
    │   │   │   ├── foo.policy_healthcheckpolicy_viewer_role.yaml
    │   │   │   ├── foo_bar_admin_role.yaml
    │   │   │   ├── foo_bar_editor_role.yaml
    │   │   │   ├── foo_bar_viewer_role.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── leader_election_role.yaml
    │   │   │   ├── leader_election_role_binding.yaml
    │   │   │   ├── metrics_auth_role.yaml
    │   │   │   ├── metrics_auth_role_binding.yaml
    │   │   │   ├── metrics_reader_role.yaml
    │   │   │   ├── role.yaml
    │   │   │   ├── role_binding.yaml
    │   │   │   ├── sea-creatures_kraken_admin_role.yaml
    │   │   │   ├── sea-creatures_kraken_editor_role.yaml
    │   │   │   ├── sea-creatures_kraken_viewer_role.yaml
    │   │   │   ├── sea-creatures_leviathan_admin_role.yaml
    │   │   │   ├── sea-creatures_leviathan_editor_role.yaml
    │   │   │   ├── sea-creatures_leviathan_viewer_role.yaml
    │   │   │   ├── service_account.yaml
    │   │   │   ├── ship_cruiser_admin_role.yaml
    │   │   │   ├── ship_cruiser_editor_role.yaml
    │   │   │   ├── ship_cruiser_viewer_role.yaml
    │   │   │   ├── ship_destroyer_admin_role.yaml
    │   │   │   ├── ship_destroyer_editor_role.yaml
    │   │   │   ├── ship_destroyer_viewer_role.yaml
    │   │   │   ├── ship_frigate_admin_role.yaml
    │   │   │   ├── ship_frigate_editor_role.yaml
    │   │   │   └── ship_frigate_viewer_role.yaml
    │   │   ├── samples/
    │   │   │   ├── crew_v1_captain.yaml
    │   │   │   ├── example.com_v1_wordpress.yaml
    │   │   │   ├── example.com_v1alpha1_busybox.yaml
    │   │   │   ├── example.com_v1alpha1_memcached.yaml
    │   │   │   ├── example.com_v2_wordpress.yaml
    │   │   │   ├── fiz_v1_bar.yaml
    │   │   │   ├── foo.policy_v1_healthcheckpolicy.yaml
    │   │   │   ├── foo_v1_bar.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── sea-creatures_v1beta1_kraken.yaml
    │   │   │   ├── sea-creatures_v1beta2_leviathan.yaml
    │   │   │   ├── ship_v1_destroyer.yaml
    │   │   │   ├── ship_v1beta1_frigate.yaml
    │   │   │   └── ship_v2alpha1_cruiser.yaml
    │   │   └── webhook/
    │   │       ├── kustomization.yaml
    │   │       ├── manifests.yaml
    │   │       └── service.yaml
    │   ├── dist/
    │   │   └── install.yaml
    │   ├── go.mod
    │   ├── grafana/
    │   │   ├── controller-resources-metrics.json
    │   │   ├── controller-runtime-metrics.json
    │   │   └── custom-metrics/
    │   │       └── config.yaml
    │   ├── hack/
    │   │   └── boilerplate.go.txt
    │   ├── internal/
    │   │   ├── controller/
    │   │   │   ├── apps/
    │   │   │   │   ├── deployment_controller.go
    │   │   │   │   ├── deployment_controller_test.go
    │   │   │   │   └── suite_test.go
    │   │   │   ├── cert-manager/
    │   │   │   │   ├── certificate_controller.go
    │   │   │   │   ├── certificate_controller_test.go
    │   │   │   │   └── suite_test.go
    │   │   │   ├── crew/
    │   │   │   │   ├── captain_controller.go
    │   │   │   │   ├── captain_controller_test.go
    │   │   │   │   └── suite_test.go
    │   │   │   ├── example.com/
    │   │   │   │   ├── busybox_controller.go
    │   │   │   │   ├── busybox_controller_test.go
    │   │   │   │   ├── memcached_controller.go
    │   │   │   │   ├── memcached_controller_test.go
    │   │   │   │   ├── suite_test.go
    │   │   │   │   ├── wordpress_controller.go
    │   │   │   │   └── wordpress_controller_test.go
    │   │   │   ├── fiz/
    │   │   │   │   ├── bar_controller.go
    │   │   │   │   ├── bar_controller_test.go
    │   │   │   │   └── suite_test.go
    │   │   │   ├── foo/
    │   │   │   │   ├── bar_controller.go
    │   │   │   │   ├── bar_controller_test.go
    │   │   │   │   └── suite_test.go
    │   │   │   ├── foo.policy/
    │   │   │   │   ├── healthcheckpolicy_controller.go
    │   │   │   │   ├── healthcheckpolicy_controller_test.go
    │   │   │   │   └── suite_test.go
    │   │   │   ├── sea-creatures/
    │   │   │   │   ├── kraken_controller.go
    │   │   │   │   ├── kraken_controller_test.go
    │   │   │   │   ├── leviathan_controller.go
    │   │   │   │   ├── leviathan_controller_test.go
    │   │   │   │   └── suite_test.go
    │   │   │   └── ship/
    │   │   │       ├── cruiser_controller.go
    │   │   │       ├── cruiser_controller_test.go
    │   │   │       ├── destroyer_controller.go
    │   │   │       ├── destroyer_controller_test.go
    │   │   │       ├── frigate_controller.go
    │   │   │       ├── frigate_controller_test.go
    │   │   │       └── suite_test.go
    │   │   └── webhook/
    │   │       ├── apps/
    │   │       │   └── v1/
    │   │       │       ├── deployment_webhook.go
    │   │       │       ├── deployment_webhook_test.go
    │   │       │       └── webhook_suite_test.go
    │   │       ├── cert-manager/
    │   │       │   └── v1/
    │   │       │       ├── issuer_webhook.go
    │   │       │       ├── issuer_webhook_test.go
    │   │       │       └── webhook_suite_test.go
    │   │       ├── core/
    │   │       │   └── v1/
    │   │       │       ├── pod_webhook.go
    │   │       │       ├── pod_webhook_test.go
    │   │       │       └── webhook_suite_test.go
    │   │       ├── crew/
    │   │       │   └── v1/
    │   │       │       ├── captain_webhook.go
    │   │       │       ├── captain_webhook_test.go
    │   │       │       └── webhook_suite_test.go
    │   │       ├── example.com/
    │   │       │   ├── v1/
    │   │       │   │   ├── webhook_suite_test.go
    │   │       │   │   ├── wordpress_webhook.go
    │   │       │   │   └── wordpress_webhook_test.go
    │   │       │   └── v1alpha1/
    │   │       │       ├── memcached_webhook.go
    │   │       │       ├── memcached_webhook_test.go
    │   │       │       └── webhook_suite_test.go
    │   │       └── ship/
    │   │           ├── v1/
    │   │           │   ├── destroyer_webhook.go
    │   │           │   ├── destroyer_webhook_test.go
    │   │           │   └── webhook_suite_test.go
    │   │           └── v2alpha1/
    │   │               ├── cruiser_webhook.go
    │   │               ├── cruiser_webhook_test.go
    │   │               └── webhook_suite_test.go
    │   └── test/
    │       ├── e2e/
    │       │   ├── e2e_suite_test.go
    │       │   └── e2e_test.go
    │       └── utils/
    │           └── utils.go
    └── project-v4-with-plugins/
        ├── .custom-gcl.yml
        ├── .devcontainer/
        │   ├── devcontainer.json
        │   └── post-install.sh
        ├── .dockerignore
        ├── .github/
        │   └── workflows/
        │       ├── auto_update.yml
        │       ├── lint.yml
        │       ├── test-chart.yml
        │       ├── test-e2e.yml
        │       └── test.yml
        ├── .gitignore
        ├── .golangci.yml
        ├── AGENTS.md
        ├── Dockerfile
        ├── Makefile
        ├── PROJECT
        ├── README.md
        ├── api/
        │   ├── v1/
        │   │   ├── groupversion_info.go
        │   │   ├── wordpress_conversion.go
        │   │   ├── wordpress_types.go
        │   │   └── zz_generated.deepcopy.go
        │   ├── v1alpha1/
        │   │   ├── busybox_types.go
        │   │   ├── groupversion_info.go
        │   │   ├── memcached_types.go
        │   │   └── zz_generated.deepcopy.go
        │   └── v2/
        │       ├── groupversion_info.go
        │       ├── wordpress_conversion.go
        │       ├── wordpress_types.go
        │       └── zz_generated.deepcopy.go
        ├── cmd/
        │   └── main.go
        ├── config/
        │   ├── certmanager/
        │   │   ├── certificate-metrics.yaml
        │   │   ├── certificate-webhook.yaml
        │   │   ├── issuer.yaml
        │   │   ├── kustomization.yaml
        │   │   └── kustomizeconfig.yaml
        │   ├── crd/
        │   │   ├── bases/
        │   │   │   ├── example.com.testproject.org_busyboxes.yaml
        │   │   │   ├── example.com.testproject.org_memcacheds.yaml
        │   │   │   └── example.com.testproject.org_wordpresses.yaml
        │   │   ├── kustomization.yaml
        │   │   ├── kustomizeconfig.yaml
        │   │   └── patches/
        │   │       └── webhook_in_wordpresses.yaml
        │   ├── default/
        │   │   ├── cert_metrics_manager_patch.yaml
        │   │   ├── kustomization.yaml
        │   │   ├── manager_metrics_patch.yaml
        │   │   ├── manager_webhook_patch.yaml
        │   │   └── metrics_service.yaml
        │   ├── manager/
        │   │   ├── kustomization.yaml
        │   │   └── manager.yaml
        │   ├── network-policy/
        │   │   ├── allow-metrics-traffic.yaml
        │   │   ├── allow-webhook-traffic.yaml
        │   │   └── kustomization.yaml
        │   ├── prometheus/
        │   │   ├── kustomization.yaml
        │   │   ├── monitor.yaml
        │   │   └── monitor_tls_patch.yaml
        │   ├── rbac/
        │   │   ├── busybox_admin_role.yaml
        │   │   ├── busybox_editor_role.yaml
        │   │   ├── busybox_viewer_role.yaml
        │   │   ├── kustomization.yaml
        │   │   ├── leader_election_role.yaml
        │   │   ├── leader_election_role_binding.yaml
        │   │   ├── memcached_admin_role.yaml
        │   │   ├── memcached_editor_role.yaml
        │   │   ├── memcached_viewer_role.yaml
        │   │   ├── metrics_auth_role.yaml
        │   │   ├── metrics_auth_role_binding.yaml
        │   │   ├── metrics_reader_role.yaml
        │   │   ├── role.yaml
        │   │   ├── role_binding.yaml
        │   │   ├── service_account.yaml
        │   │   ├── wordpress_admin_role.yaml
        │   │   ├── wordpress_editor_role.yaml
        │   │   └── wordpress_viewer_role.yaml
        │   ├── samples/
        │   │   ├── example.com_v1_wordpress.yaml
        │   │   ├── example.com_v1alpha1_busybox.yaml
        │   │   ├── example.com_v1alpha1_memcached.yaml
        │   │   ├── example.com_v2_wordpress.yaml
        │   │   └── kustomization.yaml
        │   └── webhook/
        │       ├── kustomization.yaml
        │       ├── manifests.yaml
        │       └── service.yaml
        ├── dist/
        │   ├── chart/
        │   │   ├── .helmignore
        │   │   ├── Chart.yaml
        │   │   ├── templates/
        │   │   │   ├── NOTES.txt
        │   │   │   ├── _helpers.tpl
        │   │   │   ├── cert-manager/
        │   │   │   │   ├── metrics-certs.yaml
        │   │   │   │   ├── selfsigned-issuer.yaml
        │   │   │   │   └── serving-cert.yaml
        │   │   │   ├── crd/
        │   │   │   │   ├── busyboxes.example.com.testproject.org.yaml
        │   │   │   │   ├── memcacheds.example.com.testproject.org.yaml
        │   │   │   │   └── wordpresses.example.com.testproject.org.yaml
        │   │   │   ├── manager/
        │   │   │   │   └── manager.yaml
        │   │   │   ├── metrics/
        │   │   │   │   └── controller-manager-metrics-service.yaml
        │   │   │   ├── monitoring/
        │   │   │   │   └── servicemonitor.yaml
        │   │   │   ├── rbac/
        │   │   │   │   ├── busybox-admin-role.yaml
        │   │   │   │   ├── busybox-editor-role.yaml
        │   │   │   │   ├── busybox-viewer-role.yaml
        │   │   │   │   ├── controller-manager.yaml
        │   │   │   │   ├── leader-election-role.yaml
        │   │   │   │   ├── leader-election-rolebinding.yaml
        │   │   │   │   ├── manager-role.yaml
        │   │   │   │   ├── manager-rolebinding.yaml
        │   │   │   │   ├── memcached-admin-role.yaml
        │   │   │   │   ├── memcached-editor-role.yaml
        │   │   │   │   ├── memcached-viewer-role.yaml
        │   │   │   │   ├── metrics-auth-role.yaml
        │   │   │   │   ├── metrics-auth-rolebinding.yaml
        │   │   │   │   ├── metrics-reader.yaml
        │   │   │   │   ├── wordpress-admin-role.yaml
        │   │   │   │   ├── wordpress-editor-role.yaml
        │   │   │   │   └── wordpress-viewer-role.yaml
        │   │   │   └── webhook/
        │   │   │       ├── validating-webhook-configuration.yaml
        │   │   │       └── webhook-service.yaml
        │   │   └── values.yaml
        │   └── install.yaml
        ├── go.mod
        ├── grafana/
        │   ├── controller-resources-metrics.json
        │   ├── controller-runtime-metrics.json
        │   └── custom-metrics/
        │       └── config.yaml
        ├── hack/
        │   └── boilerplate.go.txt
        ├── internal/
        │   ├── controller/
        │   │   ├── busybox_controller.go
        │   │   ├── busybox_controller_test.go
        │   │   ├── memcached_controller.go
        │   │   ├── memcached_controller_test.go
        │   │   ├── suite_test.go
        │   │   ├── wordpress_controller.go
        │   │   └── wordpress_controller_test.go
        │   └── webhook/
        │       ├── v1/
        │       │   ├── webhook_suite_test.go
        │       │   ├── wordpress_webhook.go
        │       │   └── wordpress_webhook_test.go
        │       └── v1alpha1/
        │           ├── memcached_webhook.go
        │           ├── memcached_webhook_test.go
        │           └── webhook_suite_test.go
        └── test/
            ├── e2e/
            │   ├── e2e_suite_test.go
            │   └── e2e_test.go
            └── utils/
                └── utils.go

================================================
FILE CONTENTS
================================================

================================================
FILE: .github/ISSUE_TEMPLATE/bug_report.yaml
================================================
name: Bug Report
description: Problems and issues with code or docs
labels:
- kind/bug
body: 
- type: markdown
  attributes:
    value: |
      :warning: **Stop!** :warning:

      * If this is an issue with some sort of **runtime mechanics**,
        it probably belongs in [controller-runtime][cr-issue] instead

      * If this is an issue with **CRD generation**, webhook config generation,
        or deepcopy generation, it probably belongs in [controller-tools][ct-issue].

      * If this is an issue with **scaffolding**, or is definitely a
        cross-repository effort, it probably belongs here.  Feel free to continue :wink:

      [cr-issue]: https://github.com/kubernetes-sigs/controller-runtime/issues/new
      [ct-issue]: https://github.com/kubernetes-sigs/controller-tools/issues/new

- type: markdown
  attributes:
    value: |
      # Hiya!  Welcome to Kubebuilder!
      
      For a smooth issue process, try to answer the following questions.
      Don't worry if they're not all applicable; just try to include what you can :smile:

      If you need to include code snippets or logs, please put them in fenced code
      blocks, and if they're really long, use the [`<details>` tag][mdn-details], like:

      <details>

      <summary>Code & details examples</summary>
      
      `````markdown
      Some code written in Go:

      ```go
      type Manager struct {
        // FixTheBug removes all bugs from controller-runtime
        FixTheBug bool
      }
      ```

      <details>

      <summary>Some really long logs</summary>

      ```
      ok
      ok
      ok
      SHOOT A BUG HAPPENS HERE OH NO
      ok
      ok
      done
      ```

      </details>

      `````

      [mdn-details]: ://developer.mozilla.org/en-US/docs/Web/HTML/Element/details 

- type: textarea
  attributes:
    label: What broke? What's expected?
    description: |
      Describe what didn't go the way you thought it would.
      Please include *full* & *exact* error messages if you can!

      If you have an idea of what went wrong, feel free to include that
      as well.
  validations: {required: true}
 
- type: textarea
  attributes:
    label: Reproducing this issue
    description:
      If you have simple reproduction steps, or a minimal reproducer code
      snippet, please include it here.

      If they're already described above, no need to duplicate it here :smile:.

- type: markdown
  attributes:
    value: |
      ## What versions are you using?
      
      Please specify the relevant versions and sources for the pieces of
      kubebuilder that you're using.  The more details you can provide, the
      better.

- type: input
  id: cli-version
  attributes:
    label: KubeBuilder (CLI) Version
    description: "use `kubebuilder version` to find this out"
  validations:
    required: true

# project-version & plugin versions are not required for issues with initial scaffolding
- type: input
  id: project-version
  attributes:
    label: PROJECT version
    description: "look for the `version` field in your PROJECT file to find this"

- type: textarea
  attributes:
    label: Plugin versions
    description: "list the values of the `layout` field in your PROJECT file, if on KubeBuilder v3+"
    render: yaml

- type: textarea
  attributes:
    label: Other versions
    description: |
      Often times, the following pieces of information are relevant:
      - Go version (`go version`)
      - controller-runtime & controller-tools version (check your `go.mod` file)
      - Kubernetes & kubectl versions (run `kubectl version` against your api server)

- type: dropdown
  attributes: 
    label: "Extra Labels"
    description: |
      If this is *also* a documentation request, etc, please select that below.
    multiple: true
    options:
    - "/kind documentation"
    - "/kind feature"
    - "/kind regression"
    - "/kind deprecation"
    - "/kind cleanup"


================================================
FILE: .github/ISSUE_TEMPLATE/config.yml
================================================
# allow free form issues as an escape hatch.  This can be taken away if people abuse it ;-)
blank_issues_enabled: true

# link to CR and CT for easier access
contact_links:
- name: Runtime Issues
  url: https://github.com/kubernetes-sigs/controller-runtime/issues/new
  about: Runtime issues generally belong in the controller-runtime repository

- name: CRD/Webhook/Deepcopy Generation Issues
  url: https://github.com/kubernetes-sigs/controller-tools/issues/new
  about: YAML & Go generation issues generally belong in the controller-tools repository

- name: Support Questions
  url: https://github.com/kubernetes-sigs/kubebuilder/discussions/new
  about: Need support & not sure if this a bug?  You can ask questions in Slack or GitHub discussions.


================================================
FILE: .github/ISSUE_TEMPLATE/feature_request.yaml
================================================
name: Feature request
description: Suggest an idea for this project or its docs
labels:
- kind/feature
body:
- type: markdown
  attributes:
    value: |
      :warning: **Stop!** :warning:

      * If this is an issue with some sort of **runtime mechanics**,
        it probably belongs in [controller-runtime][cr-issue] instead

      * If this is an issue with **CRD generation**, webhook config generation,
        or deepcopy generation, it probably belongs in [controller-tools][ct-issue].

      * If this is an issue with **scaffolding**, or is definitely a
        cross-repository effort, it probably belongs here.  Feel free to continue :wink:

      [cr-issue]: https://github.com/kubernetes-sigs/controller-runtime/issues/new
      [ct-issue]: https://github.com/kubernetes-sigs/controller-tools/issues/new

- type: markdown
  attributes:
    value: |
      # Hiya!  Welcome to Kubebuilder!

      For a smooth issue process, try to answer the following questions.
      Don't worry if they're not all applicable; just try to include what you can :smile:

      If you need to include code snippets or logs, please put them in fenced code
      blocks, and if they're really long, use the [`<details>` tag][mdn-details], like:

      <details>

      <summary>Code & details examples</summary>

      `````markdown
      Some code written in Go:

      ```go
      type Manager struct {
        // FixTheBug removes all bugs from controller-runtime
        FixTheBug bool
      }
      ```

      <details>

      <summary>Some really long logs</summary>

      ```
      ok
      ok
      ok
      SHOOT A BUG HAPPENS HERE OH NO
      ok
      ok
      done
      ```

      </details>

      `````

      [mdn-details]: ://developer.mozilla.org/en-US/docs/Web/HTML/Element/details

- type: textarea
  attributes:
    label: What do you want to happen?
    description: |
      Describe the feature you want, and what the motivation is.

      What are your use cases?  Why should we do this?

      Does it require a particular Kubernetes version?

      Is there currently another issue associated with this (use github syntax
      like `#xyz` to link to it)?
  validations: {required: true}

- type: dropdown
  attributes:
    label: "Extra Labels"
    description: |
      If this is *also* a documentation request, etc, please select that below.
    multiple: true
    options:
    - "/kind documentation"
    - "/kind regression"
    - "/kind deprecation"
    - "/kind cleanup"


================================================
FILE: .github/PULL_REQUEST_TEMPLATE.md
================================================
<!--

Hiya!  Welcome to Kubebuilder!  For a smooth PR process, please ensure
that you include the following information:

* a description of the change
* the motivation for the change
* what issue it fixes, if any, in GitHub syntax (e.g. Fixes #XYZ)

Both the description and motivation may reference other issues and PRs,
but should be mostly understandable without following the links (e.g. when
reading the git commit log).

Please don't @-mention people in PR or commit messages (do so in an
additional comment).

please add an icon to the title of this PR depending on the type:

- ⚠ (:warning:): breaking
- ✨ (:sparkles:): new non-breaking feature
- 🐛 (:bug:): bugfix
- 📖 (:book:): documentation
- 🌱 (:seedling:): infrastructure/other

See https://sigs.k8s.io/kubebuilder-release-tools for more information.

**PLEASE REMOVE THIS COMMENT BLOCK BEFORE SUBMITTING THE PR** (the bits
between the arrows)

-->


================================================
FILE: .github/SECURITY.md
================================================
# Security Policy

## Security Announcements

Join the [kubernetes-security-announce] group for security and vulnerability announcements related to the Kubernetes ecosystem.

You can also subscribe to an RSS feed of these announcements using [this link][kubernetes-security-announce-rss].

## Reporting a Vulnerability

Instructions for reporting a vulnerability can be found on the [Kubernetes Security and Disclosure Information] page.

## Supported Versions

Kubebuilder is tested against the latest three Kubernetes releases, in alignment with the [Kubernetes version and version skew support policy](https://kubernetes.io/docs/setup/release/version-skew-policy/).

However, each version is only tested with the dependencies used for its release. For detailed information, please refer to the [compatibility and support policy on GitHub][compatibility-policy].

## Release Policy

Kubebuilder maintains a policy of releasing updates for the latest CLI version (currently v4). Older versions (v1, v2, v3) are no longer supported, and no releases will be produced for them. It is recommended to ensure that any project scaffolded by Kubebuilder remains aligned with the latest release.

## Automated Vulnerability Scanning

Kubebuilder employs automated scanning via Dependabot and GitHub Actions within its CI/CD pipeline. This process detects vulnerabilities in dependencies and configurations, generating daily or weekly reports prioritized for the latest supported versions.

- **Dependabot Configuration**: You can review the setup in `.github/dependabot.yml`.
- **Security Checks**: Security checks are enabled in the Kubebuilder repository settings.
- **Code Scanning**: The `.github/workflows/codeql.yml` workflow scans the `master` and `book-v4` branches, which typically contain the latest release code. Other release branches may not be scanned.

## Production-Grade Security

Projects generated by Kubebuilder are designed for ease of development and are **not** configured with production-grade security settings. For example, default configurations do not enable cert-manager or perform proper certificate validation, which may not be suitable for production environments. Ensure that you make the necessary adjustments to security settings before releasing your solution for production.

[kubernetes-security-announce]: https://groups.google.com/forum/#!forum/kubernetes-security-announce
[kubernetes-security-announce-rss]: https://groups.google.com/forum/feed/kubernetes-security-announce/msgs/rss_v2_0.xml?num=50
[Kubernetes version and version skew support policy]: https://kubernetes.io/docs/setup/release/version-skew-policy/#supported-versions
[Kubernetes Security and Disclosure Information]: https://kubernetes.io/docs/reference/issues-security/security/#report-a-vulnerability
[compatibility-policy]: ./../README.md#versions-compatibility-and-supportability
[project-upgrade-assistant]: https://book.kubebuilder.io/reference/rescaffold
[testdata-directory]: https://github.com/kubernetes-sigs/kubebuilder/tree/master/testdata
[kubebuilder-releases]: https://github.com/kubernetes-sigs/kubebuilder/releases


================================================
FILE: .github/dependabot.yml
================================================
# To get started with Dependabot version updates, you'll need to specify which
# package ecosystems to update and where the package manifests are located.
# Please see the documentation for all configuration options:
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates

version: 2
updates:
  # Maintain dependencies for GitHub Actions
  - package-ecosystem: "github-actions"
    # Workflow files stored in the
    # default location of `.github/workflows`
    directory: "/"
    schedule:
      interval: "daily"
    commit-message:
      prefix: ":seedling:"
    labels:
      - "ok-to-test"

  # Maintain dependencies for go
  - package-ecosystem: "gomod"
    directory: "/"
    schedule:
      interval: "daily"
    commit-message:
      prefix: ":seedling:"
    labels:
      - "ok-to-test"

  # Maintain dependencies for go
  - package-ecosystem: "gomod"
    directory: "/testdata/project-v4"
    schedule:
      interval: "daily"
    commit-message:
      prefix: ":seedling:"
    labels:
      - "ok-to-test"

  # Maintain dependencies for dockerfile scaffold in the projects
  - package-ecosystem: docker
    directory: "testdata/project-v4"
    schedule:
      interval: daily
    commit-message:
      prefix: ":seedling:"

  # Maintain dependencies for go in external plugin sample
  - package-ecosystem: "gomod"
    directory: "docs/book/src/simple-external-plugin-tutorial/testdata/sampleexternalplugin/v1"
    schedule:
      interval: "daily"
    commit-message:
      prefix: ":book:"
    labels:
      - "ok-to-test"


================================================
FILE: .github/instructions/kubebuilder.instructions.md
================================================
See [AGENTS.md](../../AGENTS.md) for AI agent guidelines.


================================================
FILE: .github/workflows/apidiff.yml
================================================
name: APIDiff

on:
  push:
    paths-ignore:
      - '**/*.md'
  pull_request:
    paths-ignore:
      - '**/*.md'

jobs:
  go-apidiff:
    name: Verify API differences
    runs-on: ubuntu-latest
    # Pull requests from different repository only trigger this checks
    if: (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository)
    steps:
      - name: Clone the code
        uses: actions/checkout@v6.0.2
        with:
          fetch-depth: 0
      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod
      - name: Execute go-apidiff
        uses: joelanford/go-apidiff@v0.8.3
        with:
          compare-imports: true
          print-compatible: true


================================================
FILE: .github/workflows/codeql.yml
================================================
name: "CodeQL Advanced"

on:
  # We are checking both `master` and `book-v4` branches:
  # - `master` represents the latest development work.
  # - `book-v4` is the latest stable release branch, which contains the latest published code,
  #   ensuring that any issues in production are identified and addressed promptly.
  schedule:
    - cron: '30 20 * * 1'  # Runs every Monday at 8:30 PM

jobs:
  analyze:
    name: Analyze Go
    runs-on: ubuntu-latest
    permissions:
      security-events: write
      packages: read
      actions: read
      contents: read

    steps:
      - name: Checkout repository
        uses: actions/checkout@v6.0.2

      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod

      - name: Build and install Kubebuilder CLI
        run: make install

      # Preparing the project-v4 sample for CodeQL analysis:
      # - `go mod tidy` ensures dependencies are fully resolved.
      # - `make manifests` generates required manifests for a complete project structure.
      # - `make build` builds the project code, ensuring all components are ready for CodeQL analysis.
      - name: Build project-v4 sample project
        run: |
          cd testdata/project-v4
          go mod tidy
          echo 'Running build commands for Go in project-v4'
          make manifests
          make build

      - name: Initialize CodeQL
        uses: github/codeql-action/init@v4
        with:
          languages: go
          build-mode: autobuild

      - name: Perform CodeQL Analysis
        uses: github/codeql-action/analyze@v4
        with:
          category: "/language:go"


================================================
FILE: .github/workflows/coverage.yml
================================================
name: Coverage

on:
  push:
    paths-ignore: ['**/*.md']
  pull_request:
    paths-ignore: ['**/*.md']

jobs:
  coverage:
    runs-on: ubuntu-latest
    if: (github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository)
    steps:
      - name: Checkout
        uses: actions/checkout@v6.0.2

      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod

      - name: Remove pre-installed kustomize
        run: sudo rm -f /usr/local/bin/kustomize

      - name: Install Kubebuilder
        run: make install

      - name: Run tests with coverage
        run: make test-coverage

      - name: Upload coverage to Coveralls
        uses: shogo82148/actions-goveralls@v1
        with:
          path-to-profile: coverage-all.out


================================================
FILE: .github/workflows/cross-platform-tests.yml
================================================
name: Cross-Platform Tests

# Trigger the workflow on pull requests and direct pushes to any branch
on:
  push:
    paths-ignore:
      - '**/*.md'
  pull_request:
    paths-ignore:
      - '**/*.md'

jobs:
  test:
    name: ${{ matrix.os }}
    runs-on: ${{ matrix.os }}
    strategy:
      matrix:
        os:
          - ubuntu-latest
          - macos-latest
    # Pull requests from the same repository won't trigger this checks as they were already triggered by the push
    if: (github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository)
    steps:
      - name: Clone the code
        uses: actions/checkout@v6.0.2
      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod
      # This step is needed as the following one tries to remove
      # kustomize for each test but has no permission to do so
      - name: Remove pre-installed kustomize
        run: sudo rm -f /usr/local/bin/kustomize

      - name: Unit Tests
        run: make test-unit

      - name: Run Testdata
        run: make test-testdata


================================================
FILE: .github/workflows/external-plugin.yml
================================================
name: External Plugin

on:
  push:
    paths:
      - 'pkg/'
      - 'docs/book/src/simple-external-plugin-tutorial/testdata/sampleexternalplugin'
      - '.github/workflows/external-plugin.yml'
  pull_request:
    paths:
      - 'pkg/'
      - 'docs/book/src/simple-external-plugin-tutorial/testdata/sampleexternalplugin'
      - '.github/workflows/external-plugin.yml'

jobs:
  external:
    name: Verify external plugin
    runs-on: ubuntu-latest
    if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
    steps:
      - name: Checkout repository
        uses: actions/checkout@v6.0.2

      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod

      - name: Run tests
        run: make test-external-plugin



================================================
FILE: .github/workflows/legacy-webhook-path.yml
================================================
# This test ensure that the legacy webhook path
# still working. The option is deprecated
# and should be removed when we no longer need
# to support go/v4 plugin.
name: Legacy Webhook Path

on:
  push:
    paths:
      - 'testdata/**'
      - '.github/workflows/legacy-webhook-path.yml'
  pull_request:
    paths:
      - 'testdata/**'
      - '.github/workflows/legacy-webhook-path.yml'

jobs:
  webhook-legacy-path:
    name: Verify Legacy Webhook Path
    runs-on: ubuntu-latest
    # Pull requests from the same repository won't trigger this checks as they were already triggered by the push
    if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
    steps:
      - name: Clone the code
        uses: actions/checkout@v6.0.2
      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod
      - name: Run make test-legacy
        run: make test-legacy



================================================
FILE: .github/workflows/lint-sample.yml
================================================
name: Lint Samples

on:
  push:
    paths:
      - 'testdata/**'
      - 'docs/book/src/**/testdata/**'
      - '.github/workflows/lint-sample.yml'
  pull_request:
    paths:
      - 'testdata/**'
      - 'docs/book/src/**/testdata/**'
      - '.github/workflows/lint-sample.yml'

jobs:
  lint-samples:
    runs-on: ubuntu-latest
    strategy:
      fail-fast: false
      matrix:
        folder: [
          "testdata/project-v4",
          "testdata/project-v4-with-plugins",
          "testdata/project-v4-multigroup",
          "docs/book/src/cronjob-tutorial/testdata/project",
          "docs/book/src/getting-started/testdata/project",
          "docs/book/src/multiversion-tutorial/testdata/project"
        ]
    if: (github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository)
    steps:
      - name: Clone the code
        uses: actions/checkout@v6.0.2
      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod
      - name: Prepare ${{ matrix.folder }}
        working-directory: ${{ matrix.folder }}
        run: go mod tidy
      - name: Check linter configuration
        working-directory: ${{ matrix.folder }}
        run: make lint-config
      - name: Run linter
        uses: golangci/golangci-lint-action@v9
        with:
          version: v2.8.0
          working-directory: ${{ matrix.folder }}
      - name: Run linter via makefile target
        working-directory: ${{ matrix.folder }}
        run: make lint



================================================
FILE: .github/workflows/lint.yml
================================================
name: Lint

on:
  push:
    paths-ignore:
      - '**/*.md'
  pull_request:
    paths-ignore:
      - '**/*.md'

jobs:
  lint:
    name: golangci-lint
    runs-on: ubuntu-latest
    # Pull requests from the same repository won't trigger this checks as they were already triggered by the push
    if: (github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository)
    steps:
      - name: Clone the code
        uses: actions/checkout@v6.0.2
      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod
      - name: Check linter configuration
        run: make lint-config
      - name: Run linter
        uses: golangci/golangci-lint-action@v9
        with:
          version: v2.8.0

  yamllint:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v6.0.2
      - name: Install Helm
        run: make install-helm
      - name: Run yamllint (YAML + Helm chart output 2-space indentation)
        run: make yamllint
      - name: Check sample permissions
        run: make check-sample-permissions

  license:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v6.0.2
      - name: Run license check
        run: make test-license


================================================
FILE: .github/workflows/release-version-ci.yml
================================================
name: Test GoReleaser and CLI Version

on:
  pull_request:
    branches:
      - master
    paths:
      - 'pkg/**'
      - 'cmd/**'
      - 'build/.goreleaser.yml'
      - '.github/workflows/release-version-ci.yml'

jobs:
  go-releaser-test:
    runs-on: ubuntu-latest

    steps:
      - name: Checkout code
        uses: actions/checkout@v6.0.2
        with:
          fetch-depth: 0

      - name: Set up Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod

      - name: Clean dist directory
        run: rm -rf dist || true

      - name: Create temporary git tag
        run: |
          git tag v4.5.3-rc.1

      - name: Install Syft to generate SBOMs
        run: |
          curl -sSfL https://raw.githubusercontent.com/anchore/syft/main/install.sh | sh -s -- -b $HOME/bin
          echo "$HOME/bin" >> $GITHUB_PATH
          
      - name: Run GoReleaser in mock mode using tag
        uses: goreleaser/goreleaser-action@v7
        with:
          version: v2.7.0
          args: release --skip=publish --clean -f ./build/.goreleaser.yml

      - name: Init project using built kubebuilder binary and check cliVersion
        run: |
          mkdir test-operator && cd test-operator
          go mod init test-operator
          chmod +x ../dist/kubebuilder_linux_$(go env GOARCH)_v1/kubebuilder
          ../dist/kubebuilder_linux_$(go env GOARCH)_v1/kubebuilder init --domain example.com

          echo "PROJECT file content:"
          cat PROJECT

          echo "Verifying cliVersion value..."
          grep '^cliVersion: 4.5.3-rc.1$' PROJECT


================================================
FILE: .github/workflows/release.yml
================================================
name: release
on:
  push:
    tags:
      - '*'

permissions:
  contents: write

jobs:
  goreleaser:
    runs-on: ubuntu-latest

    steps:
      - name: Checkout
        uses: actions/checkout@v6.0.2
        with:
          fetch-depth: 0
      - name: Fetch all tags
        run: git fetch --force --tags
      - name: Set up Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod
      - name: Clean dist directory
        run: rm -rf dist || true
      - name: Install Syft to generate SBOMs
        run: |
          curl -sSfL https://raw.githubusercontent.com/anchore/syft/main/install.sh | sh -s -- -b $HOME/bin
          echo "$HOME/bin" >> $GITHUB_PATH
      - name: Run GoReleaser
        uses: goreleaser/goreleaser-action@v7
        with:
          version: v2.7.0
          args: release -f ./build/.goreleaser.yml
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
      - name: Upload assets
        uses: actions/upload-artifact@v7.0.0
        with:
          name: kubebuilder
          path: dist/*
          if-no-files-found: error


================================================
FILE: .github/workflows/scorecard.yml
================================================
name: Scorecard supply-chain security
on:
  # For Branch-Protection check. Only the default branch is supported. See
  # https://github.com/ossf/scorecard/blob/main/docs/checks.md#branch-protection
  branch_protection_rule:
  # To guarantee Maintained check is occasionally updated. See
  # https://github.com/ossf/scorecard/blob/main/docs/checks.md#maintained
  schedule:
    - cron: "20 15 * * 5"
  push:
    branches: ["master"]

# Declare default permissions as read only.
permissions: read-all

jobs:
  analysis:
    name: Scorecard analysis
    runs-on: ubuntu-latest
    # `publish_results: true` only works when run from the default branch. conditional can be removed if disabled.
    if: github.event.repository.default_branch == github.ref_name || github.event_name == 'pull_request'
    permissions:
      # Needed to upload the results to code-scanning dashboard.
      security-events: write
      # Needed to publish results and get a badge (see publish_results below).
      id-token: write
      # Uncomment the permissions below if installing in a private repository.
      # contents: read
      # actions: read

    steps:
      - name: "Checkout code"
        uses: actions/checkout@0c366fd6a839edf440554fa01a7085ccba70ac98 # v6.0.1
        with:
          persist-credentials: false

      - name: "Run analysis"
        uses: ossf/scorecard-action@4eaacf0543bb3f2c246792bd56e8cdeffafb205a # v2.4.3
        with:
          results_file: results.sarif
          results_format: sarif
          # (Optional) "write" PAT token. Uncomment the `repo_token` line below if:
          # - you want to enable the Branch-Protection check on a *public* repository, or
          # - you are installing Scorecard on a *private* repository
          # To create the PAT, follow the steps in https://github.com/ossf/scorecard-action?tab=readme-ov-file#authentication-with-fine-grained-pat-optional.
          # repo_token: ${{ secrets.SCORECARD_TOKEN }}

          # Public repositories:
          #   - Publish results to OpenSSF REST API for easy access by consumers
          #   - Allows the repository to include the Scorecard badge.
          #   - See https://github.com/ossf/scorecard-action#publishing-results.
          # For private repositories:
          #   - `publish_results` will always be set to `false`, regardless
          #     of the value entered here.
          publish_results: true

          # (Optional) Uncomment file_mode if you have a .gitattributes with files marked export-ignore
          # file_mode: git

      # Upload the results as artifacts (optional). Commenting out will disable uploads of run results in SARIF
      # format to the repository Actions tab.
      - name: "Upload artifact"
        uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
        with:
          name: SARIF file
          path: results.sarif
          retention-days: 5

      # Upload the results to GitHub's code scanning dashboard (optional).
      # Commenting out will disable upload of results to your repo's Code Scanning dashboard
      - name: "Upload to code-scanning"
        uses: github/codeql-action/upload-sarif@v4
        with:
          sarif_file: results.sarif


================================================
FILE: .github/workflows/spaces.yml
================================================
name: Trailing

on:
  push:
    paths:
      - '**/*.md'
  pull_request:
    paths:
      - '**/*.md'

jobs:
  lint:
    name: "Check Trailing"
    runs-on: ubuntu-latest
    # Pull requests from the same repository won't trigger this checks as they were already triggered by the push
    if: (github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository)
    steps:
      - name: Clone the code
        uses: actions/checkout@v6.0.2
      - name: Run check
        run: make test-spaces


================================================
FILE: .github/workflows/test-alpha-generate.yml
================================================
name: Test Alpha Generate

on:
  push:
    paths:
      - 'pkg/cli/alpha/**'
      - '.github/workflows/test-alpha-generate.yml'
  pull_request:
    paths:
      - 'pkg/cli/alpha/**'
      - '.github/workflows/test-alpha-generate.yml'
      
jobs:
  unsupported:
    runs-on: ubuntu-latest
    strategy:
      fail-fast: true
    if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
    steps:
      - name: Checkout repository
        uses: actions/checkout@v6.0.2

      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod

      - name: Install dependencies and generate binary
        run: make install

      - name: Navigate to testdata/project-v4
        run: cd testdata/project-v4

      - name: Update PROJECT file
        run: |
          sed -i 's#go.kubebuilder.io/v4#go.kubebuilder.io/v3#g' testdata/project-v4/PROJECT

      # Validate if help output is working and workaround to
      # update the PROJECT file in memory to allow upgrade
      # no longer supported layouts did not break the command options
      - name: Validate help output for alpha generate
        run: |
          if kubebuilder alpha generate --help | grep -q "kubebuilder alpha generate \[flags\]"; then
            echo "Help output validated"
          else
            echo "Help output missing or invalid"
            exit 1
          fi    

      - name: Run kubebuilder alpha generate
        run: |
          cd testdata/project-v4 && kubebuilder alpha generate



================================================
FILE: .github/workflows/test-book.yml
================================================
name: E2E Book Samples

on:
  push:
    paths:
      - 'docs/book/src/getting-started/testdata/project/**'
      - 'docs/book/src/cronjob-tutorial/testdata/project/**'
      - 'docs/book/src/multiversion-tutorial/testdata/project/**'
      - '.github/workflows/test-e2e-book.yml'
  pull_request:
    paths:
      - 'docs/book/src/getting-started/testdata/project/**'
      - 'docs/book/src/cronjob-tutorial/testdata/project/**'
      - 'docs/book/src/multiversion-tutorial/testdata/project/**'
      - '.github/workflows/test-e2e-book.yml'

jobs:
  e2e:
    runs-on: ubuntu-latest
    strategy:
      fail-fast: true
      matrix:
        folder: [
          "docs/book/src/getting-started/testdata/project",
          "docs/book/src/cronjob-tutorial/testdata/project",
          "docs/book/src/multiversion-tutorial/testdata/project"
        ]
    if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
    steps:
      - name: Checkout repository
        uses: actions/checkout@v6.0.2

      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod

      - name: Install the latest version of kind
        run: |
          curl -Lo ./kind https://kind.sigs.k8s.io/dl/latest/kind-linux-$(go env GOARCH)
          chmod +x ./kind
          sudo mv ./kind /usr/local/bin/kind

      - name: Verify kind installation
        run: kind version

      - name: Create kind cluster
        run: kind create cluster

      - name: Running make test for ${{ matrix.folder }}
        working-directory: ${{ matrix.folder }}
        run: make test

      - name: Running make test-e2e for ${{ matrix.folder }}
        working-directory: ${{ matrix.folder }}
        run: make test-e2e


================================================
FILE: .github/workflows/test-devcontainer.yml
================================================
name: Test DevContainer Image

on:
  push:
    paths:
      - 'testdata/**'
      - '.github/workflows/test-devcontainer.yml'
      - 'pkg/plugins/golang/v4/scaffolds/internal/templates/devcontainer.go'
  pull_request:
    paths:
      - 'testdata/**'
      - '.github/workflows/test-devcontainer.yml'
      - 'pkg/plugins/golang/v4/scaffolds/internal/templates/devcontainer.go'

jobs:
  test-devcontainer:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout repository
        uses: actions/checkout@v6.0.2

      - name: Build and Run Dev Container Tests
        uses: devcontainers/ci@v0.3
        with:
          subFolder: testdata/project-v4
          runCmd: |
            # Source bash-completion for all tests
            source /usr/share/bash-completion/bash_completion
            
            # Verify Tools Installation
            echo "Verifying installed tools..."
            docker --version
            kind version
            kubebuilder version
            kubectl version --client
            go version
            echo "All required tools are installed"
            
            # Verify common-utils feature is installed
            echo "Verifying common-utils feature..."
            if ! command -v zsh &> /dev/null; then
              echo "ERROR: common-utils feature not installed (zsh missing)"
              exit 1
            fi
            echo "common-utils feature is installed"
            
            # Verify bash-completion setup
            echo "Verifying bash-completion configuration..."
            if ! grep -q "source /usr/share/bash-completion/bash_completion" ~/.bashrc; then
              echo "ERROR: bash-completion not configured in .bashrc"
              exit 1
            fi
            echo "bash-completion is configured in .bashrc"
            
            # Verify completion files exist
            echo "Verifying completion files..."
            for cmd in kubectl kind kubebuilder docker; do
              if [ ! -f "/usr/share/bash-completion/completions/${cmd}" ]; then
                echo "ERROR: Completion file for ${cmd} not found"
                exit 1
              fi
              echo "${cmd} completion file exists"
            done
            echo "All completion files are present"
            
            # Test bash-completion works
            echo "Testing bash-completion functionality..."
            # Bash-completion uses lazy-loading, so manually source completion to test
            source /usr/share/bash-completion/completions/kubectl
            if ! complete -p kubectl &> /dev/null; then
              echo "ERROR: kubectl completions not loaded"
              exit 1
            fi
            echo "Bash completions are working"

            # Test Docker-in-Docker
            echo "Testing Docker-in-Docker functionality..."
            docker ps
            docker network ls
            docker run --rm hello-world
            echo "Docker is working inside devcontainer"

            # Test Kubebuilder Workflow
            echo "Testing Kubebuilder development workflow..."
            go mod tidy
            make all
            echo "make all passed"
            make docker-build IMG=controller:ci
            echo "make docker-build passed"

            # Test Kind Cluster Creation
            echo "Testing kind cluster creation..."
            kind create cluster --name test-cluster
            kubectl cluster-info --context kind-test-cluster
            kubectl get nodes
            kind delete cluster --name test-cluster
            echo "Kind cluster creation and deletion successful"



================================================
FILE: .github/workflows/test-e2e-samples.yml
================================================
name: E2E Testdata Sample

on:
  push:
    paths:
      - 'testdata/**'
      - '.github/workflows/test-e2e-samples.yml'
  pull_request:
    paths:
      - 'testdata/**'
      - '.github/workflows/test-e2e-samples.yml'

jobs:
  e2e-tests-project-v4:
    runs-on: ubuntu-latest
    strategy:
      fail-fast: true
    if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
    steps:
      - name: Checkout repository
        uses: actions/checkout@v6.0.2

      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod

      - name: Install the latest version of kind
        run: |
          curl -Lo ./kind https://kind.sigs.k8s.io/dl/latest/kind-linux-$(go env GOARCH)
          chmod +x ./kind
          sudo mv ./kind /usr/local/bin/kind

      - name: Verify kind installation
        run: kind version

      - name: Create kind cluster
        run: kind create cluster

      - name: Prepare project-v4
        run: |
          # Enable [METRICS-WITH-CERTS] by uncommenting the lines in kustomization.yaml
          KUSTOMIZATION_FILE_PATH="testdata/project-v4/config/default/kustomization.yaml"
          sed -i '47,49s/^#//' $KUSTOMIZATION_FILE_PATH
          cd testdata/project-v4/
          go mod tidy

      - name: Testing make test-e2e for project-v4
        working-directory: testdata/project-v4/
        run: |
          make test-e2e

  e2e-tests-project-v4-with-plugins:
    runs-on: ubuntu-latest
    strategy:
      fail-fast: true
    if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
    steps:
      - name: Checkout repository
        uses: actions/checkout@v6.0.2

      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod

      - name: Install the latest version of kind
        run: |
          curl -Lo ./kind https://kind.sigs.k8s.io/dl/latest/kind-linux-$(go env GOARCH)
          chmod +x ./kind
          sudo mv ./kind /usr/local/bin/kind

      - name: Verify kind installation
        run: kind version

      - name: Create kind cluster
        run: kind create cluster

      - name: Prepare project-v4-with-plugins
        run: |
          cd testdata/project-v4-with-plugins/
          go mod tidy

      - name: Testing make test-e2e for project-v4-with-plugins
        working-directory: testdata/project-v4-with-plugins/
        run: |
          make test-e2e

  e2e-tests-project-v4-multigroup:
    runs-on: ubuntu-latest
    strategy:
      fail-fast: true
    if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
    steps:
      - name: Checkout repository
        uses: actions/checkout@v6.0.2

      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod

      - name: Install the latest version of kind
        run: |
          curl -Lo ./kind https://kind.sigs.k8s.io/dl/latest/kind-linux-$(go env GOARCH)
          chmod +x ./kind
          sudo mv ./kind /usr/local/bin/kind

      - name: Verify kind installation
        run: kind version

      - name: Create kind cluster
        run: kind create cluster

      - name: Prepare project-v4-multigroup
        run: |
          cd testdata/project-v4-multigroup
          go mod tidy

      - name: Testing make test-e2e for project-v4-multigroup
        working-directory: testdata/project-v4-multigroup/
        run: |
          make test-e2e

  # Test to validate e2e integration when no APIs are scaffolded
  e2e-test-basic-project:
    runs-on: ubuntu-latest
    if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
    steps:
      - name: Checkout repository
        uses: actions/checkout@v6.0.2

      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod

      - name: Install the latest version of kind
        run: |
          curl -Lo ./kind https://kind.sigs.k8s.io/dl/latest/kind-linux-$(go env GOARCH)
          chmod +x ./kind
          sudo mv ./kind /usr/local/bin/kind

      - name: Verify kind installation
        run: kind version

      - name: Create kind cluster
        run: kind create cluster

      - name: Build kubebuilder CLI from this repo
        run: make install

      - name: Scaffold empty go/v4 project
        run: |
          mkdir -p /tmp/basic-project-v4
          cd /tmp/basic-project-v4
          kubebuilder init --plugins go/v4 --domain example.com --repo example.com/empty-operator
          go mod tidy
          make

      - name: Run make test-e2e on empty project
        working-directory: /tmp/basic-project-v4
        run: make test-e2e


================================================
FILE: .github/workflows/test-helm-book.yml
================================================
name: Helm Docs Tutorials

on:
  push:
    paths:
      - "docs/book/src/cronjob-tutorial/testdata/project/**"
      - "docs/book/src/getting-started/testdata/project/**"
      - "docs/book/src/multiversion-tutorial/testdata/project/**"
      - ".github/workflows/test-helm-book.yml"
  pull_request:
    paths:
      - "docs/book/src/cronjob-tutorial/testdata/project/** "
      - "docs/book/src/getting-started/testdata/project/**"
      - "docs/book/src/multiversion-tutorial/testdata/project/**"
      - ".github/workflows/test-helm-book.yml"

jobs:
  helm-test:
    runs-on: ubuntu-latest
    strategy:
      fail-fast: true
      matrix:
        folder: [
          "docs/book/src/getting-started/testdata/project",
          "docs/book/src/cronjob-tutorial/testdata/project",
          "docs/book/src/multiversion-tutorial/testdata/project"
        ]
    if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
    steps:
      - name: Set project name
        id: project
        run: echo "name=$(basename ${{ matrix.folder }})" >> $GITHUB_OUTPUT

      - name: Checkout repository
        uses: actions/checkout@v6.0.2

      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod

      - name: Install the latest version of kind
        run: |
          curl -Lo ./kind https://kind.sigs.k8s.io/dl/latest/kind-linux-$(go env GOARCH)
          chmod +x ./kind
          sudo mv ./kind /usr/local/bin/kind

      - name: Verify kind installation
        run: kind version

      - name: Create kind cluster
        run: kind create cluster

      - name: Prepare project
        run: |
          cd ${{ matrix.folder }}
          go mod tidy
          make docker-build IMG=${{ steps.project.outputs.name}}:v0.1.0
          kind load docker-image ${{ steps.project.outputs.name}}:v0.1.0

      - name: Install Helm
        run: make install-helm

      - name: Lint Helm chart
        run: |
          helm lint ${{ matrix.folder }}/dist/chart

      - name: Install Prometheus Operator CRDs
        run: |
          helm repo add prometheus-community https://prometheus-community.github.io/helm-charts
          helm repo update
          helm install prometheus-crds prometheus-community/prometheus-operator-crds

      - name: Install cert-manager via Helm
        run: |
          helm repo add jetstack https://charts.jetstack.io
          helm repo update
          helm install cert-manager jetstack/cert-manager --namespace cert-manager --create-namespace --set crds.enabled=true

      - name: Wait for cert-manager to be ready
        run: |
          kubectl wait --namespace cert-manager --for=condition=available --timeout=300s deployment/cert-manager
          kubectl wait --namespace cert-manager --for=condition=available --timeout=300s deployment/cert-manager-cainjector
          kubectl wait --namespace cert-manager --for=condition=available --timeout=300s deployment/cert-manager-webhook

      - name: Render Helm chart
        run: |
          helm template ${{ matrix.folder }}/dist/chart --namespace=${{ steps.project.outputs.name }}-system

      - name: Deploy manager via Helm
        working-directory: ${{ matrix.folder }}
        run: |
          make helm-deploy IMG=${{ steps.project.outputs.name}}:v0.1.0

      - name: Check Helm release status
        working-directory: ${{ matrix.folder }}
        run: |
          make helm-status

      - name: Run Helm tests
        run: |
          helm test ${{ steps.project.outputs.name}} --namespace ${{ steps.project.outputs.name}}-system



================================================
FILE: .github/workflows/test-helm-samples.yml
================================================
name: Helm Testdata Sample

on:
  push:
    paths:
      - "testdata/project-v4-with-plugins/**"
      - ".github/workflows/test-helm-samples.yml"
  pull_request:
    paths:
      - "testdata/project-v4-with-plugins/**"
      - ".github/workflows/test-helm-samples.yml"

jobs:
  helm-test-project-v4-with-plugins:
    runs-on: ubuntu-latest
    strategy:
      fail-fast: true
    if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
    steps:
      - name: Checkout repository
        uses: actions/checkout@v6.0.2

      - name: Enable Prometheus in kustomize (testdata sample)
        run: |
          sed -i 's/^#- \.\.\/prometheus/- ..\/prometheus/' testdata/project-v4-with-plugins/config/default/kustomization.yaml

      - name: Build kubebuilder CLI
        run: make build

      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod

      - name: Prepare project-v4-with-plugins
        run: |
          cd testdata/project-v4-with-plugins/
          go mod tidy
          make all

      - name: Rebuild installer and regenerate Helm chart (v2-alpha)
        working-directory: testdata/project-v4-with-plugins
        run: |
          make build-installer
          ../../bin/kubebuilder edit --plugins=helm/v2-alpha --force

      - name: Install the latest version of kind
        run: |
          curl -Lo ./kind https://kind.sigs.k8s.io/dl/latest/kind-linux-$(go env GOARCH)
          chmod +x ./kind
          sudo mv ./kind /usr/local/bin/kind

      - name: Verify kind installation
        run: kind version

      - name: Create kind cluster
        run: kind create cluster

      - name: Install Helm
        run: make install-helm

      - name: Lint Helm chart for project-v4-with-plugins
        run: |
          helm lint testdata/project-v4-with-plugins/dist/chart

      - name: Build project-v4-with-plugins
        run: |
          cd testdata/project-v4-with-plugins/
          go mod tidy
          make docker-build IMG=controller:latest
          kind load docker-image controller:latest

      - name: Install Prometheus Operator CRDs
        run: |
          helm repo add prometheus-community https://prometheus-community.github.io/helm-charts
          helm repo update
          helm install prometheus-crds prometheus-community/prometheus-operator-crds

      - name: Install cert-manager via Helm (wait for readiness)
        run: |
          helm repo add jetstack https://charts.jetstack.io
          helm repo update
          helm install cert-manager jetstack/cert-manager \
            --namespace cert-manager \
            --create-namespace \
            --set crds.enabled=true \
            --wait \
            --timeout 300s

      - name: Render Helm chart for project-v4-with-plugins
        run: |
          helm template testdata/project-v4-with-plugins/dist/chart --namespace=project-v4-with-plugins-system

      - name: Deploy manager via Helm
        working-directory: testdata/project-v4-with-plugins
        run: |
          make helm-deploy IMG=controller:latest HELM_EXTRA_ARGS="--set prometheus.enable=true"

      - name: Check Helm release status
        working-directory: testdata/project-v4-with-plugins
        run: |
          make helm-status

      - name: Run Helm tests
        run: |
          helm test project-v4-with-plugins --namespace project-v4-with-plugins-system

      - name: Delete kind cluster
        if: always()
        run: |
          kind delete cluster || true

  # Test scenario: 
  # - scaffold project without creating webhooks, 
  # - deploy helm chart without installing cert manager;
  # - check that deployment has been deployed;
  #
  # Command to use to scaffold project without creating webhooks and so no need to install cert manager:
  # - kubebuilder init
  # - kubebuilder create api --group example.com --version v1 --kind App --controller=true --resource=true
  # - kubebuilder edit --plugins=helm.kubebuilder.io/v2-alpha
  test-helm-no-webhooks:
    runs-on: ubuntu-latest
    if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
    steps:
      - name: Checkout repository
        uses: actions/checkout@v6.0.2

      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod

      - name: Install the latest version of kind
        run: |
          curl -Lo ./kind https://kind.sigs.k8s.io/dl/latest/kind-linux-$(go env GOARCH)
          chmod +x ./kind
          sudo mv ./kind /usr/local/bin/kind

      - name: Create kind cluster
        run: kind create cluster

      - name: Install Helm
        run: make install-helm

      - name: Install kubebuilder binary
        run: make install

      - name: Create test directory
        run: mkdir -p test-helm-no-webhooks

      - name: Scaffold project with kubebuilder commands
        working-directory: test-helm-no-webhooks
        run: |
          go mod init test-helm-no-webhooks
          kubebuilder init
          kubebuilder create api --group example.com --version v1 --kind App --controller=true --resource=true
          kubebuilder edit --plugins=helm.kubebuilder.io/v2-alpha

      - name: Build and load Docker image
        working-directory: test-helm-no-webhooks
        run: |
          make docker-build IMG=controller:latest
          kind load docker-image controller:latest

      - name: Lint Helm chart
        working-directory: test-helm-no-webhooks
        run: helm lint ./dist/chart

      - name: Deploy manager via Helm
        working-directory: test-helm-no-webhooks
        run: |
          make helm-deploy IMG=controller:latest

      - name: Verify deployment is working
        working-directory: test-helm-no-webhooks
        run: |
          make helm-status

      - name: Run Helm tests
        working-directory: test-helm-no-webhooks
        run: |
          helm test test-helm-no-webhooks --namespace test-helm-no-webhooks-system

      - name: Delete kind cluster
        if: always()
        run: |
          kind delete cluster || true


================================================
FILE: .github/workflows/testdata.yml
================================================
name: Testdata verification

on:
  push:
  pull_request:

jobs:

  testdata:
    name: Verify testdata directory
    runs-on: ubuntu-latest
    # Pull requests from the same repository won't trigger this checks as they were already triggered by the push
    if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
    steps:
      - name: Clone the code
        uses: actions/checkout@v6.0.2
      - name: Setup Go
        uses: actions/setup-go@v6
        with:
          go-version-file: go.mod
      - name: Remove pre-installed kustomize
        # This step is needed as the following one tries to remove
        # kustomize for each test but has no permission to do so
        run: sudo rm -f /usr/local/bin/kustomize
      - name: Verify testdata directory
        run: make check-testdata
      - name: Verify docs update
        run: make check-docs


================================================
FILE: .github/workflows/verify.yml
================================================
name: "PR Title Verifier"

on:
  pull_request:
    types: [opened, edited, synchronize, reopened]

jobs:
  verify:
    runs-on: ubuntu-latest

    steps:
      - name: Checkout code
        uses: actions/checkout@v6.0.2

      - name: Validate PR Title Format
        env:
          TITLE: ${{ github.event.pull_request.title }}
        run: |
          if [[ -z "$TITLE" ]]; then
            echo "Error: PR title cannot be empty."
            exit 1
          fi

          if ! [[ "$TITLE" =~ ^($'\u26A0'|$'\u2728'|$'\U0001F41B'|$'\U0001F4D6'|$'\U0001F680'|$'\U0001F331') ]]; then
            echo "Error: Invalid PR title format."
            echo "Your PR title must start with one of the following indicators:"
            echo "- Breaking change: ⚠ (U+26A0)"
            echo "- Non-breaking feature: ✨ (U+2728)"
            echo "- Patch fix: 🐛 (U+1F41B)"
            echo "- Docs: 📖 (U+1F4D6)"
            echo "- Release: 🚀 (U+1F680)"
            echo "- Infra/Tests/Other: 🌱 (U+1F331)"
            exit 1
          fi

          echo "PR title is valid: '$TITLE'"


================================================
FILE: .gitignore
================================================
.idea/
.vscode/
WORKSPACE
.DS_Store
# don't check in the build output of the book
docs/book/book/

# ignore auto-generated dir by `mdbook serve`
docs/book/src/docs

# Editor temp files
*~
\#*#
*.swp

# skip bin dirs
**/bin
**/testbin

# skip GoReleaser dist directory (root level only, not testdata)
/dist

# skip .out files (coverage tests)
*.out

# skip testdata go.sum, since it may have
# different result depending on go version
/testdata/**/go.sum
/docs/book/src/simple-external-plugin-tutorial/testdata/sampleexternalplugin/v1/bin
/testdata/**legacy**

## Skip testdata files that generate by tests using TestContext
**/e2e-*/**
# Optional rendered chart output (e.g. from make yamllint-helm when debugging)
testdata/.helm-rendered.yaml

================================================
FILE: .golangci.yml
================================================
version: "2"
run:
  allow-parallel-runners: true
linters:
  default: none
  enable:
    - asciicheck
    - bidichk
    - copyloopvar
    - depguard
    - dupl
    - errcheck
    - ginkgolinter
    - goconst
    - gocyclo
    - govet
    - importas
    - ineffassign
    - lll
    - modernize
    - misspell
    - nakedret
    - nolintlint
    - prealloc
    - revive
    - staticcheck
    - unconvert
    - unparam
    - unused
    - wrapcheck
    - whitespace
  settings:
    depguard:
      rules:
        forbid-pkg-errors:
          deny:
            - pkg: sort
              desc: Should be replaced with slices package
    ginkgolinter:
      forbid-focus-container: true
      forbid-spec-pollution: true
    govet:
      disable:
        - fieldalignment
      enable-all: true
    importas:
      no-unaliased: true
      alias:
        - pkg: sigs.k8s.io/kubebuilder/v4/pkg/plugins/optional/helm/v1alpha
          alias: helmv1alpha
        - pkg: sigs.k8s.io/kubebuilder/v4/pkg/plugins/optional/helm/v2alpha
          alias: helmv2alpha
        - pkg: sigs.k8s.io/kubebuilder/v4/pkg/plugins/optional/grafana/v1alpha
          alias: grafanav1alpha
        - pkg: "sigs.k8s.io/kubebuilder/v4/pkg/plugins/optional/autoupdate/v1alpha"
          alias: autoupdatev1alpha
        - pkg: sigs.k8s.io/kubebuilder/v4/pkg/plugins/golang/deploy-image/v1alpha1
          alias: deployimagev1alpha1
        - pkg: sigs.k8s.io/kubebuilder/v4/pkg/plugins/golang/v4
          alias: golangv4
        - pkg: sigs.k8s.io/kubebuilder/v4/pkg/plugins/common/kustomize/v2
          alias: kustomizecommonv2
    modernize:
      disable:
      # Suggest replacing omitempty with omitzero for struct fields.
      # Disable this check for now since it introduces too many changes in our existing codebase.
      # See https://pkg.go.dev/golang.org/x/tools/go/analysis/passes/modernize#hdr-Analyzer_omitzero for more details.
        - omitzero
    nolintlint:
      allow-unused: false
    revive:
      rules:
        - name: blank-imports
        - name: context-as-argument
        - name: context-keys-type
        - name: dot-imports
          arguments:
            - allowedPackages:
                - github.com/onsi/ginkgo/v2
                - github.com/onsi/gomega
        - name: error-return
        - name: error-strings
        - name: error-naming
        - name: exported
          disabled: true
        - name: if-return
        - name: import-shadowing
        - name: increment-decrement
        - name: var-naming
          severity: warning
          arguments:
            - ["ID"] # allowed initialisms
            - ["VM"] # disallowed initialisms
            - [
                # <-- this is a list containing one map
                {
                  skip-initialism-name-checks: true,
                  upper-case-const: true,
                  skip-package-name-checks: true,
                  extra-bad-package-names: ["helpers", "models"],
                },
              ]
        - name: var-declaration
        - name: package-comments
          disabled: true
        - name: range
        - name: receiver-naming
        - name: time-naming
        - name: unexported-return
        - name: indent-error-flow
        - name: errorf
        - name: empty-block
        - name: superfluous-else
        - name: unused-parameter
        - name: unreachable-code
        - name: redefines-builtin-id
        - name: bool-literal-in-expr
        - name: constant-logical-expr
        - name: comment-spacings
  exclusions:
    generated: lax
    rules:
      - linters:
          - gosec
        path: test/e2e/*
      - linters:
          - gosec
          - lll
        path: hack/docs/*
    paths:
      - third_party$
      - builtin$
      - examples$
formatters:
  enable:
    - gci
    - gofmt
    - gofumpt
    - goimports
  settings:
    gci:
      sections:
        - standard
        - default
        - prefix(sigs.k8s.io/kubebuilder)
  exclusions:
    generated: lax
    paths:
      - third_party$
      - builtin$
      - examples$


================================================
FILE: .yamllint
================================================
# yamllint configuration for Kubebuilder
# Aligns with Kubernetes YAML best practices:
# - 2-space indentation, spaces only (no tabs)
# - true/false over yes/no for booleans (truthy)
# - Newline at end of file, no trailing spaces (POSIX)
# - Unix newlines, consistent colons/hyphens
# - No duplicate keys (key-duplicates)
# - Document start (---) recommended for manifests; not enforced to allow existing testdata
extends: default
rules:
  line-length:
    max: 120
    allow-non-breakable-words: true
    # Generated CRDs and Prometheus manifests often have long lines
    ignore: |
      **/config/crd/bases/*.yaml
      **/config/prometheus/*.yaml
  indentation:
    spaces: 2
    # Kubernetes manifests often use list items at same indent as key (rules:\n- apiGroups:)
    indent-sequences: whatever
    # Uncommented replacement blocks in config/default/kustomization.yaml use 1-space for list items
    ignore: |
      **/config/default/kustomization.yaml
  # Kubernetes: prefer true/false over yes/no; do not check keys (e.g. "on" in workflows)
  truthy:
    check-keys: false
  # Allow single trailing blank line (common in editors)
  empty-lines:
    max-end: 1
  # Optional: document-start (---) is K8s best practice but not enforced for testdata
  document-start: disable
  document-end: disable


================================================
FILE: .yamllint-helm
================================================
# yamllint config for Helm-rendered manifest output (stdin or temp files).
# Extends repo .yamllint; relaxes rules that are noisy for generated/template output.
extends: .yamllint
rules:
  line-length: disable
  trailing-spaces: disable


================================================
FILE: AGENTS.md
================================================
# Kubebuilder AI Agent Guide

**Kubebuilder** is a **framework** and **command-line interface (CLI)** for building **Kubernetes APIs** using **Custom Resource Definitions (CRDs)**.
It provides scaffolding and abstractions that accelerate the development of **controllers**, **webhooks**, and **APIs** written in **Go**.

## Quick Reference

| Item       | Value                                                     |
|------------|-----------------------------------------------------------|
| Language   | Defined in the go.mod                                     |
| Module     | `sigs.k8s.io/kubebuilder/v4`                              |
| Binary     | `./bin/kubebuilder`                                       |
| Core deps  | `controller-runtime`, `controller-tools`, Helm, Kustomize |
| Docs       | https://book.kubebuilder.io                               |


## Directory Map

```
pkg/
  cli/              CLI command implementations
    alpha/          Alpha/experimental commands (generate, update, etc.)
    init.go         'init' command + default PluginBundle definition
    api.go          'create api' command
    webhook.go      'create webhook' command
    edit.go         'edit' command
    root.go         Root command setup
  machinery/        Scaffolding engine (templates, markers, injectors)
    template.go     Base template interface
    inserter.go     Code injection engine
    marker.go       Marker detection and processing
    filesystem.go   Filesystem abstraction (uses afero)
  model/
    resource/       Resource model (GVK, API, Controller, Webhook)
    stage/          Plugin execution stages
  plugin/           Plugin interfaces and utilities
    interface.go    Core plugin interfaces (Plugin, Init, CreateAPI, etc.)
    bundle.go       Plugin composition
    util/           Helper functions for plugin authors
  plugins/          Plugin implementations (ADD NEW PLUGINS HERE)
    golang/v4/      Main Go scaffolding (default for go projects)
      scaffolds/    Scaffolding for init, api, webhook
        internal/templates/  Template implementations
    golang/deployimage/  Deploy-image pattern plugin
    common/kustomize/v2/  Kustomize manifest generation (default)
    optional/       Optional plugins (enabled via --plugins flag)
      helm/         Helm chart generation (v1alpha deprecated, v2alpha current)
      grafana/      Grafana dashboard generation
      autoupdate/   Auto-update GitHub workflow
    external/       External plugin support (exec-based plugins)
docs/book/          mdBook documentation (https://book.kubebuilder.io)
  src/              Markdown source files
    **/testdata/    Sample projects used in docs (regenerated)
test/
  e2e/              E2E tests requiring Kubernetes cluster
    v4/             Tests for v4 plugin
    helm/           Tests for Helm plugin
    deployimage/    Tests for deploy-image plugin
    utils/          Test helpers (TestContext, etc.)
  testdata/         Scripts to generate testdata projects
    generate.sh     Main generation script
    test.sh         Tests all testdata projects
testdata/           Generated complete sample projects (DO NOT EDIT)
  project-v4/                    Basic v4 project
  project-v4-multigroup/         Multigroup project
  project-v4-with-plugins/       Project with optional plugins
hack/docs/          Documentation generation
  generate.sh       Regenerate docs samples + marker docs
  generate_samples.go  Sample generation logic
cmd/                CLI entry point
  version.go        Version info (updated by make update-k8s-version)
main.go             Application entry point
```

**Key Locations for Common Tasks:**
- Add new plugin → `pkg/plugins/<category>/<name>/`
- Add new template → `pkg/plugins/<plugin>/scaffolds/internal/templates/`
- Modify CLI commands → `pkg/cli/`
- Add scaffolding machinery → `pkg/machinery/`
- Add tests → `test/e2e/all/plugin_<name>_test.go` or `pkg/<package>/*_test.go`

## Critical Rules

### Do Not Manually Edit Generated Files
- `testdata/` - regenerated via `make generate-testdata`
- `docs/book/**/testdata/` - regenerated via `make generate-docs`
- `*/dist/chart/` - regenerated via `make generate-charts`

### File-Specific Requirements

After making changes, run the appropriate commands based on what you modified:

**Generate Commands (rebuild artifacts):**
- **If you modify files in `hack/docs/internal/`** → run `make install && make generate-docs`
- **If you modify files in `pkg/plugins/optional/helm/`** → run `make install && make generate-charts`
- **If you modify any boilerplate/template files** → run `make install && make generate`

**Formatting Commands:**
- After editing `*.go` → `make lint-fix`
- After editing `*.md` → `make remove-spaces`

**Always Run Before PR:**
```bash
make lint-fix    # Auto-fix Go code style
make test-unit   # Verify unit tests pass
```

**Note:** Boilerplate/template files are Go files that define scaffolding templates, typically located in `pkg/plugins/**/scaffolds/internal/templates/` or files that generate code/configs for scaffolded projects.

## Development Workflow

### Build & Install
```bash
make build    # Build to ./bin/kubebuilder
make install  # Copy to $(go env GOBIN)
```

### Lint & Format
```bash
make lint       # Check only (golangci-lint + yamllint)
make lint-fix   # Auto-fix Go code
```

### Testing
```bash
make test-unit         # Fast unit tests (./pkg/..., ./test/e2e/utils/...)
make test-integration  # Integration tests (may create temp dirs, download binaries)
make test-testdata     # Test all testdata projects
make test-e2e-local    # Full e2e (creates kind cluster)
make test              # CI aggregate (all of above + license)
```

## PR Submission

### PR Title Format (MANDATORY)

PR titles use **emojis** (appear in release notes).

Format: `:emoji: [(plugin/version)]: Description`

The `(plugin/version)` scope is optional; omit it for repo-wide or documentation-only changes.

**Emojis:**
- ⚠️ (`:warning:`) - Breaking change
- ✨ (`:sparkles:`) - New feature
- 🐛 (`:bug:`) - Bug fix
- 📖 (`:book:`) - Documentation
- 🌱 (`:seedling:`) - Infrastructure/tests/refactor

**Examples:**
```
🐛 Resolve nil pointer panic in scaffold generator
✨ (helm/v2-alpha): Add cluster-scoped resource support
📖 (go/v4): Update deployment documentation
✨ Update dependencies to latest versions
```

### Commit Message Format

Commit messages follow the [Conventional Commits](https://www.conventionalcommits.org/) standard.

Format: `<type>[optional scope]: <description>`

The `[optional scope]` is typically the plugin/version (e.g., `helm/v2-alpha`, `go/v4`); omit it for repo-wide or non-plugin changes.

**Types:**

- **feat**: A new feature for the user or a plugin
- **fix**: A bug fix for the user or a plugin
- **docs**: Documentation changes only
- **test**: Adding or updating tests
- **refactor**: Code change that neither fixes a bug nor adds a feature
- **chore**: Changes to build process, dependencies, or maintenance tasks
- **breaking**: A breaking change (can be combined with other types)

**Examples:**
```
fix: Resolve nil pointer panic in scaffold generator
feat(helm/v2-alpha): Add cluster-scoped resource support
docs(go/v4): Update deployment documentation
chore: Update dependencies to latest versions
```

### Pre-PR Checklist
- [ ] One commit per PR (squash all)
- [ ] Add/update tests for new behavior
- [ ] Add/update docs for new behavior
- [ ] Run `make lint-fix`
- [ ] Run `make install`
- [ ] Run `make generate`
- [ ] Run `make test-unit`

## Core Concepts

### Plugin Architecture

Plugins implement interfaces from `pkg/plugin/`:
- `Plugin` - base interface (Name, Version, SupportedProjectVersions)
- `Init` - project initialization (`kubebuilder init`)
- `CreateAPI` - API creation (`kubebuilder create api`)
- `CreateWebhook` - webhook creation (`kubebuilder create webhook`)
- `Edit` - post-init modifications (`kubebuilder edit`)
- `Bundle` - groups multiple plugins

**Plugin Bundles:**

Default bundle (`pkg/cli/init.go`): `go.kubebuilder.io/v4` + `kustomize.common.kubebuilder.io/v2`

Plugins resolve via `pkg/plugin` registry and execute in order.

**External Plugins:**

Executable binaries in `pkg/plugins/external/` that communicate via JSON over stdin/stdout.

### Scaffolding Machinery

From `pkg/machinery/`:
- `Template` - file generation via Go templates
- `Inserter` - code injection at markers
- `Marker` - special comments (e.g., `// +kubebuilder:scaffold:imports`)
- `Filesystem` - abstraction over afero for testability

### Scaffolded Project Structure

Projects generated by the Kubebuilder CLI use the default plugin bundle (`go/v4` + `kustomize/v2`). Each plugin scaffolds different files:

**`go/v4` plugin scaffolds Go code:**
- `cmd/main.go` - Entry point (manager setup)
- `api/v1/*_types.go` - API definitions with `+kubebuilder` markers (via `create api`)
- `internal/controller/*_controller.go` - Reconcile logic (via `create api`)
- `Dockerfile`, `Makefile` - Build and deployment automation

**`kustomize/v2` plugin scaffolds manifests:**
- `config/` - Kustomize base manifests (CRDs, RBAC, manager, webhooks)
- `config/crd/` - Custom Resource Definitions (via `create api`)
- `config/samples/` - Example CR manifests (via `create api`)

**`PROJECT` file:**
- Project configuration tracking plugins, resources, domain, and layout

**Note:** These are files in projects generated BY Kubebuilder, not the Kubebuilder source code itself.

### Reconciliation Pattern

Controllers implement `Reconcile(ctx, req) (ctrl.Result, error)`:

- **Idempotent** - Safe to run multiple times
- **Level-triggered** - React to current state, not events
- **Requeue on pending work** - Return `ctrl.Result{Requeue: true}`

### Testing Pattern
E2E tests use `utils.TestContext` from `test/e2e/utils/test_context.go`:

```go
ctx := utils.NewTestContext(util.KubebuilderBinName, "GO111MODULE=on")
ctx.Init("--domain", "example.com", "--repo", "example.com/project")
ctx.CreateAPI("--group", "crew", "--version", "v1", "--kind", "Captain")
ctx.Make("build", "test")
ctx.LoadImageToKindCluster()
```

## CLI Reference

After `make install`:

```bash
kubebuilder init --domain example.com --repo github.com/example/myproject
kubebuilder create api --group batch --version v1 --kind CronJob
kubebuilder create webhook --group batch --version v1 --kind CronJob
kubebuilder edit --plugins=helm/v2-alpha
kubebuilder alpha generate    # Experimental: generate from PROJECT file
kubebuilder alpha update      # Experimental: update to latest plugin versions
```

## Common Patterns

### Code Style
- Avoid abbreviations: `context` not `ctx` (except receivers)
- Descriptive names: `projectConfig` not `pc`
- Single/double-letter receivers OK: `(c CLI)` or `(p Plugin)`

### Logging Conventions

Kubebuilder has two distinct types of code with different logging conventions:

**1. Kubebuilder CLI Tool Code** → Go CLI best practices

Applies to: `pkg/cli/*`, `pkg/plugins/*`, `pkg/machinery/*`, `pkg/config/*`, `pkg/model/*`, etc.

This is the Kubebuilder tool itself. Follow Go logging conventions for CLI tools:
- **First word lowercase**, sentences after periods capitalized: `"unable to find file. This file is required for..."`
- **No ending punctuation** (but use periods between sentences)
- **Error strings lowercase**: `fmt.Errorf("something bad")`

```go
log.Info("writing scaffold for you to edit")
log.Warn("unable to find boilerplate file. This file is used to generate the license header")
log.Error("failed to read file", "file", path)
return fmt.Errorf("failed to load config: %w", err)
```

**2. Generated Code (Template Output)** → Kubernetes conventions

Applies to: Code GENERATED by templates in `pkg/plugins/*/scaffolds/internal/templates/*`

Templates produce controller code that runs in Kubernetes clusters. The GENERATED code follows Kubernetes conventions:
- **Start with capital letter**: `"Starting reconciliation"`
- **No ending period** (but use periods between sentences)
- **Past tense**: `"Failed to create Pod"` not `"Cannot create Pod"`
- **Active voice**: specify subject or omit when it's the program itself
- **Specify object type**: `"Created Deployment"` not `"Created"`

```go
// In template files that generate controller code:
log.Info("Starting reconciliation")
log.Info("Created Deployment", "name", deploy.Name)
log.Error(err, "Failed to create Pod", "name", name)
```

**Note:** The distinction is based on WHERE the code runs:
- CLI tool (runs on developer's machine) → Go conventions
- Generated controllers (run in Kubernetes cluster) → Kubernetes conventions

### Testing Philosophy
- Test behaviors, not implementations
- Use real components over mocks
- Test cases as specifications (Ginkgo: `Describe`, `It`, `Context`, `By`)
- Use **Ginkgo v2** + **Gomega** for BDD-style tests.
- Tests depending on the Kubebuilder binary should use: `utils.NewTestContext(util.KubebuilderBinName, "GO111MODULE=on")`

### Test Organization

- **Unit tests** (`*_test.go` in `pkg/`) - Test individual packages in isolation, fast
- **Integration tests** (`*_integration_test.go` in `pkg/`) - Test multiple components together without cluster
  - Must have `//go:build integration` tag at the top
  - May create temp dirs, download binaries, or scaffold files
  - Examples: alpha update, grafana scaffolding, helm chart generation
- **E2E tests** (`test/e2e/`) - **ONLY** for tests requiring a Kubernetes cluster (KIND)
  - `v4/plugin_cluster_test.go` - Test v4 plugin deployment
  - `helm/plugin_cluster_test.go` - Test Helm chart deployment
  - `deployimage/plugin_cluster_test.go` - Test deploy-image plugin

### Scaffolding
- Use library helpers from `pkg/plugin/util/`
- Use markers for extensibility
- Follow existing template patterns in `pkg/machinery`

## Search Tips

```bash
rg "\\+kubebuilder:scaffold" --type go  # Find markers
rg "type.*Plugin struct" pkg/plugins/   # Plugin implementations
rg "PluginBundle" pkg/cli/              # Plugin registration
rg "func.*SetTemplateDefaults"          # Template definitions
rg "func new.*Command" pkg/cli/         # CLI commands
rg "NewTestContext" test/e2e/           # E2E test setup
```

## Design Philosophy

- **Libraries over code generation** - Use libraries when possible; generated code is hard to maintain
- **Common cases easy, uncommon cases possible** - 80-90% use cases should be simple
- **Batteries included** - Projects should be deployable/testable out-of-box
- **No copy-paste** - Refactor into libraries or remote Kustomize bases

## References

### Essential Files
- **`Makefile`** - All automation targets (source of truth for build/test commands)
- **`CONTRIBUTING.md`** - CLA, pre-submit checklist, PR requirements
- **`VERSIONING.md`** - Release workflow, versioning policy, PR tagging
- **`go.mod`** - Go version and dependencies

### Key Directories
- **`pkg/`** - Core Kubebuilder code (CLI, plugins, machinery)
- **`test/e2e/`** - End-to-end tests with Kubernetes cluster
- **`testdata/`** - Generated sample projects (regenerated automatically)
- **`docs/book/`** - User documentation source (https://book.kubebuilder.io)

### Important Code Files
- **`pkg/cli/init.go`** - Default plugin bundle definition
- **`pkg/plugin/interface.go`** - Plugin interface definitions
- **`pkg/machinery/scaffold.go`** - Scaffolding engine
- **`test/e2e/utils/test_context.go`** - E2E test helpers
- **`cmd/version.go`** - Version info (includes K8S version)

### Scripts
- **`test/testdata/generate.sh`** - Regenerate all testdata projects
- **`hack/docs/generate.sh`** - Regenerate documentation samples
- **`test/e2e/local.sh`** - Run e2e tests locally with Kind

### External Resources
- **Kubebuilder Book**: https://book.kubebuilder.io
- **Kubebuilder Repo**: https://github.com/kubernetes-sigs/kubebuilder
- **controller-runtime**: https://github.com/kubernetes-sigs/controller-runtime
- **controller-tools**: https://github.com/kubernetes-sigs/controller-tools
- **API Conventions**: https://github.com/kubernetes/community/blob/master/contributors/devel/sig-architecture/api-conventions.md
- **Operator Pattern**: https://kubernetes.io/docs/concepts/extend-kubernetes/operator/
- **Kubernetes Logging Conventions:** https://github.com/kubernetes/community/blob/master/contributors/devel/sig-instrumentation/logging.md#message-style-guidelines
- **Structured Logging Guidelines:** https://github.com/kubernetes/community/blob/master/contributors/devel/sig-instrumentation/migration-to-structured-logging.md


================================================
FILE: CONTRIBUTING.md
================================================
# Contributing guidelines

This document describes how to contribute to the project.

## Sign the CLA

Kubernetes projects require that you sign a Contributor License Agreement (CLA) before we can accept your pull requests.

Please see https://git.k8s.io/community/CLA.md for more info.

## Prerequisites

- [go](https://golang.org/dl/) version v1.23+.
- [docker](https://docs.docker.com/install/) version 17.03+.
- [kubectl](https://kubernetes.io/docs/tasks/tools/install-kubectl/) version v1.11.3+.
- [kustomize](https://github.com/kubernetes-sigs/kustomize/blob/master/site/content/en/docs/Getting%20started/installation.md) v3.1.0+
- Access to a Kubernetes v1.11.3+ cluster.

## Contributing steps

1. Submit an issue describing your proposed change to the repo in question.
1. The [repo owners](OWNERS) will respond to your issue promptly.
1. If your proposed change is accepted, and you haven't already done so, sign a Contributor License Agreement (see details above).
1. Fork the desired repo, develop and test your code changes.
1. Submit a pull request.

In addition to the above steps, we adhere to the following best practices to maintain consistency and efficiency in our project:

- **Single Commit per PR:** Each Pull Request (PR) should contain only one commit. This approach simplifies tracking changes and makes the history more readable.
- **One Issue per PR:** Each PR should address a single specific issue or need. This helps in streamlining our workflow and makes it easier to identify and resolve problems such as revert the changes if required.

For more detailed guidelines, refer to the [Kubernetes Contributor Guide][k8s-contrubutiong-guide].

## How to build kubebuilder locally

Note that, by building the kubebuilder from the source code we are allowed to test the changes made locally.

1. Run the following command to clone your fork of the project locally in the dir /src/sigs.k8s.io/kubebuilder

```
$ git clone git@github.com:<user>/kubebuilder.git $GOPATH/src/sigs.k8s.io/kubebuilder
```

1. Ensure you activate module support before continue (`$ export GO111MODULE=on`)
1. Run the command `make install` to create a bin with the source code

**NOTE** In order to check the local environment run `make test-unit`.

## What to do before submitting a pull request

1. Run the script `make generate` to update/generate the mock data used in the e2e test in `$GOPATH/src/sigs.k8s.io/kubebuilder/testdata/`
1. Run `make test-unit test-e2e-local`

- e2e tests use [`kind`][kind] and [`setup-envtest`][setup-envtest]. If you want to bring your own binaries, place them in `$(go env GOPATH)/bin`.

**IMPORTANT:** The `make generate` is very helpful. By using it, you can check if good part of the commands still working successfully after the changes. Also, note that its usage is a prerequisite to submit a PR.

Following the targets that can be used to test your changes locally.

| Command             | Description                                                   | Is called in the CI? |
| ------------------- | ------------------------------------------------------------- | -------------------- |
| make test-unit      | Runs go tests                                                 | no                   |
| make test           | Runs tests in shell (`./test.sh`)                             | yes                  |
| make lint           | Run [golangci][golangci] lint checks                          | yes                  |
| make lint-fix       | Run [golangci][golangci] to automatically perform fixes       | no                   |
| make test-coverage  | Run coveralls to check the % of code covered by tests         | yes                  |
| make check-testdata | Checks if the testdata dir is updated with the latest changes | yes                  |
| make test-e2e-local | Runs the CI e2e tests locally                                 | no                   |

**NOTE** `make lint` requires a local installation of `golangci-lint`. More info: https://github.com/golangci/golangci-lint#install

### Running e2e tests locally

See that you can run `test-e2e-local` to setup Kind and run e2e tests locally.
Another option is by manually starting up Kind and configuring it and then,
you can for example via your IDEA debug the e2e tests.

To manually setup run:

```shell
# To generate an Kubebuilder local binary with your changes
make install
# To create the cluster
kind create cluster --config ./test/e2e/kind-config.yaml
```

Now, you can for example, run in debug mode the `test/e2e/all/e2e_suite_test.go`:

![example](https://github.com/kubernetes-sigs/kubebuilder/assets/7708031/277d26d5-c94d-41f0-8f02-1381458ef750)

### Test Plugin

If your intended PR creates a new plugin, make sure the PR also provides test cases. Testing should include:

1. `e2e tests` to validate the behavior of the proposed plugin.
2. `sample projects` to verify the scaffolded output from the plugin.

#### 1. Plugin E2E Tests

All the plugins provided by Kubebuilder should be validated through `e2e-tests` across multiple platforms.

Current Kubebuilder provides the testing framework that includes testing code based on [ginkgo](https://github.com/onsi/ginkgo), [Github Actions](https://github.com/Kavinjsir/kubebuilder/blob/docs%2Ftest-plugin/.github/workflows/testdata.yml) for unit tests, and multiple env tests driven by [test-infra](https://github.com/kubernetes/test-infra/blob/master/config/jobs/kubernetes-sigs/kubebuilder/kubebuilder-presubmits.yaml).

To fully test the proposed plugin:

1. Add test specs to `test/e2e/plugin_<your-plugin>_test.go` in the unified test suite.
2. Tests should use the shared `e2e_suite_test.go` BeforeSuite/AfterSuite hooks (cert-manager and Prometheus are already installed).
3. Each test should:
   - Initialize a `TestContext` using `utils.NewTestContext`
   - Trigger the plugin's bound subcommands. See [Init](https://github.com/kubernetes-sigs/kubebuilder/blob/v3.7.0/test/e2e/utils/test_context.go#L213), [CreateAPI](https://github.com/kubernetes-sigs/kubebuilder/blob/v3.6.0/test/e2e/utils/test_context.go#L222)
   - Use [PluginUtil](https://pkg.go.dev/sigs.k8s.io/kubebuilder/v4/pkg/plugin/util) to verify the scaffolded outputs
4. Test validation should:

   - 4.1. Setup testing environment, e.g:

     - Cleanup environment, create temp dir. See [Prepare](https://github.com/kubernetes-sigs/kubebuilder/blob/v3.7.0/test/e2e/utils/test_context.go#L97)
     - If your test will cover the provided features then, ensure that you install prerequisites CRDs: See [InstallCertManager](https://github.com/kubernetes-sigs/kubebuilder/blob/v3.7.0/test/e2e/utils/test_context.go#L138), [InstallPrometheusManager](https://github.com/kubernetes-sigs/kubebuilder/blob/v3.6.0/test/e2e/utils/test_context.go#L171)

   - 4.2. Run the function from `generate_test.go`.

   - 4.3. Further make sure the scaffolded output works, e.g:

     - Execute commands in your `Makefile`. See [Make](https://github.com/kubernetes-sigs/kubebuilder/blob/v3.7.0/test/e2e/utils/test_context.go#L240)
     - Temporary load image of the testing controller. See [LoadImageToKindCluster](https://github.com/kubernetes-sigs/kubebuilder/blob/v3.7.0/test/e2e/utils/test_context.go#L283)
     - Call Kubectl to validate running resources. See [utils.Kubectl](https://pkg.go.dev/sigs.k8s.io/kubebuilder/v4/test/e2e/utils#Kubectl)

   - 4.4. Delete temporary resources after testing exited, e.g:
     - Uninstall prerequisites CRDs: See [UninstallPrometheusOperManager](https://github.com/kubernetes-sigs/kubebuilder/blob/v3.7.0/test/e2e/utils/test_context.go#L183)
     - Delete temp dir. See [Destroy](https://github.com/kubernetes-sigs/kubebuilder/blob/v3.7.0/test/e2e/utils/test_context.go#L255)

5. Add the command in [test/e2e/plugin](https://github.com/kubernetes-sigs/kubebuilder/blob/v3.7.0/test/e2e/setup.sh#L65) to run your testing code:

```shell
go test $(dirname "$0")/<your-plugin-test-folder> $flags -timeout 30m
```

#### 2. Sample Projects from the Plugin

It is also necessary to test consistency of the proposed plugin across different env and the integration with other plugins.

This is performed by generating sample projects based on the plugins. The CI workflow defined in Github Action would validate the availability and the consistency.

See:

- [test/testdata/generated.sh](https://github.com/kubernetes-sigs/kubebuilder/blob/v3.7.0/test/testdata/generate.sh#L144)
- [make generate](https://github.com/kubernetes-sigs/kubebuilder/blob/v3.7.0/Makefile#L70)

## PR Process

See [VERSIONING.md](VERSIONING.md) for a full description. TL;DR:

### PR Title Format

PR titles use **emojis** (appear in release notes). Format: `:emoji: (plugin/version): Description`

**Emojis:**
- ⚠️ (`:warning:`) - Breaking change
- ✨ (`:sparkles:`) - New feature
- 🐛 (`:bug:`) - Bug fix
- 📖 (`:book:`) - Documentation
- 🌱 (`:seedling:`) - Infrastructure/tests/refactor
- 👻 (`:ghost:`) - No release note (unreleased changes only)

**Examples:**
```
🐛 Resolve nil pointer panic in scaffold generator
✨ (helm/v2-alpha): Add cluster-scoped resource support
📖 (go/v4): Update deployment documentation
✨ Update dependencies to latest versions
🌱 Add new GitHub action to test out doc samples
```

### Commit Message Format

Commit messages follow the [Conventional Commits](https://www.conventionalcommits.org/) standard.

Format: `<type>[optional scope]: <description>`

The `[optional scope]` is typically the plugin/version (e.g., `helm/v2-alpha`, `go/v4`); omit it for repo-wide or non-plugin changes.

**Types:**

- **feat**: A new feature for the user or a plugin
- **fix**: A bug fix for the user or a plugin
- **docs**: Documentation changes only
- **test**: Adding or updating tests
- **refactor**: Code change that neither fixes a bug nor adds a feature
- **chore**: Changes to build process, dependencies, or maintenance tasks
- **breaking**: A breaking change (can be combined with other types)

**Examples:**
```
fix: Resolve nil pointer panic in scaffold generator
feat(helm/v2-alpha): Add cluster-scoped resource support
docs(go/v4): Update deployment documentation
chore: Update dependencies to latest versions
```

## Where the CI Tests are configured

1. See the [action files](.github/workflows) to check its tests, and the scripts used on it.
2. Note that the prow tests used in the CI are configured in [kubernetes-sigs/kubebuilder/kubebuilder-presubmits.yaml](https://github.com/kubernetes/test-infra/blob/master/config/jobs/kubernetes-sigs/kubebuilder/kubebuilder-presubmits.yaml).
3. Check that all scripts used by the CI are defined in the project.
4. Notice that our policy to test the project is to run against k8s version N-2. So that the old version should be removed when there is a new k8s version available.

## How to contribute to docs

The docs are published off of three branches:

- `book-v4`: [book.kubebuilder.io](https://book.kubebuilder.io) -- current docs
- `book-v3`: [book-v3.book.kubebuilder.io](https://book-v3.book.kubebuilder.io) -- legacy docs
- `book-v2`: [book-v2.book.kubebuilder.io](https://book-v2.book.kubebuilder.io) -- legacy docs
- `book-v1`: [book-v1.book.kubebuilder.io](https://book-v1.book.kubebuilder.io) -- legacy docs
- `master`: [master.book.kubebuilder.io](https://master.book.kubebuilder.io) -- "nightly" docs

See [VERSIONING.md](VERSIONING.md#book-releases) for more information.

The documentation is rendered using [mdBook with its advanced Markdown features](https://rust-lang.github.io/mdBook/format/markdown.html).

There are certain writing style guidelines for Kubernetes documentation, checkout [style guide](https://kubernetes.io/docs/contribute/style/style-guide/) for more information.

### How to preview the changes performed in the docs

Check the CI job after to do the Pull Request and then, click on in the `Details` of `netlify/kubebuilder/deploy-preview`

## Community, discussion and support

Learn how to engage with the Kubernetes community on the [community page](http://kubernetes.io/community/).

You can reach the maintainers of this project at:

- [Slack](http://slack.k8s.io/)
- [Mailing List](https://groups.google.com/forum/#!forum/kubebuilder)

## Becoming a reviewer or approver

Contributors may eventually become official reviewers or approvers in
Kubebuilder and the related repositories. See
[CONTRIBUTING-ROLES.md](docs/CONTRIBUTING-ROLES.md) for more information.

## Code of conduct

Participation in the Kubernetes community is governed by the [Kubernetes Code of Conduct](code-of-conduct.md).

[golangci]: https://github.com/golangci/golangci-lint
[kind]: https://kind.sigs.k8s.io/#installation-and-usage
[setup-envtest]: https://book.kubebuilder.io/reference/envtest
[k8s-contrubutiong-guide]: https://www.kubernetes.dev/docs/guide/contributing/


================================================
FILE: DESIGN.md
================================================
# Kubebuilder Design Principles

This lays out some of the guiding design principles behind the Kubebuilder
project and its various components.

## Overarching

* **Libraries Over Code Generation**: Generated code is messy to maintain,
  hard for humans to change and understand, and hard to update.  Library
  code is easy to update (just increase your dependency version), easier
  to version using existing mechanisms, and more concise.

* **Copy-pasting is bad**: Copy-pasted code suffers from similar problems
  as code generation, except more acutely.  Copy-pasted code is nearly
  impossible to easy update, and frequently suffers from bugs and
  misunderstandings.  If something is being copy-pasted, it should
  refactored into a library component or remote
  [kustomize](https://sigs.k8s.io/kustomize) base.

* **Common Cases Should Be Easy**: The 80-90% common cases should be
  simple and easy for users to understand.

* **Uncommon Cases Should Be Possible**: There shouldn't be situations
  where it's downright impossible to do something within
  controller-runtime or controller-tools. It may take extra digging or
  coding, and it may involve interoperating with lower-level components,
  but it should be possible without unreasonable friction.

## Kubebuilder

* **Kubebuilder Has Opinions**: Kubebuilder exists as an opinionated
  project generator.  It should strive to give users a reasonable project
  layout that's simple enough to understand when getting started, but
  provides room to grow.  It might not match everyone's opinions, but it
  should strive to be useful to most.

* **Batteries Included**: Kubebuilder projects should contain enough
  deployment information to reasonably develop and run the scaffolded
  project.  This includes testing, deployment files, and development
  infrastructure to go from code to running containers.

## controller-tools and controller-runtime

* **Sufficient But Composable**: controller-tools and controller-runtime
  should be sufficient for building a custom controller by hand.  While
  scaffolding and additional libraries may make life easier, building
  without should be as painless as possible.  That being said, they should
  strive to be usable as building blocks for higher-level libraries as
  well.

* **Self-Sufficient Docs**: controller-tools and controller-runtime should
  strive to have self-sufficient docs (i.e. documentation that doesn't
  require reading other libraries' documentation for common use cases).
  Examples should be plentiful.

* **Contained Arcana**: Developers should not need to be experts in
  Kubernetes API machinery to develop controllers, but those familiar with
  Kubernetes API machinery should not feel out of place.  Abstractions
  should be intuitive to new users but feel familiar to experienced ones.
  Abstractions should embrace the concepts of Kubernetes (e.g. declarative
  idempotent reconcilers) while simplifying the details.

## controller-runtime

* **Abstractions Should Be Layered**: Abstractions should be built on top
  of lower layers, such that advanced users can write custom logic while
  still working within the existing model.  For instance, the controller
  builder is built on top of the event, source, and handler helpers, which
  are in turn built for use with the event, source, and handler
  interfaces.

* **Repetitive Stress Injuries Are Bad**:
  When possible, commonly used pieces should be exposed in a way that
  enables clear, concise code.  This includes aliasing groups of
  functionality under "alias" or "prelude" packages to avoid having 40
  lines of imports, including common idioms as flexible helpers, and
  infering resource information from the user's object types in client
  code.

* **A Little Bit of Magic Goes a Long Way**: In absence of generics,
  reflection is acceptable, especially when it leads to clearer, conciser
  code.  However, when possible interfaces that use reflection should be
  designed to avoid requiring the end-developer to use type assertions,
  string splitting, which are error-prone and repetitive.  These should be
  dealt with inside controller-runtime internals.

* **Defaults Over Constructors**: When not a huge performance impact,
  favor auto-defaulting and `Options` structs over constructors.
  Constructors quickly become unclear due to lack of names associated
  with values, and don't work well with optional values.

## Development

* **Words Are Better Than Letters**: Don't abbreviate variable names
  unless it's blindingly obvious what they are (e.g. `ctx` for `Context`).
  Single- and double-letter method receivers are acceptable, but single-
  and double-letter variables quickly become confusing the longer a code
  block gets.

* **Well-commented code**: Code should be commented and given Godocs, even
  private methods and functions. It may *seem* obvious what they do at the
  time and why, but you might forget, and others will certainly come along.

* **Test Behaviors**: Test cases should be comprehensible as sets of
  expected behaviors.  Test cases read without code (e.g. just using `It`,
  `Describe`, `Context`, and `By` lines) should still be able to explain
  what's required of the tested interface. Testing behaviors makes
  internal refactors easier, and makes reading tests easier.

* **Real Components Over Mocks**: Avoid mocks and recording actions. Mocks
  tend to be brittle and gradually become more complicated over time (e.g.
  fake client implementations tend to grow into poorly-written, incomplete
  API servers).  Recording of actions tends to lead to brittle tests that
  requires changes during refactors.  Instead, test that the end desired
  state is correct.  Test the way the world should be, without caring how
  it got there, and provide easy ways to set up the real components so
  that mocks aren't required.


================================================
FILE: LICENSE
================================================
                                 Apache License
                           Version 2.0, January 2004
                        http://www.apache.org/licenses/

   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION

   1. Definitions.

      "License" shall mean the terms and conditions for use, reproduction,
      and distribution as defined by Sections 1 through 9 of this document.

      "Licensor" shall mean the copyright owner or entity authorized by
      the copyright owner that is granting the License.

      "Legal Entity" shall mean the union of the acting entity and all
      other entities that control, are controlled by, or are under common
      control with that entity. For the purposes of this definition,
      "control" means (i) the power, direct or indirect, to cause the
      direction or management of such entity, whether by contract or
      otherwise, or (ii) ownership of fifty percent (50%) or more of the
      outstanding shares, or (iii) beneficial ownership of such entity.

      "You" (or "Your") shall mean an individual or Legal Entity
      exercising permissions granted by this License.

      "Source" form shall mean the preferred form for making modifications,
      including but not limited to software source code, documentation
      source, and configuration files.

      "Object" form shall mean any form resulting from mechanical
      transformation or translation of a Source form, including but
      not limited to compiled object code, generated documentation,
      and conversions to other media types.

      "Work" shall mean the work of authorship, whether in Source or
      Object form, made available under the License, as indicated by a
      copyright notice that is included in or attached to the work
      (an example is provided in the Appendix below).

      "Derivative Works" shall mean any work, whether in Source or Object
      form, that is based on (or derived from) the Work and for which the
      editorial revisions, annotations, elaborations, or other modifications
      represent, as a whole, an original work of authorship. For the purposes
      of this License, Derivative Works shall not include works that remain
      separable from, or merely link (or bind by name) to the interfaces of,
      the Work and Derivative Works thereof.

      "Contribution" shall mean any work of authorship, including
      the original version of the Work and any modifications or additions
      to that Work or Derivative Works thereof, that is intentionally
      submitted to Licensor for inclusion in the Work by the copyright owner
      or by an individual or Legal Entity authorized to submit on behalf of
      the copyright owner. For the purposes of this definition, "submitted"
      means any form of electronic, verbal, or written communication sent
      to the Licensor or its representatives, including but not limited to
      communication on electronic mailing lists, source code control systems,
      and issue tracking systems that are managed by, or on behalf of, the
      Licensor for the purpose of discussing and improving the Work, but
      excluding communication that is conspicuously marked or otherwise
      designated in writing by the copyright owner as "Not a Contribution."

      "Contributor" shall mean Licensor and any individual or Legal Entity
      on behalf of whom a Contribution has been received by Licensor and
      subsequently incorporated within the Work.

   2. Grant of Copyright License. Subject to the terms and conditions of
      this License, each Contributor hereby grants to You a perpetual,
      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
      copyright license to reproduce, prepare Derivative Works of,
      publicly display, publicly perform, sublicense, and distribute the
      Work and such Derivative Works in Source or Object form.

   3. Grant of Patent License. Subject to the terms and conditions of
      this License, each Contributor hereby grants to You a perpetual,
      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
      (except as stated in this section) patent license to make, have made,
      use, offer to sell, sell, import, and otherwise transfer the Work,
      where such license applies only to those patent claims licensable
      by such Contributor that are necessarily infringed by their
      Contribution(s) alone or by combination of their Contribution(s)
      with the Work to which such Contribution(s) was submitted. If You
      institute patent litigation against any entity (including a
      cross-claim or counterclaim in a lawsuit) alleging that the Work
      or a Contribution incorporated within the Work constitutes direct
      or contributory patent infringement, then any patent licenses
      granted to You under this License for that Work shall terminate
      as of the date such litigation is filed.

   4. Redistribution. You may reproduce and distribute copies of the
      Work or Derivative Works thereof in any medium, with or without
      modifications, and in Source or Object form, provided that You
      meet the following conditions:

      (a) You must give any other recipients of the Work or
          Derivative Works a copy of this License; and

      (b) You must cause any modified files to carry prominent notices
          stating that You changed the files; and

      (c) You must retain, in the Source form of any Derivative Works
          that You distribute, all copyright, patent, trademark, and
          attribution notices from the Source form of the Work,
          excluding those notices that do not pertain to any part of
          the Derivative Works; and

      (d) If the Work includes a "NOTICE" text file as part of its
          distribution, then any Derivative Works that You distribute must
          include a readable copy of the attribution notices contained
          within such NOTICE file, excluding those notices that do not
          pertain to any part of the Derivative Works, in at least one
          of the following places: within a NOTICE text file distributed
          as part of the Derivative Works; within the Source form or
          documentation, if provided along with the Derivative Works; or,
          within a display generated by the Derivative Works, if and
          wherever such third-party notices normally appear. The contents
          of the NOTICE file are for informational purposes only and
          do not modify the License. You may add Your own attribution
          notices within Derivative Works that You distribute, alongside
          or as an addendum to the NOTICE text from the Work, provided
          that such additional attribution notices cannot be construed
          as modifying the License.

      You may add Your own copyright statement to Your modifications and
      may provide additional or different license terms and conditions
      for use, reproduction, or distribution of Your modifications, or
      for any such Derivative Works as a whole, provided Your use,
      reproduction, and distribution of the Work otherwise complies with
      the conditions stated in this License.

   5. Submission of Contributions. Unless You explicitly state otherwise,
      any Contribution intentionally submitted for inclusion in the Work
      by You to the Licensor shall be under the terms and conditions of
      this License, without any additional terms or conditions.
      Notwithstanding the above, nothing herein shall supersede or modify
      the terms of any separate license agreement you may have executed
      with Licensor regarding such Contributions.

   6. Trademarks. This License does not grant permission to use the trade
      names, trademarks, service marks, or product names of the Licensor,
      except as required for reasonable and customary use in describing the
      origin of the Work and reproducing the content of the NOTICE file.

   7. Disclaimer of Warranty. Unless required by applicable law or
      agreed to in writing, Licensor provides the Work (and each
      Contributor provides its Contributions) on an "AS IS" BASIS,
      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
      implied, including, without limitation, any warranties or conditions
      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
      PARTICULAR PURPOSE. You are solely responsible for determining the
      appropriateness of using or redistributing the Work and assume any
      risks associated with Your exercise of permissions under this License.

   8. Limitation of Liability. In no event and under no legal theory,
      whether in tort (including negligence), contract, or otherwise,
      unless required by applicable law (such as deliberate and grossly
      negligent acts) or agreed to in writing, shall any Contributor be
      liable to You for damages, including any direct, indirect, special,
      incidental, or consequential damages of any character arising as a
      result of this License or out of the use or inability to use the
      Work (including but not limited to damages for loss of goodwill,
      work stoppage, computer failure or malfunction, or any and all
      other commercial damages or losses), even if such Contributor
      has been advised of the possibility of such damages.

   9. Accepting Warranty or Additional Liability. While redistributing
      the Work or Derivative Works thereof, You may choose to offer,
      and charge a fee for, acceptance of support, warranty, indemnity,
      or other liability obligations and/or rights consistent with this
      License. However, in accepting such obligations, You may act only
      on Your own behalf and on Your sole responsibility, not on behalf
      of any other Contributor, and only if You agree to indemnify,
      defend, and hold each Contributor harmless for any liability
      incurred by, or claims asserted against, such Contributor by reason
      of your accepting any such warranty or additional liability.

   END OF TERMS AND CONDITIONS

   APPENDIX: How to apply the Apache License to your work.

      To apply the Apache License to your work, attach the following
      boilerplate notice, with the fields enclosed by brackets "{}"
      replaced with your own identifying information. (Don't include
      the brackets!)  The text should be enclosed in the appropriate
      comment syntax for the file format. We also recommend that a
      file or class name and description of purpose be included on the
      same "printed page" as the copyright notice for easier
      identification within third-party archives.

   Copyright {yyyy} {name of copyright owner}

   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
   You may obtain a copy of the License at

       http://www.apache.org/licenses/LICENSE-2.0

   Unless required by applicable law or agreed to in writing, software
   distributed under the License is distributed on an "AS IS" BASIS,
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   See the License for the specific language governing permissions and
   limitations under the License.

================================================
FILE: Makefile
================================================
#!/usr/bin/env bash

#  Copyright 2023 The Kubernetes Authors.
#
#  Licensed under the Apache License, Version 2.0 (the "License");
#  you may not use this file except in compliance with the License.
#  You may obtain a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
#  Unless required by applicable law or agreed to in writing, software
#  distributed under the License is distributed on an "AS IS" BASIS,
#  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
#  See the License for the specific language governing permissions and
#  limitations under the License.

#
# Makefile with some common workflow for dev, build and test
#
export GOPROXY?=https://proxy.golang.org/

# Get the currently used golang install path (in GOPATH/bin, unless GOBIN is set)
ifeq (,$(shell go env GOBIN))
GOBIN=$(shell go env GOPATH)/bin
else
GOBIN=$(shell go env GOBIN)
endif

## Location to install dependencies to
LOCALBIN ?= $(shell pwd)/bin
$(LOCALBIN):
	mkdir -p $(LOCALBIN)

##@ General

# The help target prints out all targets with their descriptions organized
# beneath their categories. The categories are represented by '##@' and the
# target descriptions by '##'. The awk command is responsible for reading the
# entire set of makefiles included in this invocation, looking for lines of the
# file as xyz: ## something, and then pretty-format the target and help. Then,
# if there's a line with ##@ something, that gets pretty-printed as a category.
# More info on the usage of ANSI control characters for terminal formatting:
# https://en.wikipedia.org/wiki/ANSI_escape_code#SGR_parameters
# More info on the awk command:
# http://linuxcommand.org/lc3_adv_awk.php

.PHONY: help
help: ## Display this help
	@awk 'BEGIN {FS = ":.*##"; printf "\nUsage:\n  make \033[36m<target>\033[0m\n"} /^[a-zA-Z_0-9-]+:.*?##/ { printf "  \033[36m%-15s\033[0m %s\n", $$1, $$2 } /^##@/ { printf "\n\033[1m%s\033[0m\n", substr($$0, 5) } ' $(MAKEFILE_LIST)

##@ Build

.PHONY: build
build: ## Build the project locally
	go build --trimpath -o bin/kubebuilder

.PHONY: install
install: build ## Build and install the binary with the current source code. Use it to test your changes locally.
	rm -f $(GOBIN)/kubebuilder
	cp ./bin/kubebuilder $(GOBIN)/kubebuilder

##@ Development

.PHONY: generate
generate: generate-testdata generate-docs ## Update/generate all mock data. You should run this commands to update the mock data after your changes.
	go mod tidy
	make remove-spaces

.PHONY: remove-spaces
remove-spaces:
	@echo "Removing trailing spaces"
	@bash -c ' \
		if sed --version 2>&1 | grep -q "GNU"; then \
			find . -type f -name "*.md" -exec sed -i "s/[[:space:]]*$$//" {} + || true; \
		else \
			find . -type f -name "*.md" -exec sed -i "" "s/[[:space:]]*$$//" {} + || true; \
		fi'

.PHONY: generate-testdata
generate-testdata: ## Update/generate the testdata in $GOPATH/src/sigs.k8s.io/kubebuilder
	chmod -R +w testdata/
	rm -rf testdata/
	./test/testdata/generate.sh

.PHONY: generate-docs
generate-docs: ## Update/generate the docs
	./hack/docs/generate.sh

.PHONY: generate-charts
generate-charts: build ## Re-generate the helm chart testdata and docs samples
	rm -rf testdata/project-v4-with-plugins/dist/chart
	rm -rf docs/book/src/getting-started/testdata/project/dist/chart
	rm -rf docs/book/src/cronjob-tutorial/testdata/project/dist/chart
	rm -rf docs/book/src/multiversion-tutorial/testdata/project/dist/chart

	# Generate helm charts from kustomize manifests using v2-alpha plugin
	(cd testdata/project-v4-with-plugins && make build-installer && ../../bin/kubebuilder edit --plugins=helm/v2-alpha)
	(cd docs/book/src/getting-started/testdata/project && make build-installer && ../../../../../../bin/kubebuilder edit --plugins=helm/v2-alpha)
	(cd docs/book/src/cronjob-tutorial/testdata/project && make build-installer && ../../../../../../bin/kubebuilder edit --plugins=helm/v2-alpha)
	(cd docs/book/src/multiversion-tutorial/testdata/project && make build-installer && ../../../../../../bin/kubebuilder edit --plugins=helm/v2-alpha)

.PHONY: check-docs
check-docs: ## Run the script to ensure that the docs are updated
	./hack/docs/check.sh

.PHONY: lint
lint: golangci-lint yamllint check-sample-permissions ## Run golangci-lint linter, yamllint & sample permissions check
	$(GOLANGCI_LINT) run

.PHONY: lint-fix
lint-fix: golangci-lint ## Run golangci-lint linter and perform fixes
	$(GOLANGCI_LINT) run --fix

.PHONY: lint-config
lint-config: golangci-lint ## Verify golangci-lint linter configuration
	$(GOLANGCI_LINT) config verify

# Lint all YAML: testdata files (yamllint-yaml) + Helm-rendered charts (yamllint-helm).
# Repo YAML uses .yamllint; Helm output uses .yamllint-helm.
YAMLLINT_FILES := $(shell find testdata -name '*.yaml' ! -path 'testdata/.helm-rendered.yaml' \( ! -path 'testdata/*/dist/*' -o -path 'testdata/*/dist/chart/Chart.yaml' -o -path 'testdata/*/dist/chart/values.yaml' \) 2>/dev/null)
HELM_CHARTS := $(shell find testdata docs/book -type d -path '*/dist/chart' 2>/dev/null)

.PHONY: yamllint yamllint-yaml yamllint-helm
yamllint: yamllint-yaml yamllint-helm

yamllint-yaml:
	@docker run --rm $$(tty -s && echo "-it" || echo) -v $(PWD):/data -w /data cytopia/yamllint:latest $(YAMLLINT_FILES) -c .yamllint --no-warnings

yamllint-helm:
	@for chart in $(HELM_CHARTS); do \
	  helm template release $$chart --namespace=release-system 2>/dev/null | \
	  docker run --rm -i -v $(PWD):/data -w /data cytopia/yamllint:latest -c .yamllint-helm --no-warnings - || (echo "yamllint-helm: $$chart failed"; exit 1); \
	done

# All Kubebuilder-generated samples (go/v4, kustomize, helm use machinery defaults 0755/0644).
SAMPLE_ROOTS := testdata \
	docs/book/src/getting-started/testdata \
	docs/book/src/cronjob-tutorial/testdata \
	docs/book/src/multiversion-tutorial/testdata

.PHONY: check-sample-permissions
check-sample-permissions: ## Fail if any file/dir under testdata or docs samples has wrong permissions (expect 0644/0755). bin/ excluded.
	@for d in $(SAMPLE_ROOTS); do \
		test -d "$$d" || continue; \
		bad=$$(find "$$d" -path '*/bin' -prune -o \( \( -type f ! -perm 0644 \) -o \( -type d ! -perm 0755 \) \) -print 2>/dev/null); \
		if [ -n "$$bad" ]; then echo "Invalid permissions under $$d (expect 0644/0755):"; echo "$$bad"; exit 1; fi; \
	done

.PHONY: golangci-lint
golangci-lint:
	$(call go-install-tool,$(GOLANGCI_LINT),github.com/golangci/golangci-lint/v2/cmd/golangci-lint,${GOLANGCI_LINT_VERSION})

.PHONY: apidiff
apidiff: go-apidiff ## Run the go-apidiff to verify any API differences compared with origin/master
	$(GO_APIDIFF) master --compare-imports --print-compatible --repo-path=.

.PHONY: go-apidiff
go-apidiff:
	$(call go-install-tool,$(GO_APIDIFF),github.com/joelanford/go-apidiff,$(GO_APIDIFF_VERSION))

##@ Tests

.PHONY: test
test: test-unit test-integration test-testdata test-book test-license test-gomod ## Run the unit and integration tests (used in the CI)

.PHONY: test-unit
TEST_PKGS := ./pkg/... ./test/e2e/utils/...
test-unit: ## Run the unit tests
	go test -race $(TEST_PKGS)

.PHONY: test-integration
test-integration: install ## Run the integration tests (requires kubebuilder binary in PATH)
	go test -race -tags=integration -timeout 30m $(TEST_PKGS)

.PHONY: test-coverage
test-coverage: ## Run unit and integration tests with coverage report
	- rm -rf *.out  # Remove all coverage files if exists
	go test -race -failfast -tags=integration -timeout 30m \
		-coverprofile=coverage-all.out \
		-coverpkg="\
./pkg/cli/...,\
./pkg/config/...,\
./pkg/internal/...,\
./pkg/machinery/...,\
./pkg/model/...,\
./pkg/plugin/...,\
./pkg/plugins/golang,\
./pkg/plugins/golang/deploy-image/v1alpha1,\
./pkg/plugins/golang/v4,\
./pkg/plugins/external/...,\
./pkg/plugins/common/kustomize/v2,\
./pkg/plugins/optional/autoupdate/v1alpha,\
./pkg/plugins/optional/grafana/...,\
./pkg/plugins/optional/helm/v2alpha/..." \
		$(TEST_PKGS)

.PHONY: check-testdata
check-testdata: ## Run the script to ensure that the testdata is updated
	./test/testdata/check.sh

.PHONY: test-testdata
test-testdata: ## Run the tests of the testdata directory
	./test/testdata/test.sh

.PHONY: test-e2e-local
test-e2e-local: ## Run the end-to-end tests locally
	## To keep the same kind cluster between test runs, use `SKIP_KIND_CLEANUP=1 make test-e2e-local`
	./test/e2e/local.sh

.PHONY: test-e2e-ci
test-e2e-ci: ## Run the end-to-end tests (used in the CI)`
	./test/e2e/ci.sh

.PHONY: test-book
test-book: ## Run the cronjob tutorial's unit tests to make sure we don't break it
	cd ./docs/book/src/cronjob-tutorial/testdata/project && make test
	cd ./docs/book/src/multiversion-tutorial/testdata/project && make test
	cd ./docs/book/src/getting-started/testdata/project && make test

.PHONY: test-license
test-license:  ## Run the license check
	./test/check-license.sh

.PHONY: test-gomod
test-gomod:  ## Run the Go module compatibility check
	go run ./hack/test/check_go_module.go

.PHONY: test-external-plugin
test-external-plugin: install  ## Run tests for external plugin
	make -C docs/book/src/simple-external-plugin-tutorial/testdata/sampleexternalplugin/v1 install
	make -C docs/book/src/simple-external-plugin-tutorial/testdata/sampleexternalplugin/v1 test-plugin

.PHONY: test-spaces
test-spaces:  ## Run the trailing spaces check
	./test/check_spaces.sh

## TODO: Remove me when go/v4 plugin be removed
## Deprecated
.PHONY: test-legacy
test-legacy:  ## Run the tests to validate legacy path for webhooks
	rm -rf  ./testdata/**legacy**/
	./test/testdata/legacy-webhook-path.sh

.PHONY: install-helm
install-helm: ## Install the latest version of Helm locally
	@curl -fsSL https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-4 | bash

.PHONY: helm-lint
helm-lint: install-helm ## Lint the Helm chart in testdata
	helm lint testdata/project-v4-with-plugins/dist/chart

## Tool Binaries
GO_APIDIFF ?= $(LOCALBIN)/go-apidiff
GOLANGCI_LINT ?= $(LOCALBIN)/golangci-lint

## Tool Versions
GO_APIDIFF_VERSION ?= v0.8.3
GOLANGCI_LINT_VERSION ?= v2.8.0

# go-install-tool will 'go install' any package with custom target and name of binary, if it doesn't exist
# $1 - target path with name of binary
# $2 - package url which can be installed
# $3 - specific version of package
define go-install-tool
@[ -f "$(1)-$(3)" ] && [ "$$(readlink -- "$(1)" 2>/dev/null)" = "$(1)-$(3)" ] || { \
set -e; \
package=$(2)@$(3) ;\
echo "Downloading $${package}" ;\
rm -f $(1) ;\
GOBIN=$(LOCALBIN) go install $${package} ;\
mv $(1) $(1)-$(3) ;\
} ;\
ln -sf $$(realpath $(1)-$(3)) $(1)
endef


================================================
FILE: OWNERS
================================================
# See the OWNERS docs: https://git.k8s.io/community/contributors/guide/owners.md

approvers:
  - kubebuilder-admins
  - kubebuilder-approvers
reviewers:
  - kubebuilder-admins
  - kubebuilder-reviewers
  - kubebuilder-approvers


================================================
FILE: OWNERS_ALIASES
================================================
# See the OWNERS docs: https://git.k8s.io/community/contributors/guide/owners.md

aliases:
  # active folks who can be contacted to perform admin-related
  # tasks on the repo, or otherwise approve any PRs.
  kubebuilder-admins:
    - camilamacedo86
    - varshaprasad96

  # non-admin folks who can approve any PRs in the repo
  # kubebuilder-approvers:

  # folks who can review and LGTM any PRs in the repo (doesn't include
  # approvers & admins -- those count too via the OWNERS file)
  kubebuilder-reviewers:
    - vitorfloriano

  # folks who may have context on ancient history,
  # but are no longer directly involved
  kubebuilder-emeritus-approvers:
  - adirio
  - directxman12
  - droot
  - estroz
  - jmrodri
  - joelanford
  - Kavinjsir
  - mengqiy
  - pwittrock

  kubebuilder-emeritus-reviewers:
  - everettraven
  - rashmigottipati


================================================
FILE: README.md
================================================
[![OpenSSF Scorecard](https://api.scorecard.dev/projects/github.com/kubernetes-sigs/kubebuilder/badge)](https://scorecard.dev/viewer/?uri=github.com/kubernetes-sigs/kubebuilder)
[![Lint](https://github.com/kubernetes-sigs/kubebuilder/actions/workflows/lint.yml/badge.svg)](https://github.com/kubernetes-sigs/kubebuilder/actions/workflows/lint.yml)
[![Go Report Card](https://goreportcard.com/badge/sigs.k8s.io/kubebuilder)](https://goreportcard.com/report/sigs.k8s.io/kubebuilder)
[![Coverage Status](https://coveralls.io/repos/github/kubernetes-sigs/kubebuilder/badge.svg?branch=master)](https://coveralls.io/github/kubernetes-sigs/kubebuilder?branch=master)
[![Latest release](https://img.shields.io/github/v/release/kubernetes-sigs/kubebuilder)](https://github.com/kubernetes-sigs/kubebuilder/releases)
[![Go Reference](https://pkg.go.dev/badge/sigs.k8s.io/kubebuilder/v4.svg)](https://pkg.go.dev/sigs.k8s.io/kubebuilder/v4)

## Kubebuilder

Kubebuilder is a framework for building Kubernetes APIs using [custom resource definitions (CRDs)](https://kubernetes.io/docs/tasks/access-kubernetes-api/extend-api-custom-resource-definitions).

Similar to web development frameworks such as *Ruby on Rails* and *SpringBoot*,
Kubebuilder increases velocity and reduces the complexity managed by
developers for rapidly building and publishing Kubernetes APIs in Go.
It builds on top of the canonical techniques used to build the core Kubernetes APIs to provide simple abstractions that reduce boilerplate and toil.

Kubebuilder does **not** exist as an example to *copy-paste*, but instead provides powerful libraries and tools
to simplify building and publishing Kubernetes APIs from scratch. It
provides a plugin architecture allowing users to take advantage of optional helpers
and features. To learn more about this see the [Plugin section][plugin-section].

Kubebuilder is developed on top of the [controller-runtime][controller-runtime] and [controller-tools][controller-tools] libraries.

### Kubebuilder is also a library

Kubebuilder is extensible and can be used as a library in other projects.
[Operator-SDK][operator-sdk] is a good example of a project that uses Kubebuilder as a library.
[Operator-SDK][operator-sdk] uses the plugin feature to include non-Go operators _e.g. operator-sdk's Ansible and Helm-based language Operators_.

To learn more see [how to create your own plugins][your-own-plugins].

### Installation

It is strongly recommended that you use a released version. Release binaries are available on the [releases](https://github.com/kubernetes-sigs/kubebuilder/releases) page.
Follow the [instructions](https://book.kubebuilder.io/quick-start.html#installation) to install Kubebuilder.

## Getting Started

See the [Getting Started](https://book.kubebuilder.io/quick-start.html) documentation.

Also, ensure that you check out the [Deploy Image](./docs/book/src/plugins/available/deploy-image-plugin-v1-alpha.md)
Plugin. This plugin allows users to scaffold API/Controllers to deploy and manage an
Operand (image) on the cluster following the guidelines and best practices. It abstracts the
complexities of achieving this goal while allowing users to customize the generated code.

## Documentation

Check out the Kubebuilder [book](https://book.kubebuilder.io).

## Resources

- Kubebuilder Book: [book.kubebuilder.io](https://book.kubebuilder.io)
- GitHub Repo: [kubernetes-sigs/kubebuilder](https://github.com/kubernetes-sigs/kubebuilder)
- Slack channel: [#kubebuilder](https://kubernetes.slack.com/messages/#kubebuilder)
- Google Group: [kubebuilder@googlegroups.com](https://groups.google.com/forum/#!forum/kubebuilder)
- Design Documents: [designs](designs/)
- Plugin: [plugins][plugin-section]

## Motivation

Building Kubernetes tools and APIs involves making a lot of decisions and writing a lot of boilerplate.

To facilitate easily building Kubernetes APIs and tools using the canonical approach, this framework
provides a collection of Kubernetes development tools to minimize toil.

Kubebuilder attempts to facilitate the following developer workflow for building APIs

1. Create a new project directory
2. Create one or more resource APIs as CRDs and then add fields to the resources
3. Implement reconcile loops in controllers and watch additional resources
4. Test by running against a cluster (self-installs CRDs and starts controllers automatically)
5. Update bootstrapped integration tests to test new fields and business logic
6. Build and publish a container from the provided Dockerfile

## Scope

Building APIs using CRDs, Controllers, and Admission Webhooks.

## Philosophy

See [DESIGN.md](DESIGN.md) for the guiding principles of the various Kubebuilder projects.

TL;DR:

Provide clean library abstractions with clear and well-exampled go docs.

- Prefer using go *interfaces* and *libraries* over-relying on *code generation*
- Prefer using *code generation* over *1 time init* of stubs
- Prefer *1 time init* of stubs over forked and modified boilerplate
- Never fork and modify boilerplate

## Techniques

- Provide higher-level libraries on top of low-level client libraries
  - Protect developers from breaking changes in low-level libraries
  - Start minimal and provide progressive discovery of functionality
  - Provide sane defaults and allow users to override when they exist
- Provide code generators to maintain common boilerplate that can't be addressed by interfaces
  - Driven off of `// +` comments
- Provide bootstrapping commands to initialize new packages

## Versioning and Releasing

See [VERSIONING.md](VERSIONING.md).

## Troubleshooting

- ### Bugs and Feature Requests:
  If you have what looks like a bug, or you would like to make a feature request, please use the [Github issue tracking system.](https://github.com/kubernetes-sigs/kubebuilder/issues)
Before you file an issue, please search existing issues to see if your issue is already covered.

- ### Slack
  For real-time discussion,  you can join the [#kubebuilder](https://slack.k8s.io/#kubebuilder) slack channel. Slack requires registration, but the Kubernetes team is an open invitation to anyone to register here. Feel free to come and ask any questions.

## Contributing

Contributions are greatly appreciated. The maintainers actively manage the issues list and try to highlight issues suitable for newcomers.
The project follows the typical GitHub pull request model. See [CONTRIBUTING.md](CONTRIBUTING.md) for more details.
Before starting any work, please either comment on an existing issue or file a new one.

## Operating Systems Supported

Currently, Kubebuilder officially supports macOS and Linux platforms. If you are using a Windows OS, we recommend you read the instructions in [here](docs/windows.md).

Contributions towards supporting Windows are not planned.

## Versions Compatibility and Supportability

Projects created by Kubebuilder contain a `Makefile` that installs tools at versions defined during project creation. The main tools included are:

- [kustomize](https://github.com/kubernetes-sigs/kustomize)
- [controller-gen](https://github.com/kubernetes-sigs/controller-tools)
- [setup-envtest](https://github.com/kubernetes-sigs/controller-runtime/tree/main/tools/setup-envtest)

Additionally, these projects include a `go.mod` file specifying dependency versions.
Kubebuilder relies on [controller-runtime](https://github.com/kubernetes-sigs/controller-runtime) and its Go and Kubernetes dependencies.
Therefore, the versions defined in the `Makefile` and `go.mod` files are the ones that have been tested, supported, and recommended.

Each minor version of Kubebuilder is tested with a specific minor version of the client-go.
While a Kubebuilder minor version *may* be compatible with other client-go minor versions,
or other tools this compatibility is not guaranteed, supported, or tested.

The minimum Go version required by Kubebuilder is determined by the highest minimum
Go version required by its dependencies. This is usually aligned with the minimum
Go version required by the corresponding `k8s.io/*` dependencies.

Compatible `k8s.io/*` versions, client-go versions, and minimum Go versions can be found in the `go.mod`
file scaffolded for each project for each [tag release](https://github.com/kubernetes-sigs/kubebuilder/tags).

**Example:** For the `4.1.1` release, the minimum Go version compatibility is `1.22`.
You can refer to the samples in the testdata directory of the tag released [v4.1.1](https://github.com/kubernetes-sigs/kubebuilder/tree/v4.1.1/testdata),
such as the [go.mod](https://github.com/kubernetes-sigs/kubebuilder/blob/v4.1.1/testdata/project-v4/go.mod#L3) file for `project-v4`. You can also check the versions of the tools supported and
tested for this release by examining the [Makefile](https://github.com/kubernetes-sigs/kubebuilder/blob/v4.1.1/testdata/project-v4/Makefile#L160-L165).

## Community Meetings

The following meetings happen biweekly:

- Kubebuilder Meeting

You are more than welcome to attend. For further info join to [kubebuilder@googlegroups.com](https://groups.google.com/g/kubebuilder).
Every month, our team meets on the first Thursday at 11:00 PT (Pacific Time) to discuss our progress and plan for the upcoming weeks.
Please note that we have been syncing more frequently offline via Slack lately. However, if you add a topic to the agenda, we will hold the meeting as scheduled.
Additionally, we can use this channel to demonstrate new features.

[operator-sdk]: https://github.com/operator-framework/operator-sdk
[plugin-section]: https://book.kubebuilder.io/plugins/plugins.html
[controller-runtime]: https://github.com/kubernetes-sigs/controller-runtime
[your-own-plugins]: https://book.kubebuilder.io/plugins/extending
[controller-tools]: https://github.com/kubernetes-sigs/controller-tools


================================================
FILE: RELEASE.md
================================================
# Release Process

The Kubebuilder Project is released on an as-needed basis. The process is as follows:

**Note:** Releases are done from the `release-MAJOR.MINOR` branches. For PATCH releases it is not required
to create a new branch. Instead, you will just need to ensure that all major fixes are cherry-picked into the respective
`release-MAJOR.MINOR` branch. To know more about versioning, check https://semver.org/.

**Note:** Before `3.5.*` release this project was released based on `MAJOR`. A change to the
process was done to ensure that we have an aligned process under the org (similar to `controller-runtime` and
`controller-tools`) and to make it easier to produce patch releases.

## How to do a release

### Create the new branch and the release tag

1. Create a new branch `git checkout -b release-<MAJOR.MINOR>` from master
2. Push the new branch to the remote repository

### Now, let's generate the changelog

1. Create the changelog from the new branch `release-<MAJOR.MINOR>` (`git checkout release-<MAJOR.MINOR>`).
   You will need to use the [kubebuilder-release-tools][kubebuilder-release-tools] to generate release notes. See [here][release-notes-generation]

> **Note**
> - You will need to have checkout locally from the remote repository the previous branch
> - Also, ensure that you fetch all tags from the remote `git fetch --all --tags`
> - Also, if you face issues to generate the release notes you might want to able to sort it out by running i.e.:
> `go run sigs.k8s.io/kubebuilder-release-tools/notes --use-upstream=false --from=v3.11.0 --branch=release-X`


### Draft a new release from GitHub

1. Create a new tag with the correct version from the new `release-<MAJOR.MINOR>` branch
2. Verify the Release Github Action. It should build the assets and publish in the draft release
3. You also need to manually add the changelog generated above on the release page and publish it. Now, the source code is released!

### Update the website docs (https://book.kubebuilder.io/quick-start.html)

1. Push a PR to update the `book-v3` branch with the changes of the latest release branch created (`release-<MAJOR.MINOR>`)
2. Ping in the [Kubebuilder Slack channel](https://kubernetes.slack.com/archives/CAR30FCJZ) and ask for reviews.

### When the release be done and the website update: Announce the new release:

1. Announce the new release on the Slack channel, i.e:

````
:announce: Kubebuilder v3.5.0 has been released!
This release includes a Kubernetes dependency bump to v1.24.
For more info, see the release page: https://github.com/kubernetes-sigs/kubebuilder/releases/tag/v3.5.0
 :tada:  Thanks to all our contributors!
````

2. Announce the new release via email is sent to `kubebuilder@googlegroups.com` with the subject `[ANNOUNCE] Kubebuilder $VERSION is released`


## HEAD releases

The binaries releases for HEAD are available here:

- [kubebuilder-release-master-head-darwin-amd64.tar.gz](https://storage.googleapis.com/kubebuilder-release/kubebuilder-release-master-head-darwin-amd64.tar.gz)
- [kubebuilder-release-master-head-linux-amd64.tar.gz](https://storage.googleapis.com/kubebuilder-release/kubebuilder-release-master-head-linux-amd64.tar.gz)

## How the releases are configured

The releases occur in an account in the Google Cloud (See [here](https://console.cloud.google.com/cloud-build/builds?project=kubebuilder)) using Cloud Build.

### To build the Kubebuilder CLI binaries:

A trigger GitHub action [release](.github/workflows/release.yml) is trigged when a new tag is pushed.
This action will call the job [./build/.goreleaser.yml](./build/.goreleaser.yml).

###  (Deprecated) - To build the Kubebuilder-tools: (Artifacts required to use ENV TEST)

> We no longer build the artifacts and the promotion of those is deprecated. For more info
see: https://github.com/kubernetes-sigs/kubebuilder/discussions/4082

Kubebuilder projects requires artifacts which are used to do test with ENV TEST (when we call `make test` target)
These artifacts can be checked in the service page: https://storage.googleapis.com/kubebuilder-tools

The build is made from the branch [tools-releases](https://github.com/kubernetes-sigs/kubebuilder/tree/tools-releases) and the trigger will call the `build/cloudbuild_tools.yaml` passing
as argument the architecture and the OS that should be used, e.g:

<img width="553" alt="Screenshot 2022-04-30 at 10 15 41" src="https://user-images.githubusercontent.com/7708031/166099666-ae9cd2df-73fe-47f6-a987-464f63df9a19.png">

For further information see the [README](https://github.com/kubernetes-sigs/kubebuilder/blob/tools-releases/README.md).

### (Deprecated) - To build the `kube-rbac-proxy` images:

> We no longer build the images and the promotion of those images is deprecated. For more info
see: https://github.com/kubernetes-sigs/kubebuilder/discussions/3907

These images are built from the project [brancz/kube-rbac-proxy](https://github.com/brancz/kube-rbac-proxy).
The projects built with Kubebuilder creates a side container with `kube-rbac-proxy` to protect the Manager.

These images can be checked in the console, see [here](https://console.cloud.google.com/gcr/images/kubebuilder/GLOBAL/kube-rbac-proxy).

The project `kube-rbac-proxy` is in the process to be donated to the k8s org. However, it is going on for a long time and then,
we have no ETA for that to occur. When that occurs we can automate this process. But until there we need to generate these images
by bumping the versions/tags released by `kube-rbac-proxy` on the branch
[kube-rbac-proxy-releases](https://github.com/kubernetes-sigs/kubebuilder/tree/kube-rbac-proxy-releases)
then the `build/cloudbuild_kube-rbac-proxy.yaml` will generate the images.

To check an example, see the pull request [#2578](https://github.com/kubernetes-sigs/kubebuilder/pull/2578).

**Note**: we cannot use the images produced by the project `kube-rbac-proxy` because we need to ensure
to Kubebuilder users that these images will be available.

### (Deprecated) - To build the `gcr.io/kubebuilder/pr-verifier` images:

> We are working on to move all out from GCP Kubebuilder project. For further information see: https://github.com/kubernetes/k8s.io/issues/2647#issuecomment-2111182864

These images are used to verify the PR title and description. They are built from [kubernetes-sigs/kubebuilder-release-tools](https://github.com/kubernetes-sigs/kubebuilder-release-tools/).
In Kubebuilder, we have been using this project via the GitHub action [.github/workflows/verify.yml](.github/workflows/verify.yml)
and not the image, see:

```yaml
  verify:
    name: Verify PR contents
    runs-on: ubuntu-latest
    steps:
    - name: Verifier action
      id: verifier
      uses: kubernetes-sigs/kubebuilder-release-tools@v0.1.1
      with:
        github_token: ${{ secrets.GITHUB_TOKEN }}
```

However, the image should still be built and maintained since other projects under the org might be using them.

[kubebuilder-release-tools]: https://github.com/kubernetes-sigs/kubebuilder-release-tools
[release-notes-generation]: https://github.com/kubernetes-sigs/kubebuilder-release-tools/blob/master/README.md#release-notes-generation
[release-process]: https://github.com/kubernetes-sigs/kubebuilder/blob/master/VERSIONING.md#releasing


================================================
FILE: SECURITY_CONTACTS
================================================
# Defined below are the security contacts for this repo.
#
# They are the contact point for the Product Security Team to reach out
# to for triaging and handling of incoming issues.
#
# The below names agree to abide by the
# [Embargo Policy](https://github.com/kubernetes/sig-release/blob/master/security-release-process-documentation/security-release-process.md#embargo-policy)
# and will be removed and replaced if they violate that agreement.
#
# DO NOT REPORT SECURITY VULNERABILITIES DIRECTLY TO THESE NAMES, FOLLOW THE
# INSTRUCTIONS AT https://kubernetes.io/security/

camilamacedo86
varshaprasad96


================================================
FILE: VERSIONING.md
================================================
# Versioning and Releasing for Kubebuilder

We (mostly) follow the [common Kubebuilder versioning
guidelines][guidelines], and use the corresponding tooling and PR process
described there.

For the purposes of the aforementioned guidelines, Kubebuilder counts as
a "CLI project".

[guidelines]: https://sigs.k8s.io/kubebuilder-release-tools/VERSIONING.md

## Compatibility

Note that we generally do not support older release branches, except in
extreme circumstances.

Bear in mind that changes to scaffolding generally constitute breaking
changes -- see [below](#understanding-the-versions) for more details.

## Releasing

When releasing, you'll need to:

- to update references in [the build directory](build/) to the latest
  version of the [envtest tools](#tools-releases) **before tagging the
  release.**

- reset the book branch: see [below](#book-releases)

You may also want to check that the book is generating the marker docs off
the latest controller-tools release.  That info is stored in
[docs/book/install-and-build.sh](/docs/book/install-and-build.sh).

## Book Releases

The book's main version (https://book.kubebuilder.io) is published off of
the [book-v3][book-branch] (a version built off the main branch can be
found at https://master.book.kubebuilder.io).

Docs changes that aren't specific to a new feature should be
cherry-picked to the aforementioned branch to get them to be published.
The cherry-picks will automatically be published to the book once their PR
merges.

**When you publish a Kubebuilder release**, be sure to also submit a PR
that merges the main branch into [book-v3][book-branch], so that it
describes the latest changes in the new release.

[book-branch]: https://github.com/kubernetes-sigs/kubebuilder/tree/tools-releases

## Tools Releases

In order to update the [envtest tools][envtest-ref], you'll need to do an
update to the [tools-releases branch][tools-branch].  Simply submit a PR
against that branch that changes all references to the current version to
the desired next version.  Once the PR is merged, Google Cloud Build will
take care of building and publishing the artifacts.

[envtest-ref]: https://book.kubebuilder.io/reference/artifacts.html
[tools-branch]: https://github.com/kubernetes-sigs/kubebuilder/tree/tools-releases
[kb-releases]:https://github.com/kubernetes-sigs/kubebuilder/releases
[cli-plugins-versioning]:docs/book/src/plugins/extending#plugin-versioning


================================================
FILE: build/.goreleaser.yml
================================================
#  Copyright 2020 The Kubernetes Authors.
#
#  Licensed under the Apache License, Version 2.0 (the "License");
#  you may not use this file except in compliance with the License.
#  You may obtain a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
#  Unless required by applicable law or agreed to in writing, software
#  distributed under the License is distributed on an "AS IS" BASIS,
#  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
#  See the License for the specific language governing permissions and
#  limitations under the License.

# This is a GoReleaser configuration file for Kubebuilder release.
# Make sure to check the documentation at http://goreleaser.com

# Global environment variables that are needed for hooks and builds.
version: 2

env:
  - GO111MODULE=on

# Hooks to run before any build is run.
before:
  hooks:
    - go mod download

# Build a binary for each target in targets.
builds:
  - id: kubebuilder
    binary: kubebuilder
    mod_timestamp: "{{ .CommitTimestamp }}"
    targets:
      - linux_amd64
      - linux_arm64
      - linux_ppc64le
      - linux_s390x
      - darwin_amd64
      - darwin_arm64
    env:
      - CGO_ENABLED=0

# Only binaries of the form "kubebuilder_${goos}_${goarch}" will be released.
archives:
  - formats: ['binary']
    # Setting name_template correctly maps checksums to binary names.
    name_template: "{{ .Binary }}_{{ .Os }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}{{ if .Mips }}_{{ .Mips }}{{ end }}"

# Checksum all binaries.
checksum:
  name_template: "checksums.txt"

# kubebuilder uses a custom changelog, so leave this empty.
changelog:

# github.com/kubernetes-sigs/kubebuilder
release:
  github:
    owner: kubernetes-sigs
    name: kubebuilder

# Add the SBOM configuration at the end to generate SBOM files
sboms:
  - id: kubebuilder-sbom
    artifacts: binary
    cmd: syft
    args: ["$artifact", "--output", "cyclonedx-json=$document"]
    documents:
      - "{{ .Binary }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}.cyclonedx.sbom.json"


================================================
FILE: code-of-conduct.md
================================================
# Kubernetes Community Code of Conduct

Please refer to our [Kubernetes Community Code of Conduct](https://git.k8s.io/community/code-of-conduct.md)

================================================
FILE: designs/README.md
================================================
Designs
=======

These are design documents for changes to Kubebuilder (and
cross-repository changes for related projects, like controller-runtime and
controller-tools). They exist to help document the design processes that
go into writing Kubebuilder, but may not be up-to-date (more below).

Not all changes to Kubebuilder need a design document -- only major ones.
Use your best judgement.

When submitting a design document, we encourage having written
a proof-of-concept, and it's perfectly acceptable to submit the
proof-of-concept PR simultaneously with the design document, as the
proof-of-concept process can help iron out wrinkles and can help with the
`Example` section of the template.

## Out-of-Date Designs

**Kubebuilder documentation (the [book](https://book.kubebuilder.io) and
the [GoDoc](https://pkg.go.dev/sigs.k8s.io/controller-runtime?tab=doc)) should be
considered the canonical, update-to-date reference and architectural
documentation** for Kubebuilder.

However, if you see an out-of-date design document, feel free to submit
a PR marking it as such, and add an addendum linking to issues documenting
why things changed.  For example:

```markdown

# Out of Date

This change is out of date.  It turns out curly braces are frustrating to
type, so we had to abandon functions entirely, and have users specify
custom functionality using strings of Common LISP instead.  See #000 for
more information.
```


================================================
FILE: designs/code-generate-image-plugin.md
================================================
| Authors       | Creation Date | Status      | Extra |
|---------------|---------------|-------------|---|
| @camilamacedo86 | 2021-02-14 | Implemented | [deploy-image-plugin-v1-alpha](../docs/book/src/plugins/available/deploy-image-plugin-v1-alpha.md) |

# New Plugin (`deploy-image.go.kubebuilder.io/v1beta1`) to generate code

## Summary

This proposal defines a new plugin that allows users to get the scaffold with the
 required code to have a project that will deploy and manage an image on the cluster following the guidelines and what have been considered as good practices.

## Motivation

The biggest part of the Kubebuilder users looking for to create a project that will at the end only deploy an image. In this way, one of the  mainly motivations of this proposal is to abstract the complexities to achieve this goal and still giving the possibility of users improve and customize their projects according to their requirements.

**Note:** This plugin will address requests that has been raised for a while and for many users in the community. Check [here](https://github.com/operator-framework/operator-sdk/pull/2158), for example, a request done in the past for the SDK project which is integrated with Kubebuidler to address the same need.

### Goals

- Add a new plugin to generate the code required to deploy and manage an image on the cluster
- Promote the best practices by giving examples of common implementations
- Make the process of developing  operator's projects easier and more agile.
- Give flexibility to the users and allow them to change the code according to their needs
- Provide examples of code implementations and of the usage of the most common features and reduce the learning curve

### Non-Goals

The idea of this proposal is to provide a facility for the users. This plugin can be improved
in the future, however, this proposal just covers the basic requirements. In this way, is a non-goal
allow extra configurations such as; scaffolding the project using webhooks and the controller covered by tests.

## Proposal

Add the new plugin code generated which will scaffold code implementation to deploy the image informed which would like such as; `kubebuilder create api --group=crew --version=v1 --image=myexample:0.0.1 --kind=App --plugins=deploy-image.go.kubebuilder.io/v1beta1` which will:

- Add a code implementation that will do the Custom Resource reconciliation and create a Deployment resource for the `--image`;

- Add an EnvVar on the manager manifest (`config/manager/manager.yaml`) which will store the image informed and show its possibility to users:

```yaml
    ..
    spec:
      containers:
        - name: manager
          env:
            - name: {{ resource}}-IMAGE
              value: {{image:tag}}
          image: controller:latest
      ...
```

- Add a check into reconcile to ensure that the replicas of the deployment on the cluster are equal the size defined in the CR:

```go
	// Ensure the deployment size is the same as the spec
	size := {{ resource }}.Spec.Size
	if *found.Spec.Replicas != size {
		found.Spec.Replicas = &size
		err = r.Update(ctx, found)
		if err != nil {
			log.Error(err, "Failed to update Deployment", "Deployment.Namespace", found.Namespace, "Deployment.Name", found.Name)
			return ctrl.Result{}, err
		}
		// Spec updated - return and requeue
		return ctrl.Result{Requeue: true}, nil
	}
```

- Add the watch feature for the Deployment managed by the controller:

```go
func (r *{{ resource }}Reconciler) SetupWithManager(mgr ctrl.Manager) error {
	return ctrl.NewControllerManagedBy(mgr).
		For(&cachev1alpha1.{{ resource }}{}).
		Owns(&appsv1.Deployment{}).
		Complete(r)
}
```

- Add the RBAC permissions required for the scenario such as:

```go
// +kubebuilder:rbac:groups=apps,resources=deployments,verbs=get;list;watch;create;update;patch;delete
```

- A status [conditions][conditions] to allow users to check if the deployment occurred successfully or if its errors

- Add a [marker][markers] in the spec definition to demonstrate how to use OpenAPI schemas validation such as `+kubebuilder:validation:Minimum=1`

- Add the specs on the `_types.go` to generate the CRD/CR sample with default values for `ImagePullPolicy` (`Always`), `ContainerPort` (`80`) and the `Replicas Size` (`3`)

- Add a finalizer implementation with TODO for the CR managed by the controller such as described in the SDK doc [Handle Cleanup on Deletion](https://sdk.operatorframework.io/docs/building-operators/golang/advanced-topics/#handle-cleanup-on-deletion)

### User Stories

- I am a user, who would like to use a command to scaffold my common need which is to deploy an image of my application, so that I do not need to know exactly how to implement it

- I am a user, would like to have a good example code base that uses the common features so that I can easily learn its concepts and have a good starting point to address my needs.

- I am as maintainer, would like to have a good example to address the common questions, so that I can easily describe how to implement the projects and/or use the common features.

### Implementation Details/Notes/Constraints

**Example of the controller template**

```go
// +kubebuilder:rbac:groups=cache.example.com,resources={{ resource.plural }},verbs=get;list;watch;create;update;patch;delete
// +kubebuilder:rbac:groups=cache.example.com,resources={{ resource.plural }}/status,verbs=get;update;patch
// +kubebuilder:rbac:groups=cache.example.com,resources={{ resource.plural }}/finalizers,verbs=update
// +kubebuilder:rbac:groups=apps,resources=deployments,verbs=get;list;watch;create;update;patch;delete

func (r *{{ resource }}.Reconciler) Reconcile(req ctrl.Request) (ctrl.Result, error) {
	ctx := context.Background()
	log := r.Log.WithValues("{{ resource }}", req.NamespacedName)

	// Fetch the {{ resource }} instance
	{{ resource }} := &{{ apiimportalias }}.{{ resource }}{}
	err := r.Get(ctx, req.NamespacedName, {{ resource }})
	if err != nil {
		if errors.IsNotFound(err) {
			// Request object not found, could have been deleted after reconcile request.
			// Owned objects are automatically garbage collected. For additional cleanup logic use finalizers.
			// Return and don't requeue
			log.Info("{{ resource }} resource not found. Ignoring since object must be deleted")
			return ctrl.Result{}, nil
		}
		// Error reading the object - requeue the request.
		log.Error(err, "Failed to get {{ resource }}")
		return ctrl.Result{}, err
	}

	// Check if the deployment already exists, if not create a new one
	found := &appsv1.Deployment{}
	err = r.Get(ctx, types.NamespacedName{Name: {{ resource }}.Name, Namespace: {{ resource }}.Namespace}, found)
	if err != nil && errors.IsNotFound(err) {
		// Define a new deployment
		dep := r.deploymentFor{{ resource }}({{ resource }})
		log.Info("Creating a new Deployment", "Deployment.Namespace", dep.Namespace, "Deployment.Name", dep.Name)
		err = r.Create(ctx, dep)
		if err != nil {
			log.Error(err, "Failed to create new Deployment", "Deployment.Namespace", dep.Namespace, "Deployment.Name", dep.Name)
			return ctrl.Result{}, err
		}
		// Deployment created successfully - return and requeue
		return ctrl.Result{Requeue: true}, nil
	} else if err != nil {
		log.Error(err, "Failed to get Deployment")
		return ctrl.Result{}, err
	}

	// Ensure the deployment size is the same as the spec
	size := {{ resource }}.Spec.Size
	if *found.Spec.Replicas != size {
		found.Spec.Replicas = &size
		err = r.Update(ctx, found)
		if err != nil {
			log.Error(err, "Failed to update Deployment", "Deployment.Namespace", found.Namespace, "Deployment.Name", found.Name)
			return ctrl.Result{}, err
		}
		// Spec updated - return and requeue
		return ctrl.Result{Requeue: true}, nil
	}

    // TODO: add here code implementation to update/manage the status

	return ctrl.Result{}, nil
}

// deploymentFor{{ resource }} returns a {{ resource }} Deployment object
func (r *{{ resource }}Reconciler) deploymentFor{{ resource }}(m *{{ apiimportalias }}.{{ resource }}) *appsv1.Deployment {
	ls := labelsFor{{ resource }}(m.Name)
	replicas := m.Spec.Size

	dep := &appsv1.Deployment{
		ObjectMeta: metav1.ObjectMeta{
			Name:      m.Name,
			Namespace: m.Namespace,
		},
		Spec: appsv1.DeploymentSpec{
			Replicas: &replicas,
			Selector: &metav1.LabelSelector{
				MatchLabels: ls,
			},
			Template: corev1.PodTemplateSpec{
				ObjectMeta: metav1.ObjectMeta{
					Labels: ls,
				},
				Spec: corev1.PodSpec{
					Containers: []corev1.Container{{
						Image:   imageFor{{ resource }}(m.Name),
						Name:    {{ resource }},
                        ImagePullPolicy: {{ resource }}.Spec.ContainerImagePullPolicy,
						Command: []string{"{{ resource }}"},
						Ports: []corev1.ContainerPort{{
							ContainerPort: {{ resource }}.Spec.ContainerPort,
							Name:          "{{ resource }}",
						}},
					}},
				},
			},
		},
	}
	// Set {{ resource }} instance as the owner and controller
	ctrl.SetControllerReference(m, dep, r.Scheme)
	return dep
}

// labelsFor{{ resource }} returns the labels for selecting the resources
// belonging to the given {{ resource }} CR name.
func labelsFor{{ resource }}(name string) map[string]string {
	return map[string]string{"type": "{{ resource }}", "{{ resource }}_cr": name}
}

// imageFor{{ resource }} returns the image for the resources
// belonging to the given {{ resource }} CR name.
func imageFor{{ resource }}(name string) string {
	// TODO: this method will return the value of the envvar create to store the image:tag informed
}

func (r *{{ resource }}Reconciler) SetupWithManager(mgr ctrl.Manager) error {
	return ctrl.NewControllerManagedBy(mgr).
		For(&cachev1alpha1.{{ resource }}{}).
		Owns(&appsv1.Deployment{}).
		Complete(r)
}

```

**Example of the spec for the <kind>_types.go template**

```go
// {{ resource }}Spec defines the desired state of {{ resource }}
type {{ resource }}Spec struct {
	// INSERT ADDITIONAL SPEC FIELDS - desired state of cluster
	// Important: Run "make" to regenerate code after modifying this file

    // +kubebuilder:validation:Minimum=1
	// Size defines the number of {{ resource }} instances
	Size int32 `json:"size,omitempty"`

    // ImagePullPolicy defines the policy to pull the container images
	ImagePullPolicy string `json:"image-pull-policy,omitempty"`

    // ContainerPort specifies the port which will be used by the image container
	ContainerPort int `json:"container-port,omitempty"`

}
```

## Design Details

### Test Plan

To ensure this implementation a new project example should be generated in the [testdata](../testdata/) directory of the project. See the [test/testdata/generate.sh](../test/testadata/generate.sh). Also, we should use this scaffold in the [integration tests](../test/e2e/) to ensure that the data scaffold works on the cluster as expected.

### Graduation Criteria

- The new plugin will only support `project-version=3`
- The attribute image with the value informed should be added to the resources model in the PROJECT file to let the tool know that the Resource gets done with the common basic code implementation:

```yaml
plugins:
    deploy-image.go.kubebuilder.io/v1beta1:
        resources:
          - domain: example.io
            group: crew
            kind: Captain
            version: v1
            image: "<some-registry>/<project-name>:<tag>
```

For further information check the definition agreement register in the comment https://github.com/kubernetes-sigs/kubebuilder/issues/1941#issuecomment-778649947.

## Open Questions

1. Should we allow to scaffold the code for an API that is already created for the project?
No, at least in the first moment to keep the simplicity.

2. Should we support StatefulSet and Deployments?
The idea is we start it by using a Deployment. However, we can improve the feature in follow-ups to support more default types of scaffolds which could be like `kubebuilder create api --group=crew --version=v1 --image=myexample:0.0.1 --kind=App --plugins=deploy-image.go.kubebuilder.io/v1beta1 --type=[deployment|statefulset|webhook]`

3. Could this feature be useful to other languages or is it just valid to Go-based operators?

This plugin would is reponsable to scaffold content and files for Go-based operators. In a future, if other language-based operators starts to be supported (either officially or by the community) this plugin could be used as reference to create an equivalent one for their languages. Therefore, it should probably not to be a `subdomain` of `go.kubebuilder.io.`

For its integration with SDK, it might be valid for the Ansible-based operators where a new `playbook/role` could be generated as well. However, for example,for  the Helm plugin, it might be useless. E.g `deploy-image.ansible.sdk.operatorframework.io/v1beta1`

4. Should we consider creating a separate repo for plugins?

In the long term yes. However, see that currently, Kubebuilder does not have too many plugins yet. And then, the preliminary support for plugins was not indeed released. For more info see the [Extensible CLI and Scaffolding Plugins][plugins-phase1-design-doc].

In this way, at this moment, it shows to be a little Premature Optimization. Note that the issue [#2016](https://github.com/kubernetes-sigs/kubebuilder/issues/1378) will check the possibility of the plugins be as separate binaries that can be discovered by the Kubebuilder CLI binary via user-specified plugin file paths. Then, the discussion over the best approach to dealing with many plugins and if they should or not leave in the Kubebuilder repository would be better addressed after that.

5. Is Kubebuilder prepared to receive this implementation already?

The [Extensible CLI and Scaffolding Plugins - Phase 1.5](extensible-cli-and-scaffolding-plugins-phase-1-5.md) and issue #1941 are required to be implemented before this proposal. Also, to have a better idea of the proposed solutions made so for the Plugin Ecosystem see the meta issue [#2016](https://github.com/kubernetes-sigs/kubebuilder/issues/2016)

[markers]: ../docs/book/src/reference/markers.md
[conditions]: https://github.com/kubernetes/community/blob/master/contributors/devel/sig-architecture/api-conventions.md#typical-status-properties
[plugins-phase1-design-doc]: https://github.com/kubernetes-sigs/kubebuilder/blob/master/designs/extensible-cli-and-scaffolding-plugins-phase-1.md


================================================
FILE: designs/crd_version_conversion.md
================================================
| Authors       | Creation Date | Status      | Extra |
|---------------|---------------|-------------|-------|
| @droot | 01/30/2019| implementable | -     |

# API Versioning in Kubebuilder

This document describes high level design and workflow for supporting multiple versions in an API built using Kubebuilder. Multi-version support was added as an alpha feature in kubernetes project in 1.13 release. Here are links to some recommended reading material.

* [CRD version Conversion Design Doc](https://github.com/kubernetes/community/blob/3f8bf88a06a114b3984417d6867bb16506c9c71e/contributors/design-proposals/api-machinery/customresource-conversion-webhook.md)

* [CRD Webhook Conversion API changes PR](https://github.com/kubernetes/kubernetes/pull/67795/files)

* [CRD Webhook Conversion PR](https://github.com/kubernetes/kubernetes/pull/67006)

* [Kubecon talk](https://www.youtube.com/watch?v=HsYtMvvzDyI&t=0s&index=100&list=PLj6h78yzYM2PZf9eA7bhWnIh_mK1vyOfU)

* [CRD version conversion POC](https://github.com/droot/crd-conversion-example)

# Design

## Hub and Spoke

The basic concept is that all versions of an object share the storage. So say if you have versions v1, v2 and v3 of a Kind Toy, kubernetes will use one of the versions to persist the object in stable storage i.e. Etcd. User can specify the version to be used for storage in the Custom Resource definition for that API.

One can think storage version as the hub and other versions as spoke to visualize the relationship between storage and other versions (as shown below in the diagram). The key thing to note is that conversion between storage and other version should be lossless (round trippable). As shown in the diagram below, v3 is the storage/hub version and v1, v2 and v4 are spoke version. The document uses storage version and hub interchangeably.

![hub and spoke version diagram][version-diagram]

So if each spoke version (v1, v2 and v4 in this case) defines conversion function from/to the hub version, then conversion function between the spoke versions (v1, v2, v4) can be derived. For example, for converting an object from v1 to v4, we can convert v1 to v3 (the hub version) and v3 to v4.

We will introduce two interfaces in controller-runtime to express the above relationship.

```Go
// Hub defines capability to indicate whether a versioned type is a Hub or not.

type Hub interface {
    runtime.Object
    Hub()
}

// A versioned type is convertible if it can be converted to/from a hub type.

type Convertible interface {
    runtime.Object
    ConvertTo(dst Hub) error
    ConvertFrom(src Hub) error
}
```

A spoke type needs to implement Convertible interface. Kubebuilder can scaffold the skeleton for a type when it is created. An example of Convertible implementation:

```Go
package v1

func (ej *ExternalJob) ConvertTo(dst conversion.Hub) error {
    switch t := dst.(type) {
    case *v3.ExternalJob:
        jobv3 := dst.(*v3.ExternalJob)
        jobv3.ObjectMeta = ej.ObjectMeta
         // conversion implementation
	   //
        return nil
    default:
        return fmt.Errorf("unsupported type %v", t)
    }
}

func (ej *ExternalJob) ConvertFrom(src conversion.Hub) error {
    switch t := src.(type) {
    case *v3.ExternalJob:
        jobv3 := src.(*v3.ExternalJob)
        ej.ObjectMeta = jobv3.ObjectMeta
	   // conversion implementation
        return nil
    default:
        return fmt.Errorf("unsupported type %v", t)
    }
}
```

The storage type v3 needs to implement the Hub interface:

```Go

package v3
func (ej *ExternalJob) Hub() {}

```
## Conversion Webhook Handler

Controller-runtime will implement a default conversion handler that can handle conversion requests for any API type. Code snippets below captures high level implementation details of the handler. This handler will be registered with the webhook server by default.
```Go

type conversionHandler struct {
	// scheme which has Go types for the APIs are registered. This will be injected by controller manager.
	Scheme runtime.Scheme
	// decoder which will be injected by the webhook server
	// decoder knows how to decode a conversion request and API objects.
	Decoder decoder.Decoder
}

// This is the default handler which will be mounted on the webhook server.
func (ch *conversionHandler) Handle(r *http.Request, w http.Response) {
	// decode the request to converReview request object
	convertReq := ch.Decode(r.Body)
	for _, obj := range convertReq.Objects {
	// decode the incoming object
	src, gvk, _ := ch.Decoder.Decode(obj.raw)

	// get target object instance for convertReq.DesiredAPIVersion and gvk.Kind
	dst, _ := getTargetObject(convertReq.DesiredAPIVersion, gvk.Kind)

	// this is where conversion between objects happens

	ch.ConvertObject(src, dst)

	// append dst to converted object list
}

	// create a conversion response with converted objects
}

func (ch *conversionHandler) convertObject(src, dst runtime.Object) error {
    // check if src and dst are of same type, then may be return with error because API server will never invoke this handler for same version.
    srcIsHub, dstIsHub := isHub(src), isHub(dst)
    srcIsConvertible, dstIsConvertible := isConvertible(src), isConvertable(dst)
    if srcIsHub {
        if dstIsConvertible {
            return dst.(conversion.Convertable).ConvertFrom(src.(conversion.Hub))
        } else {
            // this is error case, this can be flagged at setup time ?
            return fmt.Errorf("%T is not convertible to", src)
        }
    }

    if dstIsHub {
        if srcIsConvertible {
            return src.(conversion.Convertable).ConvertTo(dst.(conversion.Hub))
        } else {
            // this is error case.
            return fmt.Errorf("%T is not convertible", src)
        }
    }

    // neither src or dst are Hub, means both of them are spoke, so lets get the hub
    // version type.

    hub, err := getHub(scheme, src)
    if err != nil {
        return err
    }

    // shall we get Hub for dst type as well and ensure hubs are same ?
    // src and dst needs to be convertible for it to work
    if !srcIsConvertable || !dstIsConvertable {
        return fmt.Errorf("%T and %T needs to be both convertible", src, dst)
    }

    err = src.(conversion.Convertible).ConvertTo(hub)
    if err != nil {
        return fmt.Errorf("%T failed to convert to hub version %T : %w", src, hub, err)
    }

    err = dst.(conversion.Convertible).ConvertFrom(hub)
    if err != nil {
        return fmt.Errorf("%T failed to convert from hub version %T : %w", dst, hub, err)
    }
    return nil
}
```

Handler Registration flow will perform following at the startup:

* For APIs with hub defined, it can examine if spoke versions implement convertible or not and can abort with error.

* It will also be nice if we can detect an API with multiple versions but with no hub defined, but that requires distinguishing between APIs defined in the project vs external.

# CRD Generation

The tool that generates the CRD manifests lives under controller-tools repo. Currently it generates the manifests for each <group, version, kind> discovered under ‘pkg/…’ directory in the project by examining the comments (aka annotations) in Go source files. Following annotations will be added to support multi version:

## Storage/Serve annotations:

The resource annotation will be extended to indicate storage/serve attributes as shown below.

```Go
// ...
// +kubebuilder:resource:storage=true,serve=true
// …
type APIName struct {
   ...
}
```

The default value of *serve* attribute is true. The default value of *storage* attribute will be *true* for single version and *false* for multiple versions to ensure backward compatibility.

CRD generation will be extended to support the following:

* If multiple versions are detected for an API:

    * Ensure only one version is marked as storage version. Assume default value of *storage* to be *false* for this case.

    * Ensure version specific fields such as *OpenAPIValidationSchema, SubResources and AdditionalPrinterColumn* are added per version and omitted from the top level CRD definition.

* In case of single version,

    * Do not use version specific field in CRD spec because users are most likely running with k8s version < 1.13 which doesn’t support version specific specs for *OpenAPIValidationSchema, SubResources and AdditionalPrinterColumn. *This is critical to maintain backward compatibility.

    * Assume default value for storage attribute to be *true* for this case.

The above two requirements will require CRD generation logic to be divided in two phases. In first phase, parse and store CRD information in an internal structure for all versions and then generate the CRD manifest on the basis of multi-version/single-version scenario.

## Conversion Webhook annotations:

Webhook annotations will be extended to support conversion webhook fields.

```Go
// ...
// +kubebuilder:webhook:conversion:....
// ...
```

These annotations would be placed just above the API type definition to associate conversion webhook with an API type.

The exact syntax for annotation is yet to be defined, but goal is CRD generation tool to be able to extract information from these annotation to populate the `CustomResourceConversion` struct in CRD definition. The CA bits for webhook configuration will be populated by using annotations on the CRD as per the [design](https://docs.google.com/document/d/1ipTvFBRoe7fuDiz27Csm5Zb6rH0z6LJTuKM8xY3jaUg/edit?ts=5c49094e#heading=h.u7ei2s2van5b).

# Kubebuilder CLI:

kubebuilder create api --group g1 --version v2 --Kind k1 [--storage]

Fields marked in yellow are proposed new fields to the command and reasoning is stated below.

*  *--storage* flag gives an option to mark a version as storage/hub version.

Generally users have one controller per group/kind, we will avoid scaffolding code for controller if we detect that a controller already exists for an API group/kind.

# TODO:

## There is more exploration/work is required in the following areas related to API versioning:

* Making it easy to write the conversion function itself.

* Making it easy to generate tests for conversion functions using fuzzer.

* Best practices around rolling out different versions of the API

Version History

<table>
  <tr>
    <td>Version</td>
    <td>Updated on</td>
    <td>Description</td>
  </tr>
  <tr>
    <td>Draft</td>
    <td>01/30/2019
</td>
    <td>Initial version</td>
  </tr>
  <tr>
    <td>1.0</td>
    <td>02/27/2019</td>
    <td>Updated the design as per POC implementation</td>
  </tr>
</table>


[version-diaiagram]: assets/version_diagram.png


================================================
FILE: designs/discontinue_usage_of_kube_rbac_proxy.md
================================================
| Authors         | Creation Date | Status        | Extra |
|-----------------|---------------|---------------|-------|
| @camilamacedo86 | 07/04/2024    | Implementable | -     |

# Discontinue Kube RBAC Proxy in Default Kubebuilder Scaffolding

This proposal highlights the need to reassess the usage of [kube-rbac-proxy](https://github.com/brancz/kube-rbac-proxy)
in the default scaffold due to the evolving k8s infra and community feedback. Key considerations include the transition to a shared infrastructure requiring
all images to be published on [registry.k8s.io][registry.k8s.io], the deprecation
of Google Cloud Platform's [Container Registry](https://cloud.google.com/artifact-registry/docs/transition/prepare-gcr-shutdown), and the fact
that [kube-rbac-proxy][kube-rbac-proxy] is yet to be part of the Kubernetes ecosystem umbrella.

The dependency on a potentially discontinuable Google infrastructure,
**which is out of our control**, paired with the challenges of maintaining,
building, or promoting [kube-rbac-proxy][kube-rbac-proxy] images,
calls for a change.

In this document is proposed to replace the [kube-rbac-proxy][kube-rbac-proxy] within
[Network Policies][k8s-doc-networkpolicies] follow-up for potentially enhancements
to protect the metrics endpoint combined with [cert-manager][cert-manager] and a new
a feature introduced in controller-runtime, see [here][cr-pr].

**For the future (when kube-rbac-proxy be part of the k8s umbrella)**, it is proposed the usage of the
[Plugins API provided by Kubebuilder](./../docs/book/src/plugins/plugins.md),
to create an [external plugin](./../docs/book/src/plugins/creating-plugins.md)
to properly integrate the solution with Kubebuilder and provide a helper to allow users to opt-in as they please them.

## Open Questions

- 1) [Network Policies][k8s-doc-networkpolicies] is implemented by the cluster’s CNI. Are we confident that all the major CNIs in use support the proposed policy?

> Besides [Network Policies][k8s-doc-networkpolicies] being part of the core Kubernetes API, their enforcement relies on the CNI plugin installed in
the Kubernetes cluster. While support and implementation details vary among CNIs, the most commonly used ones,
such as Calico, Cilium, WeaveNet, and Canal, offer  support for NetworkPolicies.
>
>Also, there was concern in the past because AWS did not support it. However, this changed,
>as detailed in their announcement: [Amazon VPC CNI now supports Kubernetes Network Policies](https://aws.amazon.com/blogs/containers/amazon-vpc-cni-now-supports-kubernetes-network-policies/).
>
>Moreover, under this proposal, users can still disable/enable this option as they please them.

- 2) NetworkPolicy is a simple firewall and does not provide `authn/authz` and encryption.

> Yes, that's correct. NetworkPolicy acts as a basic firewall for pods within a Kubernetes cluster, controlling traffic
> flow at the IP address or port level. However, it doesn't handle authentication (authn), authorization (authz),
> or encryption directly like kube-rbac-proxy solution.
>
> However, if we can combine the cert-manager and the new feature provided
> by controller-runtime, we can achieve the same or a superior level of protection
> without relying on any extra third-party dependency.

- 3) Could not Kubebuilder maintainers use the shared infrastructure to continue building and promoting those images under the new `registry.k8s.io`?

> We tried to do that, see [here](https://github.com/kubernetes/test-infra/blob/master/config/jobs/image-pushing/k8s-staging-kubebuilder.yaml) the recipe implemented.
> However, it does not work because kube-rbac-proxy is not under the
> kubernetes umbrella. Moreover, we experimented with the GitHub Repository as an alternative approach, see the [PR](https://github.com/kubernetes-sigs/kubebuilder/pull/3854) but seems
> that we are not allowed to use it. Nevertheless, neither approach sorts out all motivations and requirements
> Ideally, Kubebuilder should not be responsible for maintaining and promoting third-party artefacts.

- 4) However, is not Kubebuilder also building and promoting the binaries required to be used within [EnvTest](./../docs/book/src/reference/envtest.md)
feature implemented in controller-runtime?

> Yes, but it also will need to change. Controller-runtime maintainers are looking for solutions to
> build those binaries inside its project since it seems part of its domain. This change is likely
> to be transparent to the community users.

- 5) Could we not use the Controller-Runtime feature [controller-runtime][cr-pr] which enable secure metrics serving over HTTPS?

Yes, after some changes are addressed. After we ask for a hand for reviews from skilled auth maintainers and receive feedback, it appears that this configuration needs to
align with best practices. See the [issue](https://github.com/kubernetes-sigs/controller-runtime/issues/2781)
raised to track this need.

- 6) Could we not make [cert-manager][cert-manager] mandatory?

> No, we can not. One of the goals of Kubebuilder is to make it easier for new
users. So, we cannot make mandatory the usage of a third party as cert-manager
for users by default and to only quick-start.
>
> However, we can make mandatory the usage of
[cert-manager][cert-manager] for some specific features like use kube-rbac-proxy
or, as it is today, using webhooks, a more advanced and optional option.

## Summary

Starting with release `3.15.0`, Kubebuilder will no longer scaffold
new projects with [kube-rbac-proxy][kube-rbac-proxy].
Existing users are encouraged to switch to images hosted by the project
on [quay.io](https://quay.io/repository/brancz/kube-rbac-proxy?tab=tags&tag=latest) **OR**
to adapt their projects to utilize [Network Policies][k8s-doc-networkpolicies], following the updated scaffold guidelines.

For project updates, users can manually review scaffold changes or utilize the
provided [upgrade assistance helper](https://book.kubebuilder.io/reference/rescaffold).

Communications and guidelines would be provided along with the release.

## Motivation

- **Infrastructure Reliability Concerns**: Kubebuilder’s reliance on Google's infrastructure, which may be discontinued
at their discretion, poses a risk to image availability and project reliability. [Discussion thread](https://kubernetes.slack.com/archives/CCK68P2Q2/p1711914533693319?thread_ts=1711913605.487359&cid=CCK68P2Q2) and issues: https://github.com/kubernetes/k8s.io/issues/2647 and https://github.com/kubernetes-sigs/kubebuilder/issues/3230
- **Registry Changes and Image Availability**: The transition from `gcr.io` to [registry.k8s.io][registry.k8s.io] and
the [Container Registry][container-registry-dep] deprecation implies that **all** images provided so far by Kubebuilder
[here][kb-images-repo] will unassailable by **April 22, 2025**. [More info][container-registry-dep] and [slack ETA thread][slack-eta-thread]
- **Security and Endorsement Concerns**: [kube-rbac-proxy][kube-rbac-proxy] is a process to be part of
auth-sig for an extended period, however, it is not there yet. The Kubernetes Auth SIG’s review reveals that kube-rbac-proxy
must undergo significant updates to secure an official endorsement and to be supported, highlighting pressing concerns.
You can check the ongoing process and changes required by looking at the [project issue](https://github.com/brancz/kube-rbac-proxy/issues/238)
- **Evolving User Requirements and Deprecations**: The anticipated requirement for certificate management, potentially
necessitating cert-manager, underlines Kubebuilder's aim to simplify setup and reduce third-party dependencies. [More info, see issue #3524](https://github.com/kubernetes-sigs/kubebuilder/issues/3524)
- **Aim for a Transparent and Collaborative Infrastructure**: As an open-source project, Kubebuilder strives for
a community-transparent infrastructure that allows broader contributions. This goal aligns with our initiative
to migrate Kubebuilder CLI release builds from GCP to GitHub Actions and using Go-Releaser see [here](./../build/.goreleaser.yml),
or promoting infrastructure managed under the k8s-infra umbrella.
- **Community Feedback**: Some community members preferred its removal from the default scaffolding. [Issue 3482](https://github.com/kubernetes-sigs/kubebuilder/issues/3482)
- **Enhancing Service Monitor with Proper TLS/Certificate Usage Requested by Community:** [Issue #3657](https://github.com/kubernetes-sigs/kubebuilder/issues/3657). It is achievable with [kube-rbac-proxy][kube-rbac-proxy] OR [Network Policies][k8s-doc-networkpolicies] usage within [cert-manager][cert-manager].

### Goals

- **Maximize Protection for the Metrics Endpoint without relay in third-part(s)**: Aim to provide the highest level of
protection achievable for the metrics endpoint without relying on new third-party dependencies or the need to build
and promote images from other projects.
- **Avoid Breaking Changes**: Ensure that users who generated projects with previous versions can still use the
new version with scaffold changes and adapt their project at their convenience.
- **Sustainable Project Maintenance**: Ensure all projects scaffolded by Kubebuilder can be
maintained and supported by its maintainers.
- **Independence from Google Cloud Platform**: Move away from reliance on Google Cloud Platform,
considering the potential for unilateral shutdowns.
- **Kubernetes Umbrella Compliance**: Cease the promotion or endorsement of solutions
not yet endorsed by the Kubernetes umbrella organization, mainly when used and shipped with the workload.
- **Promote Use of External Plugins**: Adhere to Kubebuilder's directive to avoid direct third-party
integrations, favouring the support of projects through the Kubebuilder API and [external plugins][external-plugins].
This approach empowers users to add or integrate solutions with the Kubebuilder scaffold on their own, ensuring that
third-party project maintainers—who are more familiar with their solutions—can maintain and update
their integrations, as implementing it following the best practices to use their project, enhancing the user experience.
External plugins should reside within third-party repository solutions and remain up-to-date as part of those changes,
aligning with their domain of responsibility.
- **Flexible Network Policy Usage**: Allow users to opt-out of the default-enabled usage of [Network Policies][k8s-doc-networkpolicies]
if they prefer another solution, plan to deploy their solution with a vendor or use a CNI that does not support NetworkPolicies.

### Non-Goals

- **Replicate kube-rbac-proxy Features or Protection Level**: It is not a goal to provide the same features
or layer of protection as [kube-rbac-proxy][kube-rbac-proxy]. Since [Network Policies][k8s-doc-networkpolicies]operate differently
and do not offer the same kind of functionality as [kube-rbac-proxy][kube-rbac-proxy], achieving identical protection levels through
[Network Policies][k8s-doc-networkpolicies]alone is not feasible.

However, incorporating NetworkPolicies, cert-manager, and/or the features introduced
in the [controller-runtime pull request #2407][cr-pr] we are mainly addressing the security concerns that
kube-rbac-proxy handles.

## Proposal

### Phase 1: Transition to network policies

The immediate action outlined in this proposal is the replacement of [kube-rbac-proxy][kube-rbac-proxy]
with Kubernetes API NetworkPolicies.

### Phase 2: Add Cert-Manager as an Optional option to be used with metrics

Looking beyond the initial phase, this proposal envisions integrating cert-manager for TLS certificate management
and exploring synergies with new features in Controller Runtime, as demonstrated in [PR #2407](https://github.com/kubernetes-sigs/controller-runtime/pull/2407).

These enhancements would introduce encrypted communication for metrics endpoints and potentially incorporate authentication mechanisms,
significantly elevating the security model employed by projects scaffolded by Kubebuilder.

- **cert-manager**: Automates the management and issuance of TLS certificates, facilitating encrypted communication and, when configured with mTLS, adding a layer of authentication.
  Currently, we leverage cert-manager when webhooks are scaffolded. So, the proposal idea would be to allow users to enable the cert-manager for the metrics such as those provided
  and required for the webhook feature. However, it MUST be optional. One of the goals of Kubebuilder is to make it easier for new users. Therefore, new users should
  not need to deal with cert-manager by default or have the need to install it to just a quick start.

That would mean, in a follow-up to the [current open PR](https://github.com/kubernetes-sigs/kubebuilder/pull/3853) to address the above `phase 1 - Transition to NetworkPolices`,
we aim to introduce a configurable Kustomize patch that will enable patching the ServiceMonitor in `config/prometheus/monitor.yaml` and certificates similar to our
existing setup for webhooks. This enhancement will ensure more flexible deployment configurations and enhance the security
features of the service monitoring components.

Currently, in the `config/default/`, we have implemented patches for cert-manager along with webhooks, as seen in
`config/default/kustomization.yaml` ([example](https://github.com/kubernetes-sigs/kubebuilder/blob/bd0876b8132ff66da12d8d8a0fdc701fde00f54b/docs/book/src/component-config-tutorial/testdata/project/config/default/kustomization.yaml#L51-L149)).
These patches handle annotations for the cert-manager CA injection across various configurations, like
ValidatingWebhookConfiguration, MutatingWebhookConfiguration, and CRDs.

For the proposed enhancements, we need to integrate similar configurations for the ServiceMonitor.
This involves the creation of a patch file named `metrics_https_patch.yaml`, which will include
configurations necessary for enabling HTTPS for the ServiceMonitor.

Here's an example of how this configuration might look:

```sh
# [METRICS WITH HTTPS] To enable the ServiceMonitor using HTTPS, uncomment the following line
# Note that for this to work, you also need to ensure that cert-manager is enabled in your project
- path: metrics_https_patch.yaml
```

This patch should apply similar changes as the current webhook patches,
targeting necessary updates in the manifest to support HTTPS communication secured by
cert-manager certificates.

Here is an example of how the `ServiceMonitor` configured to work with cert-manager might look:

```yaml
# Prometheus Monitor Service (Metrics) with cert-manager
apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
  labels:
    control-plane: controller-manager
    app.kubernetes.io/name: project-v4
    app.kubernetes.io/managed-by: kustomize
  name: controller-manager-metrics-monitor
  namespace: system
  annotations:
    cert-manager.io/inject-ca-from: $(NAMESPACE)/controller-manager-certificate
spec:
  endpoints:
    - path: /metrics
      port: https
      scheme: https
      bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
      tlsConfig:
        # We should recommend ensure that TLS verification is not skipped in production
        insecureSkipVerify: false
        caFile: /etc/prometheus/secrets/ca.crt # CA certificate injected by cert-manager
        certFile: /etc/prometheus/secrets/tls.crt # TLS certificate injected by cert-manager
        keyFile: /etc/prometheus/secrets/tls.key # TLS private key injected by cert-manager
  selector:
    matchLabels:
      control-plane: controller-manager
```

### Phase 3: When Controller-Runtime feature is enhanced

After we have the [issue](https://github.com/kubernetes-sigs/controller-runtime/issues/2781)
addressed, and we plan to use it to protect the endpoint. See, that would mean ensuring
that we are either `handle authentication (authn), authorization (authz)`.
Examples of its implementation can be found [here](https://github.com/kubernetes-sigs/cluster-api/blob/v1.6.3/util/flags/diagnostics.go#L79-L82).

### Phase 4: When kube-rbac-proxy be accepted under the umbrella

Once kube-rbac-proxy is included in the Kubernetes umbrella,
Kubebuilder maintainers can support its integration through a [plugin](https://kubebuilder.io/plugins/plugins).
We can following up the ongoing process and changes required for the project be accepted
by looking at the [project issue](https://github.com/brancz/kube-rbac-proxy/issues/238).

This enables a seamless way to incorporate kube-rbac-proxy into Kubebuilder scaffolds,
allowing users to run:

```sh
kubebuilder init|edit --plugins="kube-rbac-proxy/v1"
```

So that the plugin could use the [plugin/util](../pkg/plugin/util) lib provide
to comment (We can add a method like the [UncommentCode](https://github.com/kubernetes-sigs/kubebuilder/blob/72586d386cfbcaecea6321a703d1d7560c521885/pkg/plugin/util/util.go#L102))
the patches in the `config/default/kustomization` and disable the default network policy used within
and [replace the code](https://github.com/kubernetes-sigs/kubebuilder/blob/72586d386cfbcaecea6321a703d1d7560c521885/pkg/plugin/util/util.go#L231)
in the `main.go` bellow with to not use the controller-runtime
feature instead.

```go
ctrlOptions := ctrl.Options{
    MetricsFilterProvider: filters.WithAuthenticationAndAuthorization,
    MetricsSecureServing:  true,
}
```

### Documentation Updates

Each phase of implementation associated with this proposal must include corresponding
updates to the documentation. This is essential to ensure end users understand
how to enable, configure, and utilize the options effectively. Documentation updates should be
completed as part of the pull request to introduce code changes.

### Proof of Concept

- **(Phase 1)NetworkPolicies:** https://github.com/kubernetes-sigs/kubebuilder/pull/3853
- Example of Controller-Runtime new feature to protect Metrics Endpoint: https://github.com/sbueringer/controller-runtime-tests/tree/master/metrics-auth

### Risks and Mitigations

#### Loss of Previously Promoted Images

The transition to the new shared infrastructure for Kubernetes SIG projects has rendered us unable to automatically build and promote images as before.
The process only works for projects under the umbrella.
However, the k8s-infra maintainers could manually transfer these images
to the new [registry.k8s.io][registry.k8s.io] as a "contingent approach".
See: [https://explore.ggcr.dev/?repo=gcr.io%2Fk8s-staging-kubebuilder%2Fkube-rbac-proxy](https://explore.ggcr.dev/?repo=registry.k8s.io%2Fkubebuilder%2Fkube-rbac-proxy)

To continue using kube-rbac-proxy, users must update their projects to reference images
from the new registry. This requires a project update and a new release,
ensuring the image references in the `config/default/manager_auth_proxy_patch.yaml` point
to a new place.

Therefore, the best approach here for those still interested in using
kube-rbac-proxy seems to direct them to the images hosted
at [quay.io](https://quay.io/repository/brancz/kube-rbac-proxy?tab=tags&tag=latest),
which are maintained by the project itself and then,
we keep those images in the registry.k8s.io as a "contingent approach".

Ensuring that these images will continue to be promoted under any infrastructure available to
Kubebuilder is not reliable or achievable for Kubebuilder maintainers. It is definitely out of our control.

#### Impact of Google Cloud Platform Kubebuilder project

Kubebuilder hasn't received any official notice regarding a shutdown of its project there so far, but there's a proactive move to transition away
from Google Cloud Platform services due to factors beyond our control. Open communication with our community is key as
we explore alternatives. It's important to note the [Container Registry Deprecation][container-registry-dep] results
in users no longer able to consume those images from the current location from **early 2025**,
emphasizing the need to shift away from dependent images as soon as possible and communicate it extensively
through mailing lists and other channels to ensure community awareness and readiness.

## Alternatives

### Replace the current images `gcr.io/kubebuilder/kube-rbac-proxy` with `registry.k8s.io/kubebuilder/kube-rbac-proxy`

The k8s-infra maintainers assist in ensuring these images will not be lost by:
- Manually adding them to [gcr.io/k8s-staging-kubebuilder/kube-rbac-proxy](https://explore.ggcr.dev/?repo=gcr.io%2Fk8s-staging-kubebuilder%2Fkube-rbac-proxy) and promoting them via [registry.k8s.io/kubebuilder/kube-rbac-proxy](https://explore.ggcr.dev/?image=registry.k8s.io%2Fkubebuilder%2Fkube-rbac-proxy:v0.16.0).

An available option would be to communicate to users to:
- a) Replace their registry from `gcr.io/k8s-staging-kubebuilder/kube-rbac-proxy` to `registry.k8s.io/kubebuilder/kube-rbac-proxy`
- b) Clearly state in the docs, Kubebuilder scaffolds, and all channels, including email communications, that kube-rbac-proxy is in the process of becoming part of Kubernetes/auth-sig but is not yet there and hence is a "not supported/secure" solution

**Cons:**
- Kubebuilder would still not be fully compliant with its goals since it would be scaffolding a third-party integration instead of properly endorsing and promoting the usage of external-plugin APIs.
- Kubebuilder would still be promoting a solution not deemed secure/safe according to the review by auth-sig maintainers.
- We would still need to manually request k8s-infra maintainers to build and promote these images in the new registry manually.
- Changes in the manager/project solution delivered in the scaffold have a critical impact. For example, in this case, users
will need to change **ALL** projects they support and ensure that their users no longer use their previously released versions.
Following this path, when kube-rbac-proxy is accepted under the Kubernetes/auth-sig, they will start to maintain and manage
their own images, which means this path will change again, and Kubebuilder maintainers have no control over ensuring that
these images will still be available and promoted for a long period.

### Retain kube-rbac-proxy as an Opt-in Feature and move it to an alpha plugin (Unsupported Feature) AND/OR use the project registry

This alternative keeps kube-rbac-proxy out of the default scaffolds, offering it as an optional plugin for users who choose
to integrate it. Clear communication will be crucial to inform users about the implications of using kube-rbac-proxy.

**Cons:**

Mainly, all cons added for the above alternative option `Replace the current images gcr.io/kubebuilder/kube-rbac-proxy`
with `registry.k8s.io/kubebuilder/kube-rbac-proxy` within the exception that we would make clear that we kubebuilder
is unable to manage those images and move the current implementation for the alpha plugin
it would maybe make the process to move it from the Kubebuilder repository to `kube-rbac-proxy` an
easier process to allow them to work with the external plugin.

However, that is a double effort for users and Kubebuilder maintainers to deal with breaking changes
resulting from achieving the ultimate go. Therefore, it would make more sense
to encourage using external-plugins API and add this option in their
repo once, then create these intermediate steps.

[kube-rbac-proxy]: https://github.com/brancz/kube-rbac-proxy
[external-plugins]: https://kubebuilder.io/plugins/external-plugins
[registry.k8s.io]: https://github.com/kubernetes/registry.k8s.io
[container-registry-dep]: https://cloud.google.com/artifact-registry/docs/transition/prepare-gcr-shutdown
[kb-images-repo]: https://console.cloud.google.com/gcr/images/kubebuilder/GLOBAL/kube-rbac-proxy
[slack-eta-thread]: https://kubernetes.slack.com/archives/CCK68P2Q2/p1712622102206909
[cr-pr]: https://github.com/kubernetes-sigs/controller-runtime/pull/2407
[k8s-doc-networkpolicies]: https://kubernetes.io/docs/concepts/services-networking/network-policies/
[cert-manager]:https://cert-manager.io/


================================================
FILE: designs/extensible-cli-and-scaffolding-plugins-phase-1-5.md
================================================
| Authors       | Creation Date | Status      | Extra                                                           |
|---------------|---------------|-------------|-----------------------------------------------------------------|
| @adirio | Mar 9, 2021  | Implemented | [Plugins doc](https://book.kubebuilder.io/plugins/plugins.html) |

# Extensible CLI and Scaffolding Plugins - Phase 1.5

Continuation of [Extensible CLI and Scaffolding Plugins](./extensible-cli-and-scaffolding-plugins-phase-1.md).

## Goal

The goal of this phase is to achieve one of the goals proposed for Phase 2: chaining plugins.
Phase 2 includes several other challenging goals, but being able to chain plugins will be beneficial
for third-party developers that are using kubebuilder as a library.

The other main goal of phase 2, discovering and using external plugins, is out of the scope of this phase,
and will be tackled when phase 2 is implemented.

## Table of contents
- [Goal](#goal)
- [Motivation](#motivation)
- [Proposal](#proposal)
- [Implementation](#implementation)

## Motivation

There are several cases of plugins that want to maintain most of the go plugin functionality and add
certain features on top of it, both inside and outside kubebuilder repository:
- [Addon pattern](../plugins/addon)
- [Operator SDK](https://github.com/operator-framework/operator-sdk/tree/master/internal/plugins/golang)

This behavior fits perfectly under Phase 1.5, where plugins could be chained. However, as this feature is
not available, the adopted temporal solution is to wrap the base go plugin and perform additional actions
after its `Run` method has been executed. This solution faces several issues:

- Wrapper plugins are unable to access the data of the wrapped plugins, as they weren't designed for this
  purpose, and therefore, most of its internal data is non-exported. An example of this inaccessible data
  would be the `Resource` objects created inside the `create api` and `create webhook` commands.
- Wrapper plugins are dependent on their wrapped plugins, and therefore can't be used for other plugins.
- Under the hood, subcommands implement a second hidden interface: `RunOptions`, which further accentuates
  these issues.

Plugin chaining solves the aforementioned problems but the current plugin API, and more specifically the
`Subcommand` interface, does not support plugin chaining.

- The `RunOptions` interface implemented under the hood is not part of the plugin API, and therefore
  the cli is not able to run post-scaffold logic (implemented in `RunOptions.PostScaffold` method) after
  all the plugins have scaffolded their part.
- `Resource`-related commands can't bind flags like `--group`, `--version` or `--kind` in each plugin,
  it must be created outside the plugins and then injected into them similar to the approach followed
  currently for `Config` objects.

## Proposal

Design a Plugin API that combines the current [`Subcommand`](../pkg/plugin/interfaces.go) and
[`RunOptions`](../pkg/plugins/internal/cmdutil/cmdutil.go) interfaces and enables plugin-chaining.
The new `Subcommand` hooks can be split in two different categories:
- Initialization hooks
- Execution hooks

Initialization hooks are run during the dynamic creation of the CLI, which means that they are able to
modify the CLI, e.g. providing descriptions and examples for subcommands or binding flags.
Execution hooks are run after the CLI is created, and therefore cannot modify the CLI. On the other hand,
as they are run during the CLI execution, they have access to user-provided flag values, project configuration,
the new API resource or the filesystem abstraction, as opposed to the initialization hooks.

Additionally, some of these hooks may be optional, in which case a non-implemented hook will be skipped
when it should be called and consider it succeeded. This also allows to create some hooks specific for
a certain subcommand call (e.g.: `Resource`-related hooks for the `edit` subcommand are not needed).

Different ordering guarantees can be considered:
- Hook order guarantee: a hook for a
Download .txt
gitextract_fvvnmo3k/

├── .github/
│   ├── ISSUE_TEMPLATE/
│   │   ├── bug_report.yaml
│   │   ├── config.yml
│   │   └── feature_request.yaml
│   ├── PULL_REQUEST_TEMPLATE.md
│   ├── SECURITY.md
│   ├── dependabot.yml
│   ├── instructions/
│   │   └── kubebuilder.instructions.md
│   └── workflows/
│       ├── apidiff.yml
│       ├── codeql.yml
│       ├── coverage.yml
│       ├── cross-platform-tests.yml
│       ├── external-plugin.yml
│       ├── legacy-webhook-path.yml
│       ├── lint-sample.yml
│       ├── lint.yml
│       ├── release-version-ci.yml
│       ├── release.yml
│       ├── scorecard.yml
│       ├── spaces.yml
│       ├── test-alpha-generate.yml
│       ├── test-book.yml
│       ├── test-devcontainer.yml
│       ├── test-e2e-samples.yml
│       ├── test-helm-book.yml
│       ├── test-helm-samples.yml
│       ├── testdata.yml
│       └── verify.yml
├── .gitignore
├── .golangci.yml
├── .yamllint
├── .yamllint-helm
├── AGENTS.md
├── CONTRIBUTING.md
├── DESIGN.md
├── LICENSE
├── Makefile
├── OWNERS
├── OWNERS_ALIASES
├── README.md
├── RELEASE.md
├── SECURITY_CONTACTS
├── VERSIONING.md
├── build/
│   └── .goreleaser.yml
├── code-of-conduct.md
├── designs/
│   ├── README.md
│   ├── code-generate-image-plugin.md
│   ├── crd_version_conversion.md
│   ├── discontinue_usage_of_kube_rbac_proxy.md
│   ├── extensible-cli-and-scaffolding-plugins-phase-1-5.md
│   ├── extensible-cli-and-scaffolding-plugins-phase-1.md
│   ├── extensible-cli-and-scaffolding-plugins-phase-2.md
│   ├── helm-chart-autogenerate-plugin.md
│   ├── helper_to_upgrade_projects_by_rescaffolding.md
│   ├── integrating-kubebuilder-and-osdk.md
│   ├── simplified-scaffolding.md
│   ├── template.md
│   └── update_action.md
├── docs/
│   ├── CONTRIBUTING-ROLES.md
│   ├── README.md
│   ├── book/
│   │   ├── .firebaserc
│   │   ├── book.toml
│   │   ├── functions/
│   │   │   └── handle-version.js
│   │   ├── install-and-build.sh
│   │   ├── litgo.sh
│   │   ├── markerdocs.sh
│   │   ├── src/
│   │   │   ├── SUMMARY.md
│   │   │   ├── TODO.md
│   │   │   ├── architecture.md
│   │   │   ├── cronjob-tutorial/
│   │   │   │   ├── api-design.md
│   │   │   │   ├── basic-project.md
│   │   │   │   ├── cert-manager.md
│   │   │   │   ├── controller-implementation.md
│   │   │   │   ├── controller-overview.md
│   │   │   │   ├── cronjob-tutorial.md
│   │   │   │   ├── empty-main.md
│   │   │   │   ├── gvks.md
│   │   │   │   ├── main-revisited.md
│   │   │   │   ├── new-api.md
│   │   │   │   ├── other-api-files.md
│   │   │   │   ├── running-webhook.md
│   │   │   │   ├── running.md
│   │   │   │   ├── testdata/
│   │   │   │   │   ├── emptyapi.go
│   │   │   │   │   ├── emptycontroller.go
│   │   │   │   │   ├── emptymain.go
│   │   │   │   │   ├── finalizer_example.go
│   │   │   │   │   └── project/
│   │   │   │   │       ├── .custom-gcl.yml
│   │   │   │   │       ├── .devcontainer/
│   │   │   │   │       │   ├── devcontainer.json
│   │   │   │   │       │   └── post-install.sh
│   │   │   │   │       ├── .dockerignore
│   │   │   │   │       ├── .github/
│   │   │   │   │       │   └── workflows/
│   │   │   │   │       │       ├── lint.yml
│   │   │   │   │       │       ├── test-chart.yml
│   │   │   │   │       │       ├── test-e2e.yml
│   │   │   │   │       │       └── test.yml
│   │   │   │   │       ├── .gitignore
│   │   │   │   │       ├── .golangci.yml
│   │   │   │   │       ├── AGENTS.md
│   │   │   │   │       ├── Dockerfile
│   │   │   │   │       ├── Makefile
│   │   │   │   │       ├── PROJECT
│   │   │   │   │       ├── README.md
│   │   │   │   │       ├── api/
│   │   │   │   │       │   └── v1/
│   │   │   │   │       │       ├── cronjob_types.go
│   │   │   │   │       │       ├── groupversion_info.go
│   │   │   │   │       │       └── zz_generated.deepcopy.go
│   │   │   │   │       ├── cmd/
│   │   │   │   │       │   └── main.go
│   │   │   │   │       ├── config/
│   │   │   │   │       │   ├── certmanager/
│   │   │   │   │       │   │   ├── certificate-metrics.yaml
│   │   │   │   │       │   │   ├── certificate-webhook.yaml
│   │   │   │   │       │   │   ├── issuer.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   └── kustomizeconfig.yaml
│   │   │   │   │       │   ├── crd/
│   │   │   │   │       │   │   ├── bases/
│   │   │   │   │       │   │   │   └── batch.tutorial.kubebuilder.io_cronjobs.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   └── kustomizeconfig.yaml
│   │   │   │   │       │   ├── default/
│   │   │   │   │       │   │   ├── cert_metrics_manager_patch.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   ├── manager_metrics_patch.yaml
│   │   │   │   │       │   │   ├── manager_webhook_patch.yaml
│   │   │   │   │       │   │   └── metrics_service.yaml
│   │   │   │   │       │   ├── manager/
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   └── manager.yaml
│   │   │   │   │       │   ├── network-policy/
│   │   │   │   │       │   │   ├── allow-metrics-traffic.yaml
│   │   │   │   │       │   │   ├── allow-webhook-traffic.yaml
│   │   │   │   │       │   │   └── kustomization.yaml
│   │   │   │   │       │   ├── prometheus/
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   ├── monitor.yaml
│   │   │   │   │       │   │   └── monitor_tls_patch.yaml
│   │   │   │   │       │   ├── rbac/
│   │   │   │   │       │   │   ├── cronjob_admin_role.yaml
│   │   │   │   │       │   │   ├── cronjob_editor_role.yaml
│   │   │   │   │       │   │   ├── cronjob_viewer_role.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   ├── leader_election_role.yaml
│   │   │   │   │       │   │   ├── leader_election_role_binding.yaml
│   │   │   │   │       │   │   ├── metrics_auth_role.yaml
│   │   │   │   │       │   │   ├── metrics_auth_role_binding.yaml
│   │   │   │   │       │   │   ├── metrics_reader_role.yaml
│   │   │   │   │       │   │   ├── role.yaml
│   │   │   │   │       │   │   ├── role_binding.yaml
│   │   │   │   │       │   │   └── service_account.yaml
│   │   │   │   │       │   ├── samples/
│   │   │   │   │       │   │   ├── batch_v1_cronjob.yaml
│   │   │   │   │       │   │   └── kustomization.yaml
│   │   │   │   │       │   └── webhook/
│   │   │   │   │       │       ├── kustomization.yaml
│   │   │   │   │       │       ├── manifests.yaml
│   │   │   │   │       │       └── service.yaml
│   │   │   │   │       ├── dist/
│   │   │   │   │       │   ├── chart/
│   │   │   │   │       │   │   ├── .helmignore
│   │   │   │   │       │   │   ├── Chart.yaml
│   │   │   │   │       │   │   ├── templates/
│   │   │   │   │       │   │   │   ├── NOTES.txt
│   │   │   │   │       │   │   │   ├── _helpers.tpl
│   │   │   │   │       │   │   │   ├── cert-manager/
│   │   │   │   │       │   │   │   │   ├── metrics-certs.yaml
│   │   │   │   │       │   │   │   │   ├── selfsigned-issuer.yaml
│   │   │   │   │       │   │   │   │   └── serving-cert.yaml
│   │   │   │   │       │   │   │   ├── crd/
│   │   │   │   │       │   │   │   │   └── cronjobs.batch.tutorial.kubebuilder.io.yaml
│   │   │   │   │       │   │   │   ├── manager/
│   │   │   │   │       │   │   │   │   └── manager.yaml
│   │   │   │   │       │   │   │   ├── metrics/
│   │   │   │   │       │   │   │   │   └── controller-manager-metrics-service.yaml
│   │   │   │   │       │   │   │   ├── prometheus/
│   │   │   │   │       │   │   │   │   └── controller-manager-metrics-monitor.yaml
│   │   │   │   │       │   │   │   ├── rbac/
│   │   │   │   │       │   │   │   │   ├── controller-manager.yaml
│   │   │   │   │       │   │   │   │   ├── cronjob-admin-role.yaml
│   │   │   │   │       │   │   │   │   ├── cronjob-editor-role.yaml
│   │   │   │   │       │   │   │   │   ├── cronjob-viewer-role.yaml
│   │   │   │   │       │   │   │   │   ├── leader-election-role.yaml
│   │   │   │   │       │   │   │   │   ├── leader-election-rolebinding.yaml
│   │   │   │   │       │   │   │   │   ├── manager-role.yaml
│   │   │   │   │       │   │   │   │   ├── manager-rolebinding.yaml
│   │   │   │   │       │   │   │   │   ├── metrics-auth-role.yaml
│   │   │   │   │       │   │   │   │   ├── metrics-auth-rolebinding.yaml
│   │   │   │   │       │   │   │   │   └── metrics-reader.yaml
│   │   │   │   │       │   │   │   └── webhook/
│   │   │   │   │       │   │   │       ├── mutating-webhook-configuration.yaml
│   │   │   │   │       │   │   │       ├── validating-webhook-configuration.yaml
│   │   │   │   │       │   │   │       └── webhook-service.yaml
│   │   │   │   │       │   │   └── values.yaml
│   │   │   │   │       │   └── install.yaml
│   │   │   │   │       ├── go.mod
│   │   │   │   │       ├── go.sum
│   │   │   │   │       ├── hack/
│   │   │   │   │       │   └── boilerplate.go.txt
│   │   │   │   │       ├── internal/
│   │   │   │   │       │   ├── controller/
│   │   │   │   │       │   │   ├── cronjob_controller.go
│   │   │   │   │       │   │   ├── cronjob_controller_test.go
│   │   │   │   │       │   │   └── suite_test.go
│   │   │   │   │       │   └── webhook/
│   │   │   │   │       │       └── v1/
│   │   │   │   │       │           ├── cronjob_webhook.go
│   │   │   │   │       │           ├── cronjob_webhook_test.go
│   │   │   │   │       │           └── webhook_suite_test.go
│   │   │   │   │       └── test/
│   │   │   │   │           ├── e2e/
│   │   │   │   │           │   ├── e2e_suite_test.go
│   │   │   │   │           │   └── e2e_test.go
│   │   │   │   │           └── utils/
│   │   │   │   │               └── utils.go
│   │   │   │   ├── webhook-implementation.md
│   │   │   │   └── writing-tests.md
│   │   │   ├── faq.md
│   │   │   ├── getting-started/
│   │   │   │   └── testdata/
│   │   │   │       └── project/
│   │   │   │           ├── .custom-gcl.yml
│   │   │   │           ├── .devcontainer/
│   │   │   │           │   ├── devcontainer.json
│   │   │   │           │   └── post-install.sh
│   │   │   │           ├── .dockerignore
│   │   │   │           ├── .github/
│   │   │   │           │   └── workflows/
│   │   │   │           │       ├── auto_update.yml
│   │   │   │           │       ├── lint.yml
│   │   │   │           │       ├── test-chart.yml
│   │   │   │           │       ├── test-e2e.yml
│   │   │   │           │       └── test.yml
│   │   │   │           ├── .gitignore
│   │   │   │           ├── .golangci.yml
│   │   │   │           ├── AGENTS.md
│   │   │   │           ├── Dockerfile
│   │   │   │           ├── Makefile
│   │   │   │           ├── PROJECT
│   │   │   │           ├── README.md
│   │   │   │           ├── api/
│   │   │   │           │   └── v1alpha1/
│   │   │   │           │       ├── groupversion_info.go
│   │   │   │           │       ├── memcached_types.go
│   │   │   │           │       └── zz_generated.deepcopy.go
│   │   │   │           ├── cmd/
│   │   │   │           │   └── main.go
│   │   │   │           ├── config/
│   │   │   │           │   ├── crd/
│   │   │   │           │   │   ├── bases/
│   │   │   │           │   │   │   └── cache.example.com_memcacheds.yaml
│   │   │   │           │   │   ├── kustomization.yaml
│   │   │   │           │   │   └── kustomizeconfig.yaml
│   │   │   │           │   ├── default/
│   │   │   │           │   │   ├── cert_metrics_manager_patch.yaml
│   │   │   │           │   │   ├── kustomization.yaml
│   │   │   │           │   │   ├── manager_metrics_patch.yaml
│   │   │   │           │   │   └── metrics_service.yaml
│   │   │   │           │   ├── manager/
│   │   │   │           │   │   ├── kustomization.yaml
│   │   │   │           │   │   └── manager.yaml
│   │   │   │           │   ├── network-policy/
│   │   │   │           │   │   ├── allow-metrics-traffic.yaml
│   │   │   │           │   │   └── kustomization.yaml
│   │   │   │           │   ├── prometheus/
│   │   │   │           │   │   ├── kustomization.yaml
│   │   │   │           │   │   ├── monitor.yaml
│   │   │   │           │   │   └── monitor_tls_patch.yaml
│   │   │   │           │   ├── rbac/
│   │   │   │           │   │   ├── kustomization.yaml
│   │   │   │           │   │   ├── leader_election_role.yaml
│   │   │   │           │   │   ├── leader_election_role_binding.yaml
│   │   │   │           │   │   ├── memcached_admin_role.yaml
│   │   │   │           │   │   ├── memcached_editor_role.yaml
│   │   │   │           │   │   ├── memcached_viewer_role.yaml
│   │   │   │           │   │   ├── metrics_auth_role.yaml
│   │   │   │           │   │   ├── metrics_auth_role_binding.yaml
│   │   │   │           │   │   ├── metrics_reader_role.yaml
│   │   │   │           │   │   ├── role.yaml
│   │   │   │           │   │   ├── role_binding.yaml
│   │   │   │           │   │   └── service_account.yaml
│   │   │   │           │   └── samples/
│   │   │   │           │       ├── cache_v1alpha1_memcached.yaml
│   │   │   │           │       └── kustomization.yaml
│   │   │   │           ├── dist/
│   │   │   │           │   ├── chart/
│   │   │   │           │   │   ├── .helmignore
│   │   │   │           │   │   ├── Chart.yaml
│   │   │   │           │   │   ├── templates/
│   │   │   │           │   │   │   ├── NOTES.txt
│   │   │   │           │   │   │   ├── _helpers.tpl
│   │   │   │           │   │   │   ├── crd/
│   │   │   │           │   │   │   │   └── memcacheds.cache.example.com.yaml
│   │   │   │           │   │   │   ├── manager/
│   │   │   │           │   │   │   │   └── manager.yaml
│   │   │   │           │   │   │   ├── metrics/
│   │   │   │           │   │   │   │   └── controller-manager-metrics-service.yaml
│   │   │   │           │   │   │   ├── monitoring/
│   │   │   │           │   │   │   │   └── servicemonitor.yaml
│   │   │   │           │   │   │   └── rbac/
│   │   │   │           │   │   │       ├── controller-manager.yaml
│   │   │   │           │   │   │       ├── leader-election-role.yaml
│   │   │   │           │   │   │       ├── leader-election-rolebinding.yaml
│   │   │   │           │   │   │       ├── manager-role.yaml
│   │   │   │           │   │   │       ├── manager-rolebinding.yaml
│   │   │   │           │   │   │       ├── memcached-admin-role.yaml
│   │   │   │           │   │   │       ├── memcached-editor-role.yaml
│   │   │   │           │   │   │       ├── memcached-viewer-role.yaml
│   │   │   │           │   │   │       ├── metrics-auth-role.yaml
│   │   │   │           │   │   │       ├── metrics-auth-rolebinding.yaml
│   │   │   │           │   │   │       └── metrics-reader.yaml
│   │   │   │           │   │   └── values.yaml
│   │   │   │           │   └── install.yaml
│   │   │   │           ├── go.mod
│   │   │   │           ├── go.sum
│   │   │   │           ├── hack/
│   │   │   │           │   └── boilerplate.go.txt
│   │   │   │           ├── internal/
│   │   │   │           │   └── controller/
│   │   │   │           │       ├── memcached_controller.go
│   │   │   │           │       ├── memcached_controller_test.go
│   │   │   │           │       └── suite_test.go
│   │   │   │           └── test/
│   │   │   │               ├── e2e/
│   │   │   │               │   ├── e2e_suite_test.go
│   │   │   │               │   └── e2e_test.go
│   │   │   │               └── utils/
│   │   │   │                   └── utils.go
│   │   │   ├── getting-started.md
│   │   │   ├── introduction.md
│   │   │   ├── logos/
│   │   │   │   └── README.md
│   │   │   ├── migration/
│   │   │   │   ├── ai-helpers.md
│   │   │   │   ├── discovery-commands.md
│   │   │   │   ├── manual-process.md
│   │   │   │   ├── multi-group.md
│   │   │   │   ├── namespace-scoped.md
│   │   │   │   ├── port-code.md
│   │   │   │   └── reorganize-layout.md
│   │   │   ├── migrations.md
│   │   │   ├── multiversion-tutorial/
│   │   │   │   ├── api-changes.md
│   │   │   │   ├── conversion-concepts.md
│   │   │   │   ├── conversion.md
│   │   │   │   ├── deployment.md
│   │   │   │   ├── testdata/
│   │   │   │   │   └── project/
│   │   │   │   │       ├── .custom-gcl.yml
│   │   │   │   │       ├── .devcontainer/
│   │   │   │   │       │   ├── devcontainer.json
│   │   │   │   │       │   └── post-install.sh
│   │   │   │   │       ├── .dockerignore
│   │   │   │   │       ├── .github/
│   │   │   │   │       │   └── workflows/
│   │   │   │   │       │       ├── lint.yml
│   │   │   │   │       │       ├── test-chart.yml
│   │   │   │   │       │       ├── test-e2e.yml
│   │   │   │   │       │       └── test.yml
│   │   │   │   │       ├── .gitignore
│   │   │   │   │       ├── .golangci.yml
│   │   │   │   │       ├── AGENTS.md
│   │   │   │   │       ├── Dockerfile
│   │   │   │   │       ├── Makefile
│   │   │   │   │       ├── PROJECT
│   │   │   │   │       ├── README.md
│   │   │   │   │       ├── api/
│   │   │   │   │       │   ├── v1/
│   │   │   │   │       │   │   ├── cronjob_conversion.go
│   │   │   │   │       │   │   ├── cronjob_types.go
│   │   │   │   │       │   │   ├── groupversion_info.go
│   │   │   │   │       │   │   └── zz_generated.deepcopy.go
│   │   │   │   │       │   └── v2/
│   │   │   │   │       │       ├── cronjob_conversion.go
│   │   │   │   │       │       ├── cronjob_types.go
│   │   │   │   │       │       ├── groupversion_info.go
│   │   │   │   │       │       └── zz_generated.deepcopy.go
│   │   │   │   │       ├── cmd/
│   │   │   │   │       │   └── main.go
│   │   │   │   │       ├── config/
│   │   │   │   │       │   ├── certmanager/
│   │   │   │   │       │   │   ├── certificate-metrics.yaml
│   │   │   │   │       │   │   ├── certificate-webhook.yaml
│   │   │   │   │       │   │   ├── issuer.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   └── kustomizeconfig.yaml
│   │   │   │   │       │   ├── crd/
│   │   │   │   │       │   │   ├── bases/
│   │   │   │   │       │   │   │   └── batch.tutorial.kubebuilder.io_cronjobs.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   ├── kustomizeconfig.yaml
│   │   │   │   │       │   │   └── patches/
│   │   │   │   │       │   │       └── webhook_in_cronjobs.yaml
│   │   │   │   │       │   ├── default/
│   │   │   │   │       │   │   ├── cert_metrics_manager_patch.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   ├── manager_metrics_patch.yaml
│   │   │   │   │       │   │   ├── manager_webhook_patch.yaml
│   │   │   │   │       │   │   └── metrics_service.yaml
│   │   │   │   │       │   ├── manager/
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   └── manager.yaml
│   │   │   │   │       │   ├── network-policy/
│   │   │   │   │       │   │   ├── allow-metrics-traffic.yaml
│   │   │   │   │       │   │   ├── allow-webhook-traffic.yaml
│   │   │   │   │       │   │   └── kustomization.yaml
│   │   │   │   │       │   ├── prometheus/
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   ├── monitor.yaml
│   │   │   │   │       │   │   └── monitor_tls_patch.yaml
│   │   │   │   │       │   ├── rbac/
│   │   │   │   │       │   │   ├── cronjob_admin_role.yaml
│   │   │   │   │       │   │   ├── cronjob_editor_role.yaml
│   │   │   │   │       │   │   ├── cronjob_viewer_role.yaml
│   │   │   │   │       │   │   ├── kustomization.yaml
│   │   │   │   │       │   │   ├── leader_election_role.yaml
│   │   │   │   │       │   │   ├── leader_election_role_binding.yaml
│   │   │   │   │       │   │   ├── metrics_auth_role.yaml
│   │   │   │   │       │   │   ├── metrics_auth_role_binding.yaml
│   │   │   │   │       │   │   ├── metrics_reader_role.yaml
│   │   │   │   │       │   │   ├── role.yaml
│   │   │   │   │       │   │   ├── role_binding.yaml
│   │   │   │   │       │   │   └── service_account.yaml
│   │   │   │   │       │   ├── samples/
│   │   │   │   │       │   │   ├── batch_v1_cronjob.yaml
│   │   │   │   │       │   │   ├── batch_v2_cronjob.yaml
│   │   │   │   │       │   │   └── kustomization.yaml
│   │   │   │   │       │   └── webhook/
│   │   │   │   │       │       ├── kustomization.yaml
│   │   │   │   │       │       ├── manifests.yaml
│   │   │   │   │       │       └── service.yaml
│   │   │   │   │       ├── dist/
│   │   │   │   │       │   ├── chart/
│   │   │   │   │       │   │   ├── .helmignore
│   │   │   │   │       │   │   ├── Chart.yaml
│   │   │   │   │       │   │   ├── templates/
│   │   │   │   │       │   │   │   ├── NOTES.txt
│   │   │   │   │       │   │   │   ├── _helpers.tpl
│   │   │   │   │       │   │   │   ├── cert-manager/
│   │   │   │   │       │   │   │   │   ├── metrics-certs.yaml
│   │   │   │   │       │   │   │   │   ├── selfsigned-issuer.yaml
│   │   │   │   │       │   │   │   │   └── serving-cert.yaml
│   │   │   │   │       │   │   │   ├── crd/
│   │   │   │   │       │   │   │   │   └── cronjobs.batch.tutorial.kubebuilder.io.yaml
│   │   │   │   │       │   │   │   ├── manager/
│   │   │   │   │       │   │   │   │   └── manager.yaml
│   │   │   │   │       │   │   │   ├── metrics/
│   │   │   │   │       │   │   │   │   └── controller-manager-metrics-service.yaml
│   │   │   │   │       │   │   │   ├── prometheus/
│   │   │   │   │       │   │   │   │   └── controller-manager-metrics-monitor.yaml
│   │   │   │   │       │   │   │   ├── rbac/
│   │   │   │   │       │   │   │   │   ├── controller-manager.yaml
│   │   │   │   │       │   │   │   │   ├── cronjob-admin-role.yaml
│   │   │   │   │       │   │   │   │   ├── cronjob-editor-role.yaml
│   │   │   │   │       │   │   │   │   ├── cronjob-viewer-role.yaml
│   │   │   │   │       │   │   │   │   ├── leader-election-role.yaml
│   │   │   │   │       │   │   │   │   ├── leader-election-rolebinding.yaml
│   │   │   │   │       │   │   │   │   ├── manager-role.yaml
│   │   │   │   │       │   │   │   │   ├── manager-rolebinding.yaml
│   │   │   │   │       │   │   │   │   ├── metrics-auth-role.yaml
│   │   │   │   │       │   │   │   │   ├── metrics-auth-rolebinding.yaml
│   │   │   │   │       │   │   │   │   └── metrics-reader.yaml
│   │   │   │   │       │   │   │   └── webhook/
│   │   │   │   │       │   │   │       ├── mutating-webhook-configuration.yaml
│   │   │   │   │       │   │   │       ├── validating-webhook-configuration.yaml
│   │   │   │   │       │   │   │       └── webhook-service.yaml
│   │   │   │   │       │   │   └── values.yaml
│   │   │   │   │       │   └── install.yaml
│   │   │   │   │       ├── go.mod
│   │   │   │   │       ├── go.sum
│   │   │   │   │       ├── hack/
│   │   │   │   │       │   └── boilerplate.go.txt
│   │   │   │   │       ├── internal/
│   │   │   │   │       │   ├── controller/
│   │   │   │   │       │   │   ├── cronjob_controller.go
│   │   │   │   │       │   │   ├── cronjob_controller_test.go
│   │   │   │   │       │   │   └── suite_test.go
│   │   │   │   │       │   └── webhook/
│   │   │   │   │       │       ├── v1/
│   │   │   │   │       │       │   ├── cronjob_webhook.go
│   │   │   │   │       │       │   ├── cronjob_webhook_test.go
│   │   │   │   │       │       │   └── webhook_suite_test.go
│   │   │   │   │       │       └── v2/
│   │   │   │   │       │           ├── cronjob_webhook.go
│   │   │   │   │       │           ├── cronjob_webhook_test.go
│   │   │   │   │       │           └── webhook_suite_test.go
│   │   │   │   │       └── test/
│   │   │   │   │           ├── e2e/
│   │   │   │   │           │   ├── e2e_suite_test.go
│   │   │   │   │           │   └── e2e_test.go
│   │   │   │   │           └── utils/
│   │   │   │   │               └── utils.go
│   │   │   │   ├── tutorial.md
│   │   │   │   └── webhooks.md
│   │   │   ├── plugins/
│   │   │   │   ├── available/
│   │   │   │   │   ├── autoupdate-v1-alpha.md
│   │   │   │   │   ├── deploy-image-plugin-v1-alpha.md
│   │   │   │   │   ├── go-v4-plugin.md
│   │   │   │   │   ├── grafana-v1-alpha.md
│   │   │   │   │   ├── helm-v1-alpha.md
│   │   │   │   │   ├── helm-v2-alpha.md
│   │   │   │   │   └── kustomize-v2.md
│   │   │   │   ├── available-plugins.md
│   │   │   │   ├── extending/
│   │   │   │   │   ├── custom-markers.md
│   │   │   │   │   ├── extending_cli_features_and_plugins.md
│   │   │   │   │   ├── external-plugins.md
│   │   │   │   │   └── testing-plugins.md
│   │   │   │   ├── extending.md
│   │   │   │   ├── kustomize-v2.md
│   │   │   │   ├── plugins-versioning.md
│   │   │   │   ├── plugins.md
│   │   │   │   ├── to-add-optional-features.md
│   │   │   │   ├── to-be-extended.md
│   │   │   │   └── to-scaffold-project.md
│   │   │   ├── quick-start.md
│   │   │   ├── reference/
│   │   │   │   ├── admission-webhook.md
│   │   │   │   ├── alpha_commands.md
│   │   │   │   ├── artifacts.md
│   │   │   │   ├── commands/
│   │   │   │   │   ├── alpha_generate.md
│   │   │   │   │   └── alpha_update.md
│   │   │   │   ├── completion.md
│   │   │   │   ├── controller-gen.md
│   │   │   │   ├── crd-scope.md
│   │   │   │   ├── envtest.md
│   │   │   │   ├── generating-crd.md
│   │   │   │   ├── good-practices.md
│   │   │   │   ├── kind-config.yaml
│   │   │   │   ├── kind.md
│   │   │   │   ├── manager-scope.md
│   │   │   │   ├── markers/
│   │   │   │   │   ├── crd-processing.md
│   │   │   │   │   ├── crd-validation.md
│   │   │   │   │   ├── crd.md
│   │   │   │   │   ├── object.md
│   │   │   │   │   ├── rbac.md
│   │   │   │   │   ├── scaffold.md
│   │   │   │   │   └── webhook.md
│   │   │   │   ├── markers.md
│   │   │   │   ├── metrics-reference.md
│   │   │   │   ├── metrics.md
│   │   │   │   ├── platform.md
│   │   │   │   ├── pprof-tutorial.md
│   │   │   │   ├── project-config.md
│   │   │   │   ├── raising-events.md
│   │   │   │   ├── reference.md
│   │   │   │   ├── scopes.md
│   │   │   │   ├── submodule-layouts.md
│   │   │   │   ├── using-finalizers.md
│   │   │   │   ├── using_an_external_resource.md
│   │   │   │   ├── watching-resources/
│   │   │   │   │   ├── predicates-with-watch.md
│   │   │   │   │   ├── secondary-owned-resources.md
│   │   │   │   │   └── secondary-resources-not-owned.md
│   │   │   │   ├── watching-resources.md
│   │   │   │   ├── webhook-bootstrap-problem.md
│   │   │   │   └── webhook-overview.md
│   │   │   └── versions_compatibility_supportability.md
│   │   ├── theme/
│   │   │   ├── css/
│   │   │   │   ├── custom.css
│   │   │   │   ├── markers.css
│   │   │   │   └── version-dropdown.css
│   │   │   └── index.hbs
│   │   └── utils/
│   │       ├── go.mod
│   │       ├── go.sum
│   │       ├── litgo/
│   │       │   └── literate.go
│   │       ├── markerdocs/
│   │       │   ├── doctypes.go
│   │       │   ├── html.go
│   │       │   └── main.go
│   │       └── plugin/
│   │           ├── input.go
│   │           ├── plugin.go
│   │           └── utils.go
│   ├── kubebuilder_annotation.md
│   ├── kubebuilder_v0_v1_difference.md
│   ├── migration_guide.md
│   ├── testing/
│   │   ├── e2e.md
│   │   └── integration.md
│   └── windows.md
├── go.mod
├── go.sum
├── hack/
│   ├── docs/
│   │   ├── check.sh
│   │   ├── generate.sh
│   │   ├── generate_samples.go
│   │   └── internal/
│   │       ├── cronjob-tutorial/
│   │       │   ├── api_design.go
│   │       │   ├── controller_implementation.go
│   │       │   ├── e2e_implementation.go
│   │       │   ├── generate_cronjob.go
│   │       │   ├── main_revisited.go
│   │       │   ├── other_api_files.go
│   │       │   ├── sample.go
│   │       │   ├── webhook_implementation.go
│   │       │   ├── writing_tests_controller.go
│   │       │   └── writing_tests_env.go
│   │       ├── getting-started/
│   │       │   └── generate_getting_started.go
│   │       ├── multiversion-tutorial/
│   │       │   ├── controller_tests_code.go
│   │       │   ├── cronjob_v1.go
│   │       │   ├── cronjob_v2.go
│   │       │   ├── generate_multiversion.go
│   │       │   ├── hub.go
│   │       │   ├── samples.go
│   │       │   └── webhook_v2_implementaton.go
│   │       └── utils/
│   │           └── utils.go
│   └── test/
│       └── check_go_module.go
├── internal/
│   ├── cli/
│   │   ├── alpha/
│   │   │   ├── generate.go
│   │   │   ├── generate_test.go
│   │   │   ├── internal/
│   │   │   │   ├── common/
│   │   │   │   │   ├── common.go
│   │   │   │   │   ├── common_test.go
│   │   │   │   │   └── suite_test.go
│   │   │   │   ├── generate.go
│   │   │   │   ├── generate_test.go
│   │   │   │   ├── update/
│   │   │   │   │   ├── helpers/
│   │   │   │   │   │   ├── conflict.go
│   │   │   │   │   │   ├── conflict_test.go
│   │   │   │   │   │   ├── download.go
│   │   │   │   │   │   ├── download_test.go
│   │   │   │   │   │   ├── git_commands.go
│   │   │   │   │   │   ├── open_gh_issue.go
│   │   │   │   │   │   ├── open_gh_issue_test.go
│   │   │   │   │   │   └── suite_test.go
│   │   │   │   │   ├── integration_test.go
│   │   │   │   │   ├── prepare.go
│   │   │   │   │   ├── prepare_test.go
│   │   │   │   │   ├── suite_test.go
│   │   │   │   │   ├── update.go
│   │   │   │   │   ├── update_test.go
│   │   │   │   │   ├── validate.go
│   │   │   │   │   └── validate_test.go
│   │   │   │   └── update.go
│   │   │   ├── suite_test.go
│   │   │   ├── update.go
│   │   │   └── update_test.go
│   │   ├── cmd/
│   │   │   └── cmd.go
│   │   └── version/
│   │       ├── version.go
│   │       └── version_test.go
│   └── logging/
│       └── handler.go
├── main.go
├── netlify.toml
├── pkg/
│   ├── cli/
│   │   ├── alpha.go
│   │   ├── api.go
│   │   ├── cli.go
│   │   ├── cli_test.go
│   │   ├── cmd_helpers.go
│   │   ├── cmd_helpers_test.go
│   │   ├── completion.go
│   │   ├── completion_test.go
│   │   ├── create.go
│   │   ├── doc.go
│   │   ├── edit.go
│   │   ├── init.go
│   │   ├── init_test.go
│   │   ├── options.go
│   │   ├── options_test.go
│   │   ├── resource.go
│   │   ├── resource_test.go
│   │   ├── root.go
│   │   ├── suite_test.go
│   │   ├── version.go
│   │   ├── version_test.go
│   │   ├── webhook.go
│   │   └── webhook_test.go
│   ├── config/
│   │   ├── errors.go
│   │   ├── errors_test.go
│   │   ├── interface.go
│   │   ├── registry.go
│   │   ├── registry_test.go
│   │   ├── store/
│   │   │   ├── errors.go
│   │   │   ├── errors_test.go
│   │   │   ├── interface.go
│   │   │   └── yaml/
│   │   │       ├── store.go
│   │   │       └── store_test.go
│   │   ├── suite_test.go
│   │   ├── v3/
│   │   │   ├── config.go
│   │   │   └── config_test.go
│   │   ├── version.go
│   │   └── version_test.go
│   ├── machinery/
│   │   ├── errors.go
│   │   ├── errors_test.go
│   │   ├── file.go
│   │   ├── filesystem.go
│   │   ├── funcmap.go
│   │   ├── funcmap_test.go
│   │   ├── injector.go
│   │   ├── injector_test.go
│   │   ├── interfaces.go
│   │   ├── machinery_suite_test.go
│   │   ├── marker.go
│   │   ├── marker_test.go
│   │   ├── mixins.go
│   │   ├── mixins_delim_test.go
│   │   ├── mixins_test.go
│   │   ├── scaffold.go
│   │   └── scaffold_test.go
│   ├── model/
│   │   ├── resource/
│   │   │   ├── api.go
│   │   │   ├── api_test.go
│   │   │   ├── gvk.go
│   │   │   ├── gvk_test.go
│   │   │   ├── resource.go
│   │   │   ├── resource_test.go
│   │   │   ├── suite_test.go
│   │   │   ├── utils.go
│   │   │   ├── utils_test.go
│   │   │   ├── webhooks.go
│   │   │   ├── webhooks_copy_test.go
│   │   │   └── webhooks_test.go
│   │   └── stage/
│   │       ├── stage.go
│   │       └── stage_test.go
│   ├── plugin/
│   │   ├── bundle.go
│   │   ├── bundle_test.go
│   │   ├── errors.go
│   │   ├── errors_test.go
│   │   ├── external/
│   │   │   └── types.go
│   │   ├── filter.go
│   │   ├── filter_test.go
│   │   ├── helpers.go
│   │   ├── helpers_test.go
│   │   ├── metadata.go
│   │   ├── plugin.go
│   │   ├── subcommand.go
│   │   ├── suite_test.go
│   │   ├── util/
│   │   │   ├── exec.go
│   │   │   ├── exec_test.go
│   │   │   ├── stdin.go
│   │   │   ├── stdin_test.go
│   │   │   ├── suite_test.go
│   │   │   ├── util.go
│   │   │   └── util_test.go
│   │   ├── version.go
│   │   └── version_test.go
│   └── plugins/
│       ├── common/
│       │   └── kustomize/
│       │       └── v2/
│       │           ├── api.go
│       │           ├── create.go
│       │           ├── create_test.go
│       │           ├── init.go
│       │           ├── init_test.go
│       │           ├── plugin.go
│       │           ├── plugin_test.go
│       │           ├── scaffolds/
│       │           │   ├── api.go
│       │           │   ├── edit.go
│       │           │   ├── init.go
│       │           │   ├── internal/
│       │           │   │   └── templates/
│       │           │   │       └── config/
│       │           │   │           ├── certmanager/
│       │           │   │           │   ├── certificate_metrics.go
│       │           │   │           │   ├── certificate_webhook.go
│       │           │   │           │   ├── issuer.go
│       │           │   │           │   ├── kustomization.go
│       │           │   │           │   └── kustomizeconfig.go
│       │           │   │           ├── crd/
│       │           │   │           │   ├── kustomization.go
│       │           │   │           │   ├── kustomizeconfig.go
│       │           │   │           │   └── patches/
│       │           │   │           │       ├── enablecainjection_patch.go
│       │           │   │           │       └── enablewebhook_patch.go
│       │           │   │           ├── kdefault/
│       │           │   │           │   ├── cert_metrics_manager_patch.go
│       │           │   │           │   ├── kustomization.go
│       │           │   │           │   ├── kustomization_conversion_updater.go
│       │           │   │           │   ├── manager_metrics_patch.go
│       │           │   │           │   ├── metrics_service.go
│       │           │   │           │   └── webhook_manager_patch.go
│       │           │   │           ├── manager/
│       │           │   │           │   ├── config.go
│       │           │   │           │   └── kustomization.go
│       │           │   │           ├── network-policy/
│       │           │   │           │   ├── allow-metrics-traffic.go
│       │           │   │           │   ├── allow-webhook-traffic.go
│       │           │   │           │   └── kustomization.go
│       │           │   │           ├── prometheus/
│       │           │   │           │   ├── kustomization.go
│       │           │   │           │   ├── monitor.go
│       │           │   │           │   └── monitor_tls_patch.go
│       │           │   │           ├── rbac/
│       │           │   │           │   ├── cluster_role.go
│       │           │   │           │   ├── cluster_role_binding.go
│       │           │   │           │   ├── crd_admin_role.go
│       │           │   │           │   ├── crd_editor_role.go
│       │           │   │           │   ├── crd_viewer_role.go
│       │           │   │           │   ├── kustomization.go
│       │           │   │           │   ├── leader_election_role.go
│       │           │   │           │   ├── leader_election_role_binding.go
│       │           │   │           │   ├── metrics_auth_role.go
│       │           │   │           │   ├── metrics_auth_role_binding.go
│       │           │   │           │   ├── metrics_reader_role.go
│       │           │   │           │   ├── namespaced_role.go
│       │           │   │           │   ├── namespaced_role_binding.go
│       │           │   │           │   └── service_account.go
│       │           │   │           ├── samples/
│       │           │   │           │   ├── crd_sample.go
│       │           │   │           │   └── kustomization.go
│       │           │   │           └── webhook/
│       │           │   │               ├── kustomization.go
│       │           │   │               └── service.go
│       │           │   └── webhook.go
│       │           ├── suite_test.go
│       │           └── webhook.go
│       ├── domain.go
│       ├── external/
│       │   ├── api.go
│       │   ├── edit.go
│       │   ├── external_test.go
│       │   ├── helpers.go
│       │   ├── helpers_test.go
│       │   ├── init.go
│       │   ├── plugin.go
│       │   └── webhook.go
│       ├── golang/
│       │   ├── deploy-image/
│       │   │   └── v1alpha1/
│       │   │       ├── api.go
│       │   │       ├── api_test.go
│       │   │       ├── plugin.go
│       │   │       ├── plugin_test.go
│       │   │       ├── scaffolds/
│       │   │       │   ├── api.go
│       │   │       │   └── internal/
│       │   │       │       └── templates/
│       │   │       │           ├── api/
│       │   │       │           │   └── types.go
│       │   │       │           ├── config/
│       │   │       │           │   └── samples/
│       │   │       │           │       └── crd_sample.go
│       │   │       │           └── controllers/
│       │   │       │               ├── controller-test.go
│       │   │       │               └── controller.go
│       │   │       └── suite_test.go
│       │   ├── domain.go
│       │   ├── go_version.go
│       │   ├── go_version_test.go
│       │   ├── options.go
│       │   ├── options_test.go
│       │   ├── repository.go
│       │   ├── repository_test.go
│       │   ├── suite_test.go
│       │   └── v4/
│       │       ├── api.go
│       │       ├── api_test.go
│       │       ├── edit.go
│       │       ├── edit_test.go
│       │       ├── init.go
│       │       ├── init_test.go
│       │       ├── plugin.go
│       │       ├── plugin_test.go
│       │       ├── scaffolds/
│       │       │   ├── api.go
│       │       │   ├── doc.go
│       │       │   ├── edit.go
│       │       │   ├── edit_integration_test.go
│       │       │   ├── init.go
│       │       │   ├── init_integration_test.go
│       │       │   ├── internal/
│       │       │   │   └── templates/
│       │       │   │       ├── agents.go
│       │       │   │       ├── api/
│       │       │   │       │   ├── group.go
│       │       │   │       │   ├── hub.go
│       │       │   │       │   ├── spoke.go
│       │       │   │       │   ├── types.go
│       │       │   │       │   └── types_updater.go
│       │       │   │       ├── cmd/
│       │       │   │       │   └── main.go
│       │       │   │       ├── controllers/
│       │       │   │       │   ├── controller.go
│       │       │   │       │   ├── controller_suitetest.go
│       │       │   │       │   └── controller_test_template.go
│       │       │   │       ├── customgcl.go
│       │       │   │       ├── devcontainer.go
│       │       │   │       ├── dockerfile.go
│       │       │   │       ├── dockerignore.go
│       │       │   │       ├── github/
│       │       │   │       │   ├── lint.go
│       │       │   │       │   ├── test-e2e.go
│       │       │   │       │   └── test.go
│       │       │   │       ├── gitignore.go
│       │       │   │       ├── golangci.go
│       │       │   │       ├── gomod.go
│       │       │   │       ├── hack/
│       │       │   │       │   └── boilerplate.go
│       │       │   │       ├── makefile.go
│       │       │   │       ├── readme.go
│       │       │   │       ├── test/
│       │       │   │       │   ├── e2e/
│       │       │   │       │   │   ├── suite.go
│       │       │   │       │   │   └── test.go
│       │       │   │       │   └── utils/
│       │       │   │       │       └── utils.go
│       │       │   │       └── webhooks/
│       │       │   │           ├── webhook.go
│       │       │   │           ├── webhook_suitetest.go
│       │       │   │           ├── webhook_test_template.go
│       │       │   │           ├── webhook_test_updater.go
│       │       │   │           └── webhook_updater.go
│       │       │   ├── suite_test.go
│       │       │   ├── webhook.go
│       │       │   └── webhook_test.go
│       │       ├── suite_test.go
│       │       ├── webhook.go
│       │       └── webhook_test.go
│       ├── optional/
│       │   ├── autoupdate/
│       │   │   └── v1alpha/
│       │   │       ├── edit.go
│       │   │       ├── edit_test.go
│       │   │       ├── init.go
│       │   │       ├── plugin.go
│       │   │       ├── plugin_test.go
│       │   │       ├── scaffolds/
│       │   │       │   ├── init.go
│       │   │       │   └── internal/
│       │   │       │       └── github/
│       │   │       │           └── auto_update.go
│       │   │       └── suite_test.go
│       │   ├── grafana/
│       │   │   └── v1alpha/
│       │   │       ├── commons.go
│       │   │       ├── constants.go
│       │   │       ├── edit.go
│       │   │       ├── init.go
│       │   │       ├── plugin.go
│       │   │       └── scaffolds/
│       │   │           ├── edit.go
│       │   │           ├── edit_test.go
│       │   │           ├── init.go
│       │   │           ├── init_test.go
│       │   │           ├── internal/
│       │   │           │   └── templates/
│       │   │           │       ├── custom.go
│       │   │           │       ├── custom_metrics.go
│       │   │           │       ├── resources.go
│       │   │           │       └── runtime.go
│       │   │           ├── scaffolds_test.go
│       │   │           └── suite_test.go
│       │   └── helm/
│       │       ├── v1alpha/
│       │       │   ├── commons.go
│       │       │   ├── edit.go
│       │       │   ├── plugin.go
│       │       │   └── scaffolds/
│       │       │       ├── edit.go
│       │       │       └── internal/
│       │       │           └── templates/
│       │       │               ├── chart-templates/
│       │       │               │   ├── cert-manager/
│       │       │               │   │   └── certificate.go
│       │       │               │   ├── helpers_tpl.go
│       │       │               │   ├── manager/
│       │       │               │   │   └── manager.go
│       │       │               │   ├── metrics/
│       │       │               │   │   └── metrics_service.go
│       │       │               │   ├── prometheus/
│       │       │               │   │   └── monitor.go
│       │       │               │   └── webhook/
│       │       │               │       ├── service.go
│       │       │               │       └── webhook.go
│       │       │               ├── chart.go
│       │       │               ├── github/
│       │       │               │   └── test_chart.go
│       │       │               ├── helmignore.go
│       │       │               └── values.go
│       │       └── v2alpha/
│       │           ├── edit.go
│       │           ├── edit_test.go
│       │           ├── makefile_test.go
│       │           ├── plugin.go
│       │           ├── plugin_test.go
│       │           ├── scaffolds/
│       │           │   ├── chart_generation_integration_test.go
│       │           │   ├── chart_never_overwrite_test.go
│       │           │   ├── edit_kustomize.go
│       │           │   ├── extras_integration_test.go
│       │           │   ├── force_integration_test.go
│       │           │   ├── internal/
│       │           │   │   ├── kustomize/
│       │           │   │   │   ├── chart_converter.go
│       │           │   │   │   ├── chart_converter_test.go
│       │           │   │   │   ├── chart_writer.go
│       │           │   │   │   ├── helm_templater.go
│       │           │   │   │   ├── helm_templater_test.go
│       │           │   │   │   ├── parser.go
│       │           │   │   │   ├── parser_test.go
│       │           │   │   │   ├── resource_organizer.go
│       │           │   │   │   └── suite_test.go
│       │           │   │   └── templates/
│       │           │   │       ├── chart-templates/
│       │           │   │       │   ├── consts.go
│       │           │   │       │   ├── helpers_tpl.go
│       │           │   │       │   ├── notes.go
│       │           │   │       │   ├── notes_test.go
│       │           │   │       │   ├── servicemonitor.go
│       │           │   │       │   └── suite_test.go
│       │           │   │       ├── chart.go
│       │           │   │       ├── github/
│       │           │   │       │   └── test_chart.go
│       │           │   │       ├── helmignore.go
│       │           │   │       ├── suite_test.go
│       │           │   │       ├── values_basic.go
│       │           │   │       └── values_basic_test.go
│       │           │   └── suite_test.go
│       │           └── suite_test.go
│       └── scaffolder.go
├── roadmap/
│   ├── README.md
│   ├── roadmap_2024.md
│   ├── roadmap_2025.md
│   └── roadmap_2026.md
├── test/
│   ├── check-docs-only.sh
│   ├── check-license.sh
│   ├── check_spaces.sh
│   ├── common.sh
│   ├── e2e/
│   │   ├── all/
│   │   │   ├── e2e_suite_test.go
│   │   │   ├── plugin_deployimage_test.go
│   │   │   ├── plugin_helm_test.go
│   │   │   └── plugin_v4_test.go
│   │   ├── ci.sh
│   │   ├── internal/
│   │   │   └── helpers/
│   │   │       ├── generate_v4.go
│   │   │       ├── plugin_test_helper.go
│   │   │       └── plugin_test_metrics.go
│   │   ├── kind-config.yaml
│   │   ├── local.sh
│   │   ├── setup.sh
│   │   └── utils/
│   │       ├── kubectl.go
│   │       ├── kubectl_test.go
│   │       ├── suite_test.go
│   │       ├── test_context.go
│   │       └── webhooks.go
│   └── testdata/
│       ├── check.sh
│       ├── generate.sh
│       ├── legacy-webhook-path.sh
│       ├── test.sh
│       └── test_legacy.sh
├── test.sh
├── test_e2e.sh
└── testdata/
    ├── project-v4/
    │   ├── .custom-gcl.yml
    │   ├── .devcontainer/
    │   │   ├── devcontainer.json
    │   │   └── post-install.sh
    │   ├── .dockerignore
    │   ├── .github/
    │   │   └── workflows/
    │   │       ├── lint.yml
    │   │       ├── test-e2e.yml
    │   │       └── test.yml
    │   ├── .gitignore
    │   ├── .golangci.yml
    │   ├── AGENTS.md
    │   ├── Dockerfile
    │   ├── Makefile
    │   ├── PROJECT
    │   ├── README.md
    │   ├── api/
    │   │   ├── v1/
    │   │   │   ├── admiral_types.go
    │   │   │   ├── captain_types.go
    │   │   │   ├── firstmate_conversion.go
    │   │   │   ├── firstmate_types.go
    │   │   │   ├── groupversion_info.go
    │   │   │   ├── sailor_types.go
    │   │   │   └── zz_generated.deepcopy.go
    │   │   └── v2/
    │   │       ├── firstmate_conversion.go
    │   │       ├── firstmate_types.go
    │   │       ├── groupversion_info.go
    │   │       └── zz_generated.deepcopy.go
    │   ├── cmd/
    │   │   └── main.go
    │   ├── config/
    │   │   ├── certmanager/
    │   │   │   ├── certificate-metrics.yaml
    │   │   │   ├── certificate-webhook.yaml
    │   │   │   ├── issuer.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   └── kustomizeconfig.yaml
    │   │   ├── crd/
    │   │   │   ├── bases/
    │   │   │   │   ├── crew.testproject.org_admirales.yaml
    │   │   │   │   ├── crew.testproject.org_captains.yaml
    │   │   │   │   ├── crew.testproject.org_firstmates.yaml
    │   │   │   │   └── crew.testproject.org_sailors.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── kustomizeconfig.yaml
    │   │   │   └── patches/
    │   │   │       └── webhook_in_firstmates.yaml
    │   │   ├── default/
    │   │   │   ├── cert_metrics_manager_patch.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── manager_metrics_patch.yaml
    │   │   │   ├── manager_webhook_patch.yaml
    │   │   │   └── metrics_service.yaml
    │   │   ├── manager/
    │   │   │   ├── kustomization.yaml
    │   │   │   └── manager.yaml
    │   │   ├── network-policy/
    │   │   │   ├── allow-metrics-traffic.yaml
    │   │   │   ├── allow-webhook-traffic.yaml
    │   │   │   └── kustomization.yaml
    │   │   ├── prometheus/
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── monitor.yaml
    │   │   │   └── monitor_tls_patch.yaml
    │   │   ├── rbac/
    │   │   │   ├── admiral_admin_role.yaml
    │   │   │   ├── admiral_editor_role.yaml
    │   │   │   ├── admiral_viewer_role.yaml
    │   │   │   ├── captain_admin_role.yaml
    │   │   │   ├── captain_editor_role.yaml
    │   │   │   ├── captain_viewer_role.yaml
    │   │   │   ├── firstmate_admin_role.yaml
    │   │   │   ├── firstmate_editor_role.yaml
    │   │   │   ├── firstmate_viewer_role.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── leader_election_role.yaml
    │   │   │   ├── leader_election_role_binding.yaml
    │   │   │   ├── metrics_auth_role.yaml
    │   │   │   ├── metrics_auth_role_binding.yaml
    │   │   │   ├── metrics_reader_role.yaml
    │   │   │   ├── role.yaml
    │   │   │   ├── role_binding.yaml
    │   │   │   ├── sailor_admin_role.yaml
    │   │   │   ├── sailor_editor_role.yaml
    │   │   │   ├── sailor_viewer_role.yaml
    │   │   │   └── service_account.yaml
    │   │   ├── samples/
    │   │   │   ├── crew_v1_admiral.yaml
    │   │   │   ├── crew_v1_captain.yaml
    │   │   │   ├── crew_v1_firstmate.yaml
    │   │   │   ├── crew_v1_sailor.yaml
    │   │   │   ├── crew_v2_firstmate.yaml
    │   │   │   └── kustomization.yaml
    │   │   └── webhook/
    │   │       ├── kustomization.yaml
    │   │       ├── manifests.yaml
    │   │       └── service.yaml
    │   ├── dist/
    │   │   └── install.yaml
    │   ├── go.mod
    │   ├── hack/
    │   │   └── boilerplate.go.txt
    │   ├── internal/
    │   │   ├── controller/
    │   │   │   ├── admiral_controller.go
    │   │   │   ├── admiral_controller_test.go
    │   │   │   ├── captain_controller.go
    │   │   │   ├── captain_controller_test.go
    │   │   │   ├── certificate_controller.go
    │   │   │   ├── certificate_controller_test.go
    │   │   │   ├── firstmate_controller.go
    │   │   │   ├── firstmate_controller_test.go
    │   │   │   ├── sailor_controller.go
    │   │   │   ├── sailor_controller_test.go
    │   │   │   └── suite_test.go
    │   │   └── webhook/
    │   │       └── v1/
    │   │           ├── admiral_webhook.go
    │   │           ├── admiral_webhook_test.go
    │   │           ├── captain_webhook.go
    │   │           ├── captain_webhook_test.go
    │   │           ├── deployment_webhook.go
    │   │           ├── deployment_webhook_test.go
    │   │           ├── firstmate_webhook.go
    │   │           ├── firstmate_webhook_test.go
    │   │           ├── issuer_webhook.go
    │   │           ├── issuer_webhook_test.go
    │   │           ├── pod_webhook.go
    │   │           ├── pod_webhook_test.go
    │   │           ├── sailor_webhook.go
    │   │           ├── sailor_webhook_test.go
    │   │           └── webhook_suite_test.go
    │   └── test/
    │       ├── e2e/
    │       │   ├── e2e_suite_test.go
    │       │   └── e2e_test.go
    │       └── utils/
    │           └── utils.go
    ├── project-v4-multigroup/
    │   ├── .custom-gcl.yml
    │   ├── .devcontainer/
    │   │   ├── devcontainer.json
    │   │   └── post-install.sh
    │   ├── .dockerignore
    │   ├── .github/
    │   │   └── workflows/
    │   │       ├── lint.yml
    │   │       ├── test-e2e.yml
    │   │       └── test.yml
    │   ├── .gitignore
    │   ├── .golangci.yml
    │   ├── AGENTS.md
    │   ├── Dockerfile
    │   ├── Makefile
    │   ├── PROJECT
    │   ├── README.md
    │   ├── api/
    │   │   ├── crew/
    │   │   │   └── v1/
    │   │   │       ├── captain_types.go
    │   │   │       ├── groupversion_info.go
    │   │   │       └── zz_generated.deepcopy.go
    │   │   ├── example.com/
    │   │   │   ├── v1/
    │   │   │   │   ├── groupversion_info.go
    │   │   │   │   ├── wordpress_conversion.go
    │   │   │   │   ├── wordpress_types.go
    │   │   │   │   └── zz_generated.deepcopy.go
    │   │   │   ├── v1alpha1/
    │   │   │   │   ├── busybox_types.go
    │   │   │   │   ├── groupversion_info.go
    │   │   │   │   ├── memcached_types.go
    │   │   │   │   └── zz_generated.deepcopy.go
    │   │   │   └── v2/
    │   │   │       ├── groupversion_info.go
    │   │   │       ├── wordpress_conversion.go
    │   │   │       ├── wordpress_types.go
    │   │   │       └── zz_generated.deepcopy.go
    │   │   ├── fiz/
    │   │   │   └── v1/
    │   │   │       ├── bar_types.go
    │   │   │       ├── groupversion_info.go
    │   │   │       └── zz_generated.deepcopy.go
    │   │   ├── foo/
    │   │   │   └── v1/
    │   │   │       ├── bar_types.go
    │   │   │       ├── groupversion_info.go
    │   │   │       └── zz_generated.deepcopy.go
    │   │   ├── foo.policy/
    │   │   │   └── v1/
    │   │   │       ├── groupversion_info.go
    │   │   │       ├── healthcheckpolicy_types.go
    │   │   │       └── zz_generated.deepcopy.go
    │   │   ├── sea-creatures/
    │   │   │   ├── v1beta1/
    │   │   │   │   ├── groupversion_info.go
    │   │   │   │   ├── kraken_types.go
    │   │   │   │   └── zz_generated.deepcopy.go
    │   │   │   └── v1beta2/
    │   │   │       ├── groupversion_info.go
    │   │   │       ├── leviathan_types.go
    │   │   │       └── zz_generated.deepcopy.go
    │   │   └── ship/
    │   │       ├── v1/
    │   │       │   ├── destroyer_types.go
    │   │       │   ├── groupversion_info.go
    │   │       │   └── zz_generated.deepcopy.go
    │   │       ├── v1beta1/
    │   │       │   ├── frigate_types.go
    │   │       │   ├── groupversion_info.go
    │   │       │   └── zz_generated.deepcopy.go
    │   │       └── v2alpha1/
    │   │           ├── cruiser_types.go
    │   │           ├── groupversion_info.go
    │   │           └── zz_generated.deepcopy.go
    │   ├── cmd/
    │   │   └── main.go
    │   ├── config/
    │   │   ├── certmanager/
    │   │   │   ├── certificate-metrics.yaml
    │   │   │   ├── certificate-webhook.yaml
    │   │   │   ├── issuer.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   └── kustomizeconfig.yaml
    │   │   ├── crd/
    │   │   │   ├── bases/
    │   │   │   │   ├── crew.testproject.org_captains.yaml
    │   │   │   │   ├── example.com.testproject.org_busyboxes.yaml
    │   │   │   │   ├── example.com.testproject.org_memcacheds.yaml
    │   │   │   │   ├── example.com.testproject.org_wordpresses.yaml
    │   │   │   │   ├── fiz.testproject.org_bars.yaml
    │   │   │   │   ├── foo.policy.testproject.org_healthcheckpolicies.yaml
    │   │   │   │   ├── foo.testproject.org_bars.yaml
    │   │   │   │   ├── sea-creatures.testproject.org_krakens.yaml
    │   │   │   │   ├── sea-creatures.testproject.org_leviathans.yaml
    │   │   │   │   ├── ship.testproject.org_cruisers.yaml
    │   │   │   │   ├── ship.testproject.org_destroyers.yaml
    │   │   │   │   └── ship.testproject.org_frigates.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── kustomizeconfig.yaml
    │   │   │   └── patches/
    │   │   │       └── webhook_in_example.com_wordpresses.yaml
    │   │   ├── default/
    │   │   │   ├── cert_metrics_manager_patch.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── manager_metrics_patch.yaml
    │   │   │   ├── manager_webhook_patch.yaml
    │   │   │   └── metrics_service.yaml
    │   │   ├── manager/
    │   │   │   ├── kustomization.yaml
    │   │   │   └── manager.yaml
    │   │   ├── network-policy/
    │   │   │   ├── allow-metrics-traffic.yaml
    │   │   │   ├── allow-webhook-traffic.yaml
    │   │   │   └── kustomization.yaml
    │   │   ├── prometheus/
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── monitor.yaml
    │   │   │   └── monitor_tls_patch.yaml
    │   │   ├── rbac/
    │   │   │   ├── crew_captain_admin_role.yaml
    │   │   │   ├── crew_captain_editor_role.yaml
    │   │   │   ├── crew_captain_viewer_role.yaml
    │   │   │   ├── example.com_busybox_admin_role.yaml
    │   │   │   ├── example.com_busybox_editor_role.yaml
    │   │   │   ├── example.com_busybox_viewer_role.yaml
    │   │   │   ├── example.com_memcached_admin_role.yaml
    │   │   │   ├── example.com_memcached_editor_role.yaml
    │   │   │   ├── example.com_memcached_viewer_role.yaml
    │   │   │   ├── example.com_wordpress_admin_role.yaml
    │   │   │   ├── example.com_wordpress_editor_role.yaml
    │   │   │   ├── example.com_wordpress_viewer_role.yaml
    │   │   │   ├── fiz_bar_admin_role.yaml
    │   │   │   ├── fiz_bar_editor_role.yaml
    │   │   │   ├── fiz_bar_viewer_role.yaml
    │   │   │   ├── foo.policy_healthcheckpolicy_admin_role.yaml
    │   │   │   ├── foo.policy_healthcheckpolicy_editor_role.yaml
    │   │   │   ├── foo.policy_healthcheckpolicy_viewer_role.yaml
    │   │   │   ├── foo_bar_admin_role.yaml
    │   │   │   ├── foo_bar_editor_role.yaml
    │   │   │   ├── foo_bar_viewer_role.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── leader_election_role.yaml
    │   │   │   ├── leader_election_role_binding.yaml
    │   │   │   ├── metrics_auth_role.yaml
    │   │   │   ├── metrics_auth_role_binding.yaml
    │   │   │   ├── metrics_reader_role.yaml
    │   │   │   ├── role.yaml
    │   │   │   ├── role_binding.yaml
    │   │   │   ├── sea-creatures_kraken_admin_role.yaml
    │   │   │   ├── sea-creatures_kraken_editor_role.yaml
    │   │   │   ├── sea-creatures_kraken_viewer_role.yaml
    │   │   │   ├── sea-creatures_leviathan_admin_role.yaml
    │   │   │   ├── sea-creatures_leviathan_editor_role.yaml
    │   │   │   ├── sea-creatures_leviathan_viewer_role.yaml
    │   │   │   ├── service_account.yaml
    │   │   │   ├── ship_cruiser_admin_role.yaml
    │   │   │   ├── ship_cruiser_editor_role.yaml
    │   │   │   ├── ship_cruiser_viewer_role.yaml
    │   │   │   ├── ship_destroyer_admin_role.yaml
    │   │   │   ├── ship_destroyer_editor_role.yaml
    │   │   │   ├── ship_destroyer_viewer_role.yaml
    │   │   │   ├── ship_frigate_admin_role.yaml
    │   │   │   ├── ship_frigate_editor_role.yaml
    │   │   │   └── ship_frigate_viewer_role.yaml
    │   │   ├── samples/
    │   │   │   ├── crew_v1_captain.yaml
    │   │   │   ├── example.com_v1_wordpress.yaml
    │   │   │   ├── example.com_v1alpha1_busybox.yaml
    │   │   │   ├── example.com_v1alpha1_memcached.yaml
    │   │   │   ├── example.com_v2_wordpress.yaml
    │   │   │   ├── fiz_v1_bar.yaml
    │   │   │   ├── foo.policy_v1_healthcheckpolicy.yaml
    │   │   │   ├── foo_v1_bar.yaml
    │   │   │   ├── kustomization.yaml
    │   │   │   ├── sea-creatures_v1beta1_kraken.yaml
    │   │   │   ├── sea-creatures_v1beta2_leviathan.yaml
    │   │   │   ├── ship_v1_destroyer.yaml
    │   │   │   ├── ship_v1beta1_frigate.yaml
    │   │   │   └── ship_v2alpha1_cruiser.yaml
    │   │   └── webhook/
    │   │       ├── kustomization.yaml
    │   │       ├── manifests.yaml
    │   │       └── service.yaml
    │   ├── dist/
    │   │   └── install.yaml
    │   ├── go.mod
    │   ├── grafana/
    │   │   ├── controller-resources-metrics.json
    │   │   ├── controller-runtime-metrics.json
    │   │   └── custom-metrics/
    │   │       └── config.yaml
    │   ├── hack/
    │   │   └── boilerplate.go.txt
    │   ├── internal/
    │   │   ├── controller/
    │   │   │   ├── apps/
    │   │   │   │   ├── deployment_controller.go
    │   │   │   │   ├── deployment_controller_test.go
    │   │   │   │   └── suite_test.go
    │   │   │   ├── cert-manager/
    │   │   │   │   ├── certificate_controller.go
    │   │   │   │   ├── certificate_controller_test.go
    │   │   │   │   └── suite_test.go
    │   │   │   ├── crew/
    │   │   │   │   ├── captain_controller.go
    │   │   │   │   ├── captain_controller_test.go
    │   │   │   │   └── suite_test.go
    │   │   │   ├── example.com/
    │   │   │   │   ├── busybox_controller.go
    │   │   │   │   ├── busybox_controller_test.go
    │   │   │   │   ├── memcached_controller.go
    │   │   │   │   ├── memcached_controller_test.go
    │   │   │   │   ├── suite_test.go
    │   │   │   │   ├── wordpress_controller.go
    │   │   │   │   └── wordpress_controller_test.go
    │   │   │   ├── fiz/
    │   │   │   │   ├── bar_controller.go
    │   │   │   │   ├── bar_controller_test.go
    │   │   │   │   └── suite_test.go
    │   │   │   ├── foo/
    │   │   │   │   ├── bar_controller.go
    │   │   │   │   ├── bar_controller_test.go
    │   │   │   │   └── suite_test.go
    │   │   │   ├── foo.policy/
    │   │   │   │   ├── healthcheckpolicy_controller.go
    │   │   │   │   ├── healthcheckpolicy_controller_test.go
    │   │   │   │   └── suite_test.go
    │   │   │   ├── sea-creatures/
    │   │   │   │   ├── kraken_controller.go
    │   │   │   │   ├── kraken_controller_test.go
    │   │   │   │   ├── leviathan_controller.go
    │   │   │   │   ├── leviathan_controller_test.go
    │   │   │   │   └── suite_test.go
    │   │   │   └── ship/
    │   │   │       ├── cruiser_controller.go
    │   │   │       ├── cruiser_controller_test.go
    │   │   │       ├── destroyer_controller.go
    │   │   │       ├── destroyer_controller_test.go
    │   │   │       ├── frigate_controller.go
    │   │   │       ├── frigate_controller_test.go
    │   │   │       └── suite_test.go
    │   │   └── webhook/
    │   │       ├── apps/
    │   │       │   └── v1/
    │   │       │       ├── deployment_webhook.go
    │   │       │       ├── deployment_webhook_test.go
    │   │       │       └── webhook_suite_test.go
    │   │       ├── cert-manager/
    │   │       │   └── v1/
    │   │       │       ├── issuer_webhook.go
    │   │       │       ├── issuer_webhook_test.go
    │   │       │       └── webhook_suite_test.go
    │   │       ├── core/
    │   │       │   └── v1/
    │   │       │       ├── pod_webhook.go
    │   │       │       ├── pod_webhook_test.go
    │   │       │       └── webhook_suite_test.go
    │   │       ├── crew/
    │   │       │   └── v1/
    │   │       │       ├── captain_webhook.go
    │   │       │       ├── captain_webhook_test.go
    │   │       │       └── webhook_suite_test.go
    │   │       ├── example.com/
    │   │       │   ├── v1/
    │   │       │   │   ├── webhook_suite_test.go
    │   │       │   │   ├── wordpress_webhook.go
    │   │       │   │   └── wordpress_webhook_test.go
    │   │       │   └── v1alpha1/
    │   │       │       ├── memcached_webhook.go
    │   │       │       ├── memcached_webhook_test.go
    │   │       │       └── webhook_suite_test.go
    │   │       └── ship/
    │   │           ├── v1/
    │   │           │   ├── destroyer_webhook.go
    │   │           │   ├── destroyer_webhook_test.go
    │   │           │   └── webhook_suite_test.go
    │   │           └── v2alpha1/
    │   │               ├── cruiser_webhook.go
    │   │               ├── cruiser_webhook_test.go
    │   │               └── webhook_suite_test.go
    │   └── test/
    │       ├── e2e/
    │       │   ├── e2e_suite_test.go
    │       │   └── e2e_test.go
    │       └── utils/
    │           └── utils.go
    └── project-v4-with-plugins/
        ├── .custom-gcl.yml
        ├── .devcontainer/
        │   ├── devcontainer.json
        │   └── post-install.sh
        ├── .dockerignore
        ├── .github/
        │   └── workflows/
        │       ├── auto_update.yml
        │       ├── lint.yml
        │       ├── test-chart.yml
        │       ├── test-e2e.yml
        │       └── test.yml
        ├── .gitignore
        ├── .golangci.yml
        ├── AGENTS.md
        ├── Dockerfile
        ├── Makefile
        ├── PROJECT
        ├── README.md
        ├── api/
        │   ├── v1/
        │   │   ├── groupversion_info.go
        │   │   ├── wordpress_conversion.go
        │   │   ├── wordpress_types.go
        │   │   └── zz_generated.deepcopy.go
        │   ├── v1alpha1/
        │   │   ├── busybox_types.go
        │   │   ├── groupversion_info.go
        │   │   ├── memcached_types.go
        │   │   └── zz_generated.deepcopy.go
        │   └── v2/
        │       ├── groupversion_info.go
        │       ├── wordpress_conversion.go
        │       ├── wordpress_types.go
        │       └── zz_generated.deepcopy.go
        ├── cmd/
        │   └── main.go
        ├── config/
        │   ├── certmanager/
        │   │   ├── certificate-metrics.yaml
        │   │   ├── certificate-webhook.yaml
        │   │   ├── issuer.yaml
        │   │   ├── kustomization.yaml
        │   │   └── kustomizeconfig.yaml
        │   ├── crd/
        │   │   ├── bases/
        │   │   │   ├── example.com.testproject.org_busyboxes.yaml
        │   │   │   ├── example.com.testproject.org_memcacheds.yaml
        │   │   │   └── example.com.testproject.org_wordpresses.yaml
        │   │   ├── kustomization.yaml
        │   │   ├── kustomizeconfig.yaml
        │   │   └── patches/
        │   │       └── webhook_in_wordpresses.yaml
        │   ├── default/
        │   │   ├── cert_metrics_manager_patch.yaml
        │   │   ├── kustomization.yaml
        │   │   ├── manager_metrics_patch.yaml
        │   │   ├── manager_webhook_patch.yaml
        │   │   └── metrics_service.yaml
        │   ├── manager/
        │   │   ├── kustomization.yaml
        │   │   └── manager.yaml
        │   ├── network-policy/
        │   │   ├── allow-metrics-traffic.yaml
        │   │   ├── allow-webhook-traffic.yaml
        │   │   └── kustomization.yaml
        │   ├── prometheus/
        │   │   ├── kustomization.yaml
        │   │   ├── monitor.yaml
        │   │   └── monitor_tls_patch.yaml
        │   ├── rbac/
        │   │   ├── busybox_admin_role.yaml
        │   │   ├── busybox_editor_role.yaml
        │   │   ├── busybox_viewer_role.yaml
        │   │   ├── kustomization.yaml
        │   │   ├── leader_election_role.yaml
        │   │   ├── leader_election_role_binding.yaml
        │   │   ├── memcached_admin_role.yaml
        │   │   ├── memcached_editor_role.yaml
        │   │   ├── memcached_viewer_role.yaml
        │   │   ├── metrics_auth_role.yaml
        │   │   ├── metrics_auth_role_binding.yaml
        │   │   ├── metrics_reader_role.yaml
        │   │   ├── role.yaml
        │   │   ├── role_binding.yaml
        │   │   ├── service_account.yaml
        │   │   ├── wordpress_admin_role.yaml
        │   │   ├── wordpress_editor_role.yaml
        │   │   └── wordpress_viewer_role.yaml
        │   ├── samples/
        │   │   ├── example.com_v1_wordpress.yaml
        │   │   ├── example.com_v1alpha1_busybox.yaml
        │   │   ├── example.com_v1alpha1_memcached.yaml
        │   │   ├── example.com_v2_wordpress.yaml
        │   │   └── kustomization.yaml
        │   └── webhook/
        │       ├── kustomization.yaml
        │       ├── manifests.yaml
        │       └── service.yaml
        ├── dist/
        │   ├── chart/
        │   │   ├── .helmignore
        │   │   ├── Chart.yaml
        │   │   ├── templates/
        │   │   │   ├── NOTES.txt
        │   │   │   ├── _helpers.tpl
        │   │   │   ├── cert-manager/
        │   │   │   │   ├── metrics-certs.yaml
        │   │   │   │   ├── selfsigned-issuer.yaml
        │   │   │   │   └── serving-cert.yaml
        │   │   │   ├── crd/
        │   │   │   │   ├── busyboxes.example.com.testproject.org.yaml
        │   │   │   │   ├── memcacheds.example.com.testproject.org.yaml
        │   │   │   │   └── wordpresses.example.com.testproject.org.yaml
        │   │   │   ├── manager/
        │   │   │   │   └── manager.yaml
        │   │   │   ├── metrics/
        │   │   │   │   └── controller-manager-metrics-service.yaml
        │   │   │   ├── monitoring/
        │   │   │   │   └── servicemonitor.yaml
        │   │   │   ├── rbac/
        │   │   │   │   ├── busybox-admin-role.yaml
        │   │   │   │   ├── busybox-editor-role.yaml
        │   │   │   │   ├── busybox-viewer-role.yaml
        │   │   │   │   ├── controller-manager.yaml
        │   │   │   │   ├── leader-election-role.yaml
        │   │   │   │   ├── leader-election-rolebinding.yaml
        │   │   │   │   ├── manager-role.yaml
        │   │   │   │   ├── manager-rolebinding.yaml
        │   │   │   │   ├── memcached-admin-role.yaml
        │   │   │   │   ├── memcached-editor-role.yaml
        │   │   │   │   ├── memcached-viewer-role.yaml
        │   │   │   │   ├── metrics-auth-role.yaml
        │   │   │   │   ├── metrics-auth-rolebinding.yaml
        │   │   │   │   ├── metrics-reader.yaml
        │   │   │   │   ├── wordpress-admin-role.yaml
        │   │   │   │   ├── wordpress-editor-role.yaml
        │   │   │   │   └── wordpress-viewer-role.yaml
        │   │   │   └── webhook/
        │   │   │       ├── validating-webhook-configuration.yaml
        │   │   │       └── webhook-service.yaml
        │   │   └── values.yaml
        │   └── install.yaml
        ├── go.mod
        ├── grafana/
        │   ├── controller-resources-metrics.json
        │   ├── controller-runtime-metrics.json
        │   └── custom-metrics/
        │       └── config.yaml
        ├── hack/
        │   └── boilerplate.go.txt
        ├── internal/
        │   ├── controller/
        │   │   ├── busybox_controller.go
        │   │   ├── busybox_controller_test.go
        │   │   ├── memcached_controller.go
        │   │   ├── memcached_controller_test.go
        │   │   ├── suite_test.go
        │   │   ├── wordpress_controller.go
        │   │   └── wordpress_controller_test.go
        │   └── webhook/
        │       ├── v1/
        │       │   ├── webhook_suite_test.go
        │       │   ├── wordpress_webhook.go
        │       │   └── wordpress_webhook_test.go
        │       └── v1alpha1/
        │           ├── memcached_webhook.go
        │           ├── memcached_webhook_test.go
        │           └── webhook_suite_test.go
        └── test/
            ├── e2e/
            │   ├── e2e_suite_test.go
            │   └── e2e_test.go
            └── utils/
                └── utils.go
Download .txt
Showing preview only (273K chars total). Download the full file or copy to clipboard to get everything.
SYMBOL INDEX (2817 symbols across 461 files)

FILE: docs/book/functions/handle-version.js
  function notFound (line 1) | function notFound(info) {
  function redirectToDownload (line 12) | function redirectToDownload(version, file) {

FILE: docs/book/src/cronjob-tutorial/testdata/emptyapi.go
  type CronJobSpec (line 41) | type CronJobSpec struct
  type CronJobStatus (line 47) | type CronJobStatus struct
  type CronJob (line 76) | type CronJob struct
  type CronJobList (line 87) | type CronJobList struct
  function init (line 97) | func init() {

FILE: docs/book/src/cronjob-tutorial/testdata/emptycontroller.go
  type CronJobReconciler (line 43) | type CronJobReconciler struct
    method Reconcile (line 90) | func (r *CronJobReconciler) Reconcile(ctx context.Context, req ctrl.Re...
    method SetupWithManager (line 107) | func (r *CronJobReconciler) SetupWithManager(mgr ctrl.Manager) error {

FILE: docs/book/src/cronjob-tutorial/testdata/emptymain.go
  function init (line 62) | func init() {
  function main (line 90) | func main() {

FILE: docs/book/src/cronjob-tutorial/testdata/finalizer_example.go
  method Reconcile (line 49) | func (r *CronJobReconciler) Reconcile(ctx context.Context, req ctrl.Requ...
  method deleteExternalResources (line 101) | func (r *Reconciler) deleteExternalResources(cronJob *batch.CronJob) err...

FILE: docs/book/src/cronjob-tutorial/testdata/project/api/v1/cronjob_types.go
  type CronJobSpec (line 66) | type CronJobSpec struct
  type ConcurrencyPolicy (line 121) | type ConcurrencyPolicy
  constant AllowConcurrent (line 125) | AllowConcurrent ConcurrencyPolicy = "Allow"
  constant ForbidConcurrent (line 129) | ForbidConcurrent ConcurrencyPolicy = "Forbid"
  constant ReplaceConcurrent (line 132) | ReplaceConcurrent ConcurrencyPolicy = "Replace"
  type CronJobStatus (line 145) | type CronJobStatus struct
  type CronJob (line 188) | type CronJob struct
  type CronJobList (line 209) | type CronJobList struct
  function init (line 215) | func init() {

FILE: docs/book/src/cronjob-tutorial/testdata/project/api/v1/zz_generated.deepcopy.go
  method DeepCopyInto (line 30) | func (in *CronJob) DeepCopyInto(out *CronJob) {
  method DeepCopy (line 39) | func (in *CronJob) DeepCopy() *CronJob {
  method DeepCopyObject (line 49) | func (in *CronJob) DeepCopyObject() runtime.Object {
  method DeepCopyInto (line 57) | func (in *CronJobList) DeepCopyInto(out *CronJobList) {
  method DeepCopy (line 71) | func (in *CronJobList) DeepCopy() *CronJobList {
  method DeepCopyObject (line 81) | func (in *CronJobList) DeepCopyObject() runtime.Object {
  method DeepCopyInto (line 89) | func (in *CronJobSpec) DeepCopyInto(out *CronJobSpec) {
  method DeepCopy (line 115) | func (in *CronJobSpec) DeepCopy() *CronJobSpec {
  method DeepCopyInto (line 125) | func (in *CronJobStatus) DeepCopyInto(out *CronJobStatus) {
  method DeepCopy (line 146) | func (in *CronJobStatus) DeepCopy() *CronJobStatus {

FILE: docs/book/src/cronjob-tutorial/testdata/project/cmd/main.go
  function init (line 61) | func init() {
  function main (line 74) | func main() {

FILE: docs/book/src/cronjob-tutorial/testdata/project/internal/controller/cronjob_controller.go
  type CronJobReconciler (line 52) | type CronJobReconciler struct
    method Reconcile (line 113) | func (r *CronJobReconciler) Reconcile(ctx context.Context, req ctrl.Re...
    method SetupWithManager (line 738) | func (r *CronJobReconciler) SetupWithManager(mgr ctrl.Manager) error {
  type realClock (line 62) | type realClock struct
    method Now (line 64) | func (_ realClock) Now() time.Time { return time.Now() }
  type Clock (line 68) | type Clock interface
  constant typeAvailableCronJob (line 77) | typeAvailableCronJob = "Available"
  constant typeProgressingCronJob (line 79) | typeProgressingCronJob = "Progressing"
  constant typeDegradedCronJob (line 81) | typeDegradedCronJob = "Degraded"

FILE: docs/book/src/cronjob-tutorial/testdata/project/internal/controller/suite_test.go
  function TestControllers (line 67) | func TestControllers(t *testing.T) {
  function getFirstFoundEnvTestBinaryDir (line 187) | func getFirstFoundEnvTestBinaryDir() string {

FILE: docs/book/src/cronjob-tutorial/testdata/project/internal/webhook/v1/cronjob_webhook.go
  function SetupCronJobWebhookWithManager (line 49) | func SetupCronJobWebhookWithManager(mgr ctrl.Manager) error {
  type CronJobCustomDefaulter (line 79) | type CronJobCustomDefaulter struct
    method Default (line 96) | func (d *CronJobCustomDefaulter) Default(_ context.Context, obj *batch...
    method applyDefaults (line 105) | func (d *CronJobCustomDefaulter) applyDefaults(cronJob *batchv1.CronJo...
  type CronJobCustomValidator (line 157) | type CronJobCustomValidator struct
    method ValidateCreate (line 162) | func (v *CronJobCustomValidator) ValidateCreate(_ context.Context, obj...
    method ValidateUpdate (line 169) | func (v *CronJobCustomValidator) ValidateUpdate(_ context.Context, old...
    method ValidateDelete (line 176) | func (v *CronJobCustomValidator) ValidateDelete(_ context.Context, obj...
  function validateCronJob (line 189) | func validateCronJob(cronjob *batchv1.CronJob) error {
  function validateCronJobSpec (line 216) | func validateCronJobSpec(cronjob *batchv1.CronJob) *field.Error {
  function validateScheduleFormat (line 229) | func validateScheduleFormat(schedule string, fldPath *field.Path) *field...
  function validateCronJobName (line 245) | func validateCronJobName(cronjob *batchv1.CronJob) *field.Error {

FILE: docs/book/src/cronjob-tutorial/testdata/project/internal/webhook/v1/webhook_suite_test.go
  function TestAPIs (line 57) | func TestAPIs(t *testing.T) {
  function getFirstFoundEnvTestBinaryDir (line 152) | func getFirstFoundEnvTestBinaryDir() string {

FILE: docs/book/src/cronjob-tutorial/testdata/project/test/e2e/e2e_suite_test.go
  function TestE2E (line 47) | func TestE2E(t *testing.T) {
  function setupCertManager (line 92) | func setupCertManager() {
  function teardownCertManager (line 113) | func teardownCertManager() {

FILE: docs/book/src/cronjob-tutorial/testdata/project/test/e2e/e2e_test.go
  constant namespace (line 37) | namespace = "project-system"
  constant serviceAccountName (line 40) | serviceAccountName = "project-controller-manager"
  constant metricsServiceName (line 43) | metricsServiceName = "project-controller-manager-metrics-service"
  constant metricsRoleBindingName (line 46) | metricsRoleBindingName = "project-metrics-binding"
  function serviceAccountToken (line 367) | func serviceAccountToken() (string, error) {
  function getMetricsOutput (line 406) | func getMetricsOutput() (string, error) {
  type tokenRequest (line 414) | type tokenRequest struct

FILE: docs/book/src/cronjob-tutorial/testdata/project/test/utils/utils.go
  constant certmanagerVersion (line 31) | certmanagerVersion = "v1.20.0"
  constant certmanagerURLTmpl (line 32) | certmanagerURLTmpl = "https://github.com/cert-manager/cert-manager/relea...
  constant defaultKindBinary (line 34) | defaultKindBinary  = "kind"
  constant defaultKindCluster (line 35) | defaultKindCluster = "kind"
  constant prometheusOperatorVersion (line 37) | prometheusOperatorVersion = "v0.89.0"
  constant prometheusOperatorURL (line 38) | prometheusOperatorURL     = "https://github.com/prometheus-operator/prom...
  function warnError (line 42) | func warnError(err error) {
  function Run (line 47) | func Run(cmd *exec.Cmd) (string, error) {
  function UninstallCertManager (line 67) | func UninstallCertManager() {
  function InstallCertManager (line 89) | func InstallCertManager() error {
  function IsCertManagerCRDsInstalled (line 109) | func IsCertManagerCRDsInstalled() bool {
  function InstallPrometheusOperator (line 141) | func InstallPrometheusOperator() error {
  function UninstallPrometheusOperator (line 149) | func UninstallPrometheusOperator() {
  function IsPrometheusCRDsInstalled (line 159) | func IsPrometheusCRDsInstalled() bool {
  function LoadImageToKindClusterWithName (line 185) | func LoadImageToKindClusterWithName(name string) error {
  function GetNonEmptyLines (line 202) | func GetNonEmptyLines(output string) []string {
  function GetProjectDir (line 215) | func GetProjectDir() (string, error) {
  function UncommentCode (line 226) | func UncommentCode(filename, target, prefix string) error {

FILE: docs/book/src/getting-started/testdata/project/api/v1alpha1/memcached_types.go
  type MemcachedSpec (line 30) | type MemcachedSpec struct
  type MemcachedStatus (line 47) | type MemcachedStatus struct
  type Memcached (line 73) | type Memcached struct
  type MemcachedList (line 92) | type MemcachedList struct
  function init (line 98) | func init() {

FILE: docs/book/src/getting-started/testdata/project/api/v1alpha1/zz_generated.deepcopy.go
  method DeepCopyInto (line 29) | func (in *Memcached) DeepCopyInto(out *Memcached) {
  method DeepCopy (line 38) | func (in *Memcached) DeepCopy() *Memcached {
  method DeepCopyObject (line 48) | func (in *Memcached) DeepCopyObject() runtime.Object {
  method DeepCopyInto (line 56) | func (in *MemcachedList) DeepCopyInto(out *MemcachedList) {
  method DeepCopy (line 70) | func (in *MemcachedList) DeepCopy() *MemcachedList {
  method DeepCopyObject (line 80) | func (in *MemcachedList) DeepCopyObject() runtime.Object {
  method DeepCopyInto (line 88) | func (in *MemcachedSpec) DeepCopyInto(out *MemcachedSpec) {
  method DeepCopy (line 98) | func (in *MemcachedSpec) DeepCopy() *MemcachedSpec {
  method DeepCopyInto (line 108) | func (in *MemcachedStatus) DeepCopyInto(out *MemcachedStatus) {
  method DeepCopy (line 120) | func (in *MemcachedStatus) DeepCopy() *MemcachedStatus {

FILE: docs/book/src/getting-started/testdata/project/cmd/main.go
  function init (line 48) | func init() {
  function main (line 56) | func main() {

FILE: docs/book/src/getting-started/testdata/project/internal/controller/memcached_controller.go
  constant typeAvailableMemcached (line 43) | typeAvailableMemcached = "Available"
  type MemcachedReconciler (line 47) | type MemcachedReconciler struct
    method Reconcile (line 72) | func (r *MemcachedReconciler) Reconcile(ctx context.Context, req ctrl....
    method SetupWithManager (line 209) | func (r *MemcachedReconciler) SetupWithManager(mgr ctrl.Manager) error {
    method deploymentForMemcached (line 218) | func (r *MemcachedReconciler) deploymentForMemcached(

FILE: docs/book/src/getting-started/testdata/project/internal/controller/suite_test.go
  function TestControllers (line 51) | func TestControllers(t *testing.T) {
  function getFirstFoundEnvTestBinaryDir (line 105) | func getFirstFoundEnvTestBinaryDir() string {

FILE: docs/book/src/getting-started/testdata/project/test/e2e/e2e_suite_test.go
  function TestE2E (line 45) | func TestE2E(t *testing.T) {
  function setupCertManager (line 72) | func setupCertManager() {
  function teardownCertManager (line 93) | func teardownCertManager() {

FILE: docs/book/src/getting-started/testdata/project/test/e2e/e2e_test.go
  constant namespace (line 37) | namespace = "project-system"
  constant serviceAccountName (line 40) | serviceAccountName = "project-controller-manager"
  constant metricsServiceName (line 43) | metricsServiceName = "project-controller-manager-metrics-service"
  constant metricsRoleBindingName (line 46) | metricsRoleBindingName = "project-metrics-binding"
  function serviceAccountToken (line 288) | func serviceAccountToken() (string, error) {
  function getMetricsOutput (line 327) | func getMetricsOutput() (string, error) {
  type tokenRequest (line 335) | type tokenRequest struct

FILE: docs/book/src/getting-started/testdata/project/test/utils/utils.go
  constant certmanagerVersion (line 31) | certmanagerVersion = "v1.20.0"
  constant certmanagerURLTmpl (line 32) | certmanagerURLTmpl = "https://github.com/cert-manager/cert-manager/relea...
  constant defaultKindBinary (line 34) | defaultKindBinary  = "kind"
  constant defaultKindCluster (line 35) | defaultKindCluster = "kind"
  function warnError (line 38) | func warnError(err error) {
  function Run (line 43) | func Run(cmd *exec.Cmd) (string, error) {
  function UninstallCertManager (line 63) | func UninstallCertManager() {
  function InstallCertManager (line 85) | func InstallCertManager() error {
  function IsCertManagerCRDsInstalled (line 105) | func IsCertManagerCRDsInstalled() bool {
  function LoadImageToKindClusterWithName (line 137) | func LoadImageToKindClusterWithName(name string) error {
  function GetNonEmptyLines (line 154) | func GetNonEmptyLines(output string) []string {
  function GetProjectDir (line 167) | func GetProjectDir() (string, error) {
  function UncommentCode (line 178) | func UncommentCode(filename, target, prefix string) error {

FILE: docs/book/src/multiversion-tutorial/testdata/project/api/v1/cronjob_conversion.go
  method Hub (line 28) | func (*CronJob) Hub() {}

FILE: docs/book/src/multiversion-tutorial/testdata/project/api/v1/cronjob_types.go
  type CronJobSpec (line 38) | type CronJobSpec struct
  type ConcurrencyPolicy (line 86) | type ConcurrencyPolicy
  constant AllowConcurrent (line 90) | AllowConcurrent ConcurrencyPolicy = "Allow"
  constant ForbidConcurrent (line 94) | ForbidConcurrent ConcurrencyPolicy = "Forbid"
  constant ReplaceConcurrent (line 97) | ReplaceConcurrent ConcurrencyPolicy = "Replace"
  type CronJobStatus (line 101) | type CronJobStatus struct
  type CronJob (line 154) | type CronJob struct
  type CronJobList (line 176) | type CronJobList struct
  function init (line 182) | func init() {

FILE: docs/book/src/multiversion-tutorial/testdata/project/api/v1/zz_generated.deepcopy.go
  method DeepCopyInto (line 30) | func (in *CronJob) DeepCopyInto(out *CronJob) {
  method DeepCopy (line 39) | func (in *CronJob) DeepCopy() *CronJob {
  method DeepCopyObject (line 49) | func (in *CronJob) DeepCopyObject() runtime.Object {
  method DeepCopyInto (line 57) | func (in *CronJobList) DeepCopyInto(out *CronJobList) {
  method DeepCopy (line 71) | func (in *CronJobList) DeepCopy() *CronJobList {
  method DeepCopyObject (line 81) | func (in *CronJobList) DeepCopyObject() runtime.Object {
  method DeepCopyInto (line 89) | func (in *CronJobSpec) DeepCopyInto(out *CronJobSpec) {
  method DeepCopy (line 115) | func (in *CronJobSpec) DeepCopy() *CronJobSpec {
  method DeepCopyInto (line 125) | func (in *CronJobStatus) DeepCopyInto(out *CronJobStatus) {
  method DeepCopy (line 146) | func (in *CronJobStatus) DeepCopy() *CronJobStatus {

FILE: docs/book/src/multiversion-tutorial/testdata/project/api/v2/cronjob_conversion.go
  method ConvertTo (line 51) | func (src *CronJob) ConvertTo(dstRaw conversion.Hub) error {
  method ConvertFrom (line 104) | func (dst *CronJob) ConvertFrom(srcRaw conversion.Hub) error {

FILE: docs/book/src/multiversion-tutorial/testdata/project/api/v2/cronjob_types.go
  type CronJobSpec (line 43) | type CronJobSpec struct
  type CronSchedule (line 97) | type CronSchedule struct
  type CronField (line 122) | type CronField
  type ConcurrencyPolicy (line 133) | type ConcurrencyPolicy
  constant AllowConcurrent (line 137) | AllowConcurrent ConcurrencyPolicy = "Allow"
  constant ForbidConcurrent (line 141) | ForbidConcurrent ConcurrencyPolicy = "Forbid"
  constant ReplaceConcurrent (line 144) | ReplaceConcurrent ConcurrencyPolicy = "Replace"
  type CronJobStatus (line 148) | type CronJobStatus struct
  type CronJob (line 184) | type CronJob struct
  type CronJobList (line 203) | type CronJobList struct
  function init (line 209) | func init() {

FILE: docs/book/src/multiversion-tutorial/testdata/project/api/v2/zz_generated.deepcopy.go
  method DeepCopyInto (line 30) | func (in *CronJob) DeepCopyInto(out *CronJob) {
  method DeepCopy (line 39) | func (in *CronJob) DeepCopy() *CronJob {
  method DeepCopyObject (line 49) | func (in *CronJob) DeepCopyObject() runtime.Object {
  method DeepCopyInto (line 57) | func (in *CronJobList) DeepCopyInto(out *CronJobList) {
  method DeepCopy (line 71) | func (in *CronJobList) DeepCopy() *CronJobList {
  method DeepCopyObject (line 81) | func (in *CronJobList) DeepCopyObject() runtime.Object {
  method DeepCopyInto (line 89) | func (in *CronJobSpec) DeepCopyInto(out *CronJobSpec) {
  method DeepCopy (line 116) | func (in *CronJobSpec) DeepCopy() *CronJobSpec {
  method DeepCopyInto (line 126) | func (in *CronJobStatus) DeepCopyInto(out *CronJobStatus) {
  method DeepCopy (line 147) | func (in *CronJobStatus) DeepCopy() *CronJobStatus {
  method DeepCopyInto (line 157) | func (in *CronSchedule) DeepCopyInto(out *CronSchedule) {
  method DeepCopy (line 187) | func (in *CronSchedule) DeepCopy() *CronSchedule {

FILE: docs/book/src/multiversion-tutorial/testdata/project/cmd/main.go
  function init (line 58) | func init() {
  function main (line 73) | func main() {

FILE: docs/book/src/multiversion-tutorial/testdata/project/internal/controller/cronjob_controller.go
  type CronJobReconciler (line 52) | type CronJobReconciler struct
    method Reconcile (line 113) | func (r *CronJobReconciler) Reconcile(ctx context.Context, req ctrl.Re...
    method SetupWithManager (line 738) | func (r *CronJobReconciler) SetupWithManager(mgr ctrl.Manager) error {
  type realClock (line 62) | type realClock struct
    method Now (line 64) | func (_ realClock) Now() time.Time { return time.Now() }
  type Clock (line 68) | type Clock interface
  constant typeAvailableCronJob (line 77) | typeAvailableCronJob = "Available"
  constant typeProgressingCronJob (line 79) | typeProgressingCronJob = "Progressing"
  constant typeDegradedCronJob (line 81) | typeDegradedCronJob = "Degraded"

FILE: docs/book/src/multiversion-tutorial/testdata/project/internal/controller/suite_test.go
  function TestControllers (line 67) | func TestControllers(t *testing.T) {
  function getFirstFoundEnvTestBinaryDir (line 187) | func getFirstFoundEnvTestBinaryDir() string {

FILE: docs/book/src/multiversion-tutorial/testdata/project/internal/webhook/v1/cronjob_webhook.go
  function SetupCronJobWebhookWithManager (line 54) | func SetupCronJobWebhookWithManager(mgr ctrl.Manager) error {
  type CronJobCustomDefaulter (line 84) | type CronJobCustomDefaulter struct
    method Default (line 101) | func (d *CronJobCustomDefaulter) Default(_ context.Context, obj *batch...
    method applyDefaults (line 110) | func (d *CronJobCustomDefaulter) applyDefaults(cronJob *batchv1.CronJo...
  type CronJobCustomValidator (line 162) | type CronJobCustomValidator struct
    method ValidateCreate (line 167) | func (v *CronJobCustomValidator) ValidateCreate(_ context.Context, obj...
    method ValidateUpdate (line 174) | func (v *CronJobCustomValidator) ValidateUpdate(_ context.Context, old...
    method ValidateDelete (line 181) | func (v *CronJobCustomValidator) ValidateDelete(_ context.Context, obj...
  function validateCronJob (line 194) | func validateCronJob(cronjob *batchv1.CronJob) error {
  function validateCronJobSpec (line 221) | func validateCronJobSpec(cronjob *batchv1.CronJob) *field.Error {
  function validateScheduleFormat (line 234) | func validateScheduleFormat(schedule string, fldPath *field.Path) *field...
  function validateCronJobName (line 250) | func validateCronJobName(cronjob *batchv1.CronJob) *field.Error {

FILE: docs/book/src/multiversion-tutorial/testdata/project/internal/webhook/v1/webhook_suite_test.go
  function TestAPIs (line 57) | func TestAPIs(t *testing.T) {
  function getFirstFoundEnvTestBinaryDir (line 152) | func getFirstFoundEnvTestBinaryDir() string {

FILE: docs/book/src/multiversion-tutorial/testdata/project/internal/webhook/v2/cronjob_webhook.go
  function SetupCronJobWebhookWithManager (line 44) | func SetupCronJobWebhookWithManager(mgr ctrl.Manager) error {
  type CronJobCustomDefaulter (line 65) | type CronJobCustomDefaulter struct
    method Default (line 74) | func (d *CronJobCustomDefaulter) Default(_ context.Context, obj *batch...
    method applyDefaults (line 120) | func (d *CronJobCustomDefaulter) applyDefaults(cronJob *batchv2.CronJo...
  type CronJobCustomValidator (line 92) | type CronJobCustomValidator struct
    method ValidateCreate (line 97) | func (v *CronJobCustomValidator) ValidateCreate(_ context.Context, obj...
    method ValidateUpdate (line 104) | func (v *CronJobCustomValidator) ValidateUpdate(_ context.Context, old...
    method ValidateDelete (line 111) | func (v *CronJobCustomValidator) ValidateDelete(_ context.Context, obj...
  function validateCronJob (line 141) | func validateCronJob(cronjob *batchv2.CronJob) error {
  function validateCronJobName (line 155) | func validateCronJobName(cronjob *batchv2.CronJob) *field.Error {
  function validateCronJobSpec (line 163) | func validateCronJobSpec(cronjob *batchv2.CronJob) *field.Error {
  function validateScheduleFormat (line 190) | func validateScheduleFormat(schedule string, fldPath *field.Path) *field...

FILE: docs/book/src/multiversion-tutorial/testdata/project/internal/webhook/v2/webhook_suite_test.go
  function TestAPIs (line 57) | func TestAPIs(t *testing.T) {
  function getFirstFoundEnvTestBinaryDir (line 152) | func getFirstFoundEnvTestBinaryDir() string {

FILE: docs/book/src/multiversion-tutorial/testdata/project/test/e2e/e2e_suite_test.go
  function TestE2E (line 47) | func TestE2E(t *testing.T) {
  function setupCertManager (line 92) | func setupCertManager() {
  function teardownCertManager (line 113) | func teardownCertManager() {

FILE: docs/book/src/multiversion-tutorial/testdata/project/test/e2e/e2e_test.go
  constant namespace (line 38) | namespace = "project-system"
  constant serviceAccountName (line 41) | serviceAccountName = "project-controller-manager"
  constant metricsServiceName (line 44) | metricsServiceName = "project-controller-manager-metrics-service"
  constant metricsRoleBindingName (line 47) | metricsRoleBindingName = "project-metrics-binding"
  function serviceAccountToken (line 461) | func serviceAccountToken() (string, error) {
  function getMetricsOutput (line 500) | func getMetricsOutput() (string, error) {
  type tokenRequest (line 508) | type tokenRequest struct

FILE: docs/book/src/multiversion-tutorial/testdata/project/test/utils/utils.go
  constant certmanagerVersion (line 31) | certmanagerVersion = "v1.20.0"
  constant certmanagerURLTmpl (line 32) | certmanagerURLTmpl = "https://github.com/cert-manager/cert-manager/relea...
  constant defaultKindBinary (line 34) | defaultKindBinary  = "kind"
  constant defaultKindCluster (line 35) | defaultKindCluster = "kind"
  constant prometheusOperatorVersion (line 37) | prometheusOperatorVersion = "v0.89.0"
  constant prometheusOperatorURL (line 38) | prometheusOperatorURL     = "https://github.com/prometheus-operator/prom...
  function warnError (line 42) | func warnError(err error) {
  function Run (line 47) | func Run(cmd *exec.Cmd) (string, error) {
  function UninstallCertManager (line 67) | func UninstallCertManager() {
  function InstallCertManager (line 89) | func InstallCertManager() error {
  function IsCertManagerCRDsInstalled (line 109) | func IsCertManagerCRDsInstalled() bool {
  function InstallPrometheusOperator (line 141) | func InstallPrometheusOperator() error {
  function UninstallPrometheusOperator (line 149) | func UninstallPrometheusOperator() {
  function IsPrometheusCRDsInstalled (line 159) | func IsPrometheusCRDsInstalled() bool {
  function LoadImageToKindClusterWithName (line 185) | func LoadImageToKindClusterWithName(name string) error {
  function GetNonEmptyLines (line 202) | func GetNonEmptyLines(output string) []string {
  function GetProjectDir (line 215) | func GetProjectDir() (string, error) {
  function UncommentCode (line 226) | func UncommentCode(filename, target, prefix string) error {

FILE: docs/book/utils/litgo/literate.go
  type Literate (line 40) | type Literate struct
    method SupportsOutput (line 48) | func (Literate) SupportsOutput(_ string) bool { return true }
    method Process (line 51) | func (l Literate) Process(input *plugin.Input) error {
    method extractContents (line 226) | func (l Literate) extractContents(contents []byte, pathInfo filePathIn...
  type filePathInfo (line 79) | type filePathInfo struct
    method FullPath (line 91) | func (f filePathInfo) FullPath() string {
    method ViewablePath (line 96) | func (f filePathInfo) ViewablePath(baseBookSrcURL url.URL) string {
  type commentCodePair (line 107) | type commentCodePair struct
  function getCollapse (line 119) | func getCollapse(tok token.Token, lit string) string {
  function isBlockComment (line 137) | func isBlockComment(tok token.Token, lit string) bool {
  function commentText (line 151) | func commentText(raw string, lineOffset int) string {
  function extractPairs (line 173) | func extractPairs(contents []byte, path string) ([]commentCodePair, erro...
  function removeIndent (line 283) | func removeIndent(comment string) string {
  function wrapWithNewlines (line 294) | func wrapWithNewlines(src string) string {
  function main (line 299) | func main() {

FILE: docs/book/utils/markerdocs/doctypes.go
  type DetailedHelp (line 21) | type DetailedHelp struct
  type Argument (line 26) | type Argument struct
  type FieldHelp (line 32) | type FieldHelp struct
  type MarkerDoc (line 42) | type MarkerDoc struct
    method Anonymous (line 61) | func (m MarkerDoc) Anonymous() bool {
  type CategoryDoc (line 56) | type CategoryDoc struct

FILE: docs/book/utils/markerdocs/html.go
  type toHTML (line 34) | type toHTML interface
  type Text (line 40) | type Text
    method WriteHTML (line 47) | func (t Text) WriteHTML(w io.Writer) error {
  type Tag (line 68) | type Tag struct
    method WriteHTML (line 75) | func (t Tag) WriteHTML(w io.Writer) error {
  type Fragment (line 98) | type Fragment
    method WriteHTML (line 101) | func (f Fragment) WriteHTML(w io.Writer) error {
  type Attrs (line 111) | type Attrs interface
  type classes (line 117) | type classes
    method ToAttrs (line 120) | func (c classes) ToAttrs() string { return fmt.Sprintf("class=%q", str...
  type optionalClasses (line 123) | type optionalClasses
    method ToAttrs (line 126) | func (c optionalClasses) ToAttrs() string {
  type attrs (line 137) | type attrs
    method ToAttrs (line 140) | func (a attrs) ToAttrs() string {
  type dataAttr (line 149) | type dataAttr struct
    method ToAttrs (line 155) | func (d dataAttr) ToAttrs() string {
  function makeTag (line 161) | func makeTag(name string) func(Attrs, ...toHTML) Tag {

FILE: docs/book/utils/markerdocs/main.go
  function argType (line 31) | func argType(arg *Argument) toHTML {
  function maybeDetails (line 43) | func maybeDetails(help *DetailedHelp) toHTML {
  function markerTemplate (line 57) | func markerTemplate(marker *MarkerDoc) toHTML {
  type MarkerDocs (line 116) | type MarkerDocs struct
    method SupportsOutput (line 125) | func (MarkerDocs) SupportsOutput(_ string) bool { return true }
    method Process (line 128) | func (p MarkerDocs) Process(input *plugin.Input) error {
    method getMarkerDocs (line 227) | func (p MarkerDocs) getMarkerDocs() ([]CategoryDoc, error) {
  function wrapWithNewlines (line 207) | func wrapWithNewlines(src string) string {
  function main (line 255) | func main() {

FILE: docs/book/utils/plugin/input.go
  type Context (line 26) | type Context struct
  type Config (line 32) | type Config struct
  type BookConfig (line 37) | type BookConfig struct
  type Book (line 42) | type Book struct
  type BookSection (line 48) | type BookSection struct
  type BookItem (line 55) | type BookItem
    method UnmarshalJSON (line 58) | func (b *BookItem) UnmarshalJSON(input []byte) error {
    method MarshalJSON (line 84) | func (b BookItem) MarshalJSON() ([]byte, error) {
  type bookItem (line 93) | type bookItem struct
  type BookChapter (line 99) | type BookChapter struct
  type SectionNumber (line 109) | type SectionNumber
  type Input (line 114) | type Input struct
    method UnmarshalJSON (line 120) | func (p *Input) UnmarshalJSON(input []byte) error {
  type ChapterVisitor (line 152) | type ChapterVisitor
  function EachItem (line 156) | func EachItem(parentItem *BookItem, visitor ChapterVisitor) error {
  function EachItemInBook (line 177) | func EachItemInBook(book *Book, visitor ChapterVisitor) error {

FILE: docs/book/utils/plugin/plugin.go
  type Plugin (line 27) | type Plugin interface
  function Run (line 36) | func Run(plug Plugin, inputRaw io.Reader, outputRaw io.Writer, args ...s...

FILE: docs/book/utils/plugin/utils.go
  function EachCommand (line 27) | func EachCommand(book *Book, cmd string, callback func(chapter *BookChap...

FILE: hack/docs/generate_samples.go
  constant KubebuilderBinName (line 30) | KubebuilderBinName = "/tmp/kubebuilder/bin/kubebuilder"
  type tutorialGenerator (line 32) | type tutorialGenerator interface
  function main (line 39) | func main() {
  function updateTutorial (line 64) | func updateTutorial(generator tutorialGenerator) {
  function updateCronjobTutorial (line 71) | func updateCronjobTutorial() {
  function updateGettingStarted (line 77) | func updateGettingStarted() {
  function updateMultiversionTutorial (line 83) | func updateMultiversionTutorial() {

FILE: hack/docs/internal/cronjob-tutorial/api_design.go
  constant cronjobSpecExplaination (line 19) | cronjobSpecExplaination = `
  constant cronjobSpecStruct (line 52) | cronjobSpecStruct = `
  constant cronjobList (line 130) | cronjobList = `
  constant docCommentStatusSub (line 144) | docCommentStatusSub = `

FILE: hack/docs/internal/cronjob-tutorial/controller_implementation.go
  constant controllerIntro (line 19) | controllerIntro = `
  constant controllerImport (line 27) | controllerImport = `import (
  constant controllerMockClock (line 54) | controllerMockClock = `
  constant controllerReconcile (line 88) | controllerReconcile = `
  constant skipGoCycloLint (line 100) | skipGoCycloLint = `
  constant controllerReconcileLogic (line 103) | controllerReconcileLogic = `log := logf.FromContext(ctx)
  constant controllerSetupWithManager (line 727) | controllerSetupWithManager = `

FILE: hack/docs/internal/cronjob-tutorial/e2e_implementation.go
  constant isPrometheusInstalledVar (line 19) | isPrometheusInstalledVar = `
  constant beforeSuitePrometheus (line 23) | beforeSuitePrometheus = `
  constant afterSuitePrometheus (line 28) | afterSuitePrometheus = `
  constant checkPrometheusInstalled (line 36) | checkPrometheusInstalled = `
  constant serviceMonitorE2e (line 47) | serviceMonitorE2e = `
  constant prometheusUtilities (line 54) | prometheusUtilities = `// InstallPrometheusOperator installs the prometh...
  constant prometheusVersionURL (line 99) | prometheusVersionURL = `

FILE: hack/docs/internal/cronjob-tutorial/generate_cronjob.go
  type Sample (line 34) | type Sample struct
    method Prepare (line 46) | func (sp *Sample) Prepare() {
    method GenerateSampleProject (line 57) | func (sp *Sample) GenerateSampleProject() {
    method UpdateTutorial (line 88) | func (sp *Sample) UpdateTutorial() {
    method CodeGen (line 137) | func (sp *Sample) CodeGen() {
    method updateSpec (line 151) | func (sp *Sample) updateSpec() {
    method updateAPIStuff (line 238) | func (sp *Sample) updateAPIStuff() {
    method updateController (line 254) | func (sp *Sample) updateController() {
    method updateMain (line 321) | func (sp *Sample) updateMain() {
    method updateMakefile (line 372) | func (sp *Sample) updateMakefile() {
    method updateWebhookTests (line 389) | func (sp *Sample) updateWebhookTests() {
    method updateWebhook (line 419) | func (sp *Sample) updateWebhook() {
    method updateSuiteTest (line 529) | func (sp *Sample) updateSuiteTest() {
    method updateKustomization (line 611) | func (sp *Sample) updateKustomization() {
    method updateExample (line 703) | func (sp *Sample) updateExample() {
    method addControllerTest (line 718) | func (sp *Sample) addControllerTest() {
    method updateE2E (line 724) | func (sp *Sample) updateE2E() {
  function NewSample (line 39) | func NewSample(binaryPath, samplePath string) Sample {

FILE: hack/docs/internal/cronjob-tutorial/main_revisited.go
  constant mainBatch (line 19) | mainBatch = `
  constant mainEnableWebhook (line 31) | mainEnableWebhook = `

FILE: hack/docs/internal/cronjob-tutorial/other_api_files.go
  constant groupVersionIntro (line 19) | groupVersionIntro = `
  constant groupVersionSchema (line 31) | groupVersionSchema = `

FILE: hack/docs/internal/cronjob-tutorial/sample.go
  constant cronjobSample (line 19) | cronjobSample = `
  constant certManagerForMetrics (line 47) | certManagerForMetrics = `# - source: # Uncomment the following block to ...

FILE: hack/docs/internal/cronjob-tutorial/webhook_implementation.go
  constant webhookIntro (line 19) | webhookIntro = `batchv1 "tutorial.kubebuilder.io/project/api/v1"
  constant webhookDefaultingSettings (line 30) | webhookDefaultingSettings = `// Set default values
  constant webhooksNoticeMarker (line 55) | webhooksNoticeMarker = `
  constant explanationValidateCRD (line 68) | explanationValidateCRD = `
  constant customInterfaceDefaultInfo (line 97) | customInterfaceDefaultInfo = `/*
  constant webhookValidateSpecMethods (line 106) | webhookValidateSpecMethods = `
  constant fragmentForDefaultFields (line 183) | fragmentForDefaultFields = `
  constant webhookTestCreateDefaultingFragment (line 191) | webhookTestCreateDefaultingFragment = `// TODO (user): Add logic for def...
  constant webhookTestCreateDefaultingReplaceFragment (line 202) | webhookTestCreateDefaultingReplaceFragment = `It("Should apply defaults ...
  constant webhookTestingValidatingTodoFragment (line 239) | webhookTestingValidatingTodoFragment = `// TODO (user): Add logic for va...
  constant webhookTestingValidatingExampleFragment (line 260) | webhookTestingValidatingExampleFragment = `It("Should deny creation if t...
  constant webhookTestsVars (line 312) | webhookTestsVars = `var (
  constant webhookTestsConstants (line 319) | webhookTestsConstants = `	var (
  constant webhookTestsBeforeEachOriginal (line 329) | webhookTestsBeforeEachOriginal = `obj = &batchv1.CronJob{}
  constant webhookTestsBeforeEachChanged (line 338) | webhookTestsBeforeEachChanged = `obj = &batchv1.CronJob{

FILE: hack/docs/internal/cronjob-tutorial/writing_tests_controller.go
  constant controllerTest (line 19) | controllerTest = `/*

FILE: hack/docs/internal/cronjob-tutorial/writing_tests_env.go
  constant suiteTestIntro (line 19) | suiteTestIntro = `
  constant suiteTestEnv (line 30) | suiteTestEnv = `
  constant suiteTestAddSchema (line 46) | suiteTestAddSchema = `
  constant suiteTestClient (line 65) | suiteTestClient = `
  constant suiteTestDescription (line 70) | suiteTestDescription = `
  constant suiteTestCleanup (line 111) | suiteTestCleanup = `

FILE: hack/docs/internal/getting-started/generate_getting_started.go
  type Sample (line 30) | type Sample struct
    method UpdateTutorial (line 42) | func (sp *Sample) UpdateTutorial() {
    method updateControllerTest (line 49) | func (sp *Sample) updateControllerTest() {
    method updateAPI (line 98) | func (sp *Sample) updateAPI() {
    method updateSample (line 124) | func (sp *Sample) updateSample() {
    method updateController (line 130) | func (sp *Sample) updateController() {
    method Prepare (line 193) | func (sp *Sample) Prepare() {
    method GenerateSampleProject (line 204) | func (sp *Sample) GenerateSampleProject() {
    method CodeGen (line 231) | func (sp *Sample) CodeGen() {
  function NewSample (line 35) | func NewSample(binaryPath, samplePath string) Sample {
  constant oldSpecAPI (line 249) | oldSpecAPI = "// foo is an example field of Memcached. Edit memcached_ty...
  constant newSpecAPI (line 250) | newSpecAPI = `// size defines the number of Memcached instances
  constant sampleSizeFragment (line 260) | sampleSizeFragment = `# TODO(user): edit the following value to ensure t...
  constant controllerImports (line 264) | controllerImports = `"context"
  constant controllerStatusTypes (line 277) | controllerStatusTypes = `
  constant controllerInfoReconcileOld (line 284) | controllerInfoReconcileOld = `// TODO(user): Modify the Reconcile functi...
  constant controllerInfoReconcileNew (line 289) | controllerInfoReconcileNew = `// It is essential for the controller's re...
  constant controllerReconcileImplementation (line 298) | controllerReconcileImplementation = `// Fetch the Memcached instance
  constant controllerDeploymentFunc (line 428) | controllerDeploymentFunc = `// deploymentForMemcached returns a Memcache...

FILE: hack/docs/internal/multiversion-tutorial/controller_tests_code.go
  constant multiversionControllerTest (line 19) | multiversionControllerTest = `/*

FILE: hack/docs/internal/multiversion-tutorial/cronjob_v1.go
  constant cronjobSpecComment (line 19) | cronjobSpecComment = `/*
  constant concurrencyPolicyComment (line 47) | concurrencyPolicyComment = `/*
  constant statusDesignComment (line 54) | statusDesignComment = `/*
  constant boilerplateReplacement (line 63) | boilerplateReplacement = `// +kubebuilder:docs-gen:collapse=Remaining co...

FILE: hack/docs/internal/multiversion-tutorial/cronjob_v2.go
  constant importV2 (line 19) | importV2 = `import (
  constant importReplacement (line 23) | importReplacement = `/*
  constant cronjobSpecMore (line 32) | cronjobSpecMore = `// startingDeadlineSeconds defines in seconds for sta...

FILE: hack/docs/internal/multiversion-tutorial/generate_multiversion.go
  type Sample (line 32) | type Sample struct
    method Prepare (line 44) | func (sp *Sample) Prepare() {
    method GenerateSampleProject (line 51) | func (sp *Sample) GenerateSampleProject() {
    method UpdateTutorial (line 94) | func (sp *Sample) UpdateTutorial() {
    method updateControllerTest (line 117) | func (sp *Sample) updateControllerTest() {
    method updateCronjobV1ForConversion (line 125) | func (sp *Sample) updateCronjobV1ForConversion() {
    method updateSampleV2 (line 143) | func (sp *Sample) updateSampleV2() {
    method updateConversionFiles (line 155) | func (sp *Sample) updateConversionFiles() {
    method updateAPIV1 (line 250) | func (sp *Sample) updateAPIV1() {
    method updateWebhookV2 (line 332) | func (sp *Sample) updateWebhookV2() {
    method updateMain (line 421) | func (sp *Sample) updateMain() {
    method updateAPIV2 (line 531) | func (sp *Sample) updateAPIV2() {
    method CodeGen (line 634) | func (sp *Sample) CodeGen() {
    method updateE2EWebhookConversion (line 722) | func (sp *Sample) updateE2EWebhookConversion() {
  function NewSample (line 37) | func NewSample(binaryPath, samplePath string) Sample {
  constant webhookConversionE2ETest (line 647) | webhookConversionE2ETest = `

FILE: hack/docs/internal/multiversion-tutorial/hub.go
  constant hubV1CodeComment (line 20) | hubV1CodeComment = `
  constant hubV2CodeComment (line 29) | hubV2CodeComment = `package v2
  constant hubV2CovertTo (line 39) | hubV2CovertTo = `sched := src.Spec.Schedule
  constant hubV2ConvertFromCode (line 80) | hubV2ConvertFromCode = `schedParts := strings.Split(src.Spec.Schedule, " ")

FILE: hack/docs/internal/multiversion-tutorial/samples.go
  constant sampleV2Code (line 19) | sampleV2Code = `schedule:

FILE: hack/docs/internal/multiversion-tutorial/webhook_v2_implementaton.go
  constant cronJobFieldsForDefaulting (line 19) | cronJobFieldsForDefaulting = `	// Default values for various CronJob fields
  constant cronJobDefaultingLogic (line 26) | cronJobDefaultingLogic = `// Set default values
  constant cronJobDefaultFunction (line 31) | cronJobDefaultFunction = `
  constant cronJobValidationFunction (line 52) | cronJobValidationFunction = `
  constant originalSetupManager (line 113) | originalSetupManager = `// SetupCronJobWebhookWithManager registers the ...
  constant replaceSetupManager (line 121) | replaceSetupManager = `// SetupCronJobWebhookWithManager registers the w...

FILE: hack/docs/internal/utils/utils.go
  function CheckError (line 27) | func CheckError(msg string, err error) {
  function NewSampleContext (line 35) | func NewSampleContext(binaryPath string, samplePath string, env ...strin...

FILE: hack/test/check_go_module.go
  function main (line 44) | func main() {
  function checkFilePaths (line 69) | func checkFilePaths() error {
  function checkRetractedVersions (line 103) | func checkRetractedVersions() error {
  function readGoModInfo (line 125) | func readGoModInfo() (modulePath, goVersion string, err error) {
  function setupAndCheckConsumer (line 170) | func setupAndCheckConsumer(modulePath, goVersion string) error {
  function writeConsumerFiles (line 202) | func writeConsumerFiles(consumerDir, modulePath, goVersion string) error {
  function runCommand (line 234) | func runCommand(dir, name string, args ...string) error {

FILE: internal/cli/alpha/generate.go
  function NewScaffoldCommand (line 40) | func NewScaffoldCommand() *cobra.Command {

FILE: internal/cli/alpha/internal/common/common.go
  function LoadProjectConfig (line 31) | func LoadProjectConfig(inputDir string) (store.Store, error) {
  function GetInputPath (line 40) | func GetInputPath(inputPath string) (string, error) {

FILE: internal/cli/alpha/internal/common/suite_test.go
  function TestCommon (line 26) | func TestCommon(t *testing.T) {

FILE: internal/cli/alpha/internal/generate.go
  type Generate (line 41) | type Generate struct
    method Generate (line 50) | func (opts *Generate) Generate() error {
    method Validate (line 140) | func (opts *Generate) Validate() error {
  function getExecutablePath (line 156) | func getExecutablePath() (string, error) {
  function createDirectory (line 173) | func createDirectory(outputDir string) error {
  function changeWorkingDirectory (line 181) | func changeWorkingDirectory(outputDir string) error {
  function kubebuilderInit (line 189) | func kubebuilderInit(s store.Store) error {
  function kubebuilderCreate (line 203) | func kubebuilderCreate(s store.Store) error {
  function migrateGrafanaPlugin (line 228) | func migrateGrafanaPlugin(s store.Store, src, des string) error {
  function migrateAutoUpdatePlugin (line 278) | func migrateAutoUpdatePlugin(s store.Store) error {
  function migrateDeployImagePlugin (line 329) | func migrateDeployImagePlugin(s store.Store) error {
  function createAPIWithDeployImage (line 379) | func createAPIWithDeployImage(resourceData deployimagev1alpha1.ResourceD...
  function getInitArgs (line 390) | func getInitArgs(s store.Store) []string {
  function getGVKFlags (line 436) | func getGVKFlags(res resource.Resource) []string {
  function getGVKFlagsFromDeployImage (line 454) | func getGVKFlagsFromDeployImage(resourceData deployimagev1alpha1.Resourc...
  function getDeployImageOptions (line 469) | func getDeployImageOptions(resourceData deployimagev1alpha1.ResourceData...
  function createAPI (line 488) | func createAPI(res resource.Resource) error {
  function getAPIResourceFlags (line 510) | func getAPIResourceFlags(res resource.Resource) []string {
  function createWebhook (line 532) | func createWebhook(res resource.Resource) error {
  function getWebhookResourceFlags (line 547) | func getWebhookResourceFlags(res resource.Resource) []string {
  function copyFile (line 582) | func copyFile(src, des string) error {
  function grafanaConfigMigrate (line 595) | func grafanaConfigMigrate(src, des string) error {
  function kubebuilderGrafanaEdit (line 605) | func kubebuilderGrafanaEdit() error {
  function kubebuilderHelmEditWithConfig (line 614) | func kubebuilderHelmEditWithConfig(s store.Store) error {
  function kubebuilderHelmEdit (line 644) | func kubebuilderHelmEdit(isV2Alpha bool) error {
  function hasHelmPlugin (line 661) | func hasHelmPlugin(cfg store.Store) (bool, bool) {

FILE: internal/cli/alpha/internal/generate_test.go
  type fakeConfig (line 34) | type fakeConfig struct
    method GetPluginChain (line 48) | func (f *fakeConfig) GetPluginChain() []string { return f.pluginChain }
    method GetDomain (line 49) | func (f *fakeConfig) GetDomain() string        { return f.domain }
    method GetRepository (line 50) | func (f *fakeConfig) GetRepository() string    { return f.repo }
    method GetProjectName (line 51) | func (f *fakeConfig) GetProjectName() string   { return f.projectName }
    method IsMultiGroup (line 52) | func (f *fakeConfig) IsMultiGroup() bool       { return f.multigroup }
    method IsNamespaced (line 53) | func (f *fakeConfig) IsNamespaced() bool       { return f.namespaced }
    method GetResources (line 54) | func (f *fakeConfig) GetResources() ([]resource.Resource, error) {
    method DecodePluginConfig (line 61) | func (f *fakeConfig) DecodePluginConfig(key string, dst any) error {
  type fakeStore (line 90) | type fakeStore struct
    method Config (line 95) | func (f *fakeStore) Config() config.Config { return f.cfg }
  function TestGenerateHelpers (line 97) | func TestGenerateHelpers(t *testing.T) {
  function setupKubebuilderMockEnvironment (line 103) | func setupKubebuilderMockEnvironment(kbc *utils.TestContext) string {

FILE: internal/cli/alpha/internal/update.go
  type Update (line 39) | type Update struct
    method Update (line 58) | func (opts *Update) Update() error {
    method downloadKubebuilderBinary (line 107) | func (opts *Update) downloadKubebuilderBinary() (string, error) {
    method checkoutAncestorBranch (line 167) | func (opts *Update) checkoutAncestorBranch() error {
    method cleanUpAncestorBranch (line 180) | func (opts *Update) cleanUpAncestorBranch() error {
    method runAlphaGenerate (line 226) | func (opts *Update) runAlphaGenerate(tempDir, version string) error {
    method checkoutCurrentOffAncestor (line 283) | func (opts *Update) checkoutCurrentOffAncestor() error {
    method checkoutUpgradeOffAncestor (line 318) | func (opts *Update) checkoutUpgradeOffAncestor() error {
    method checkoutMergeOffCurrent (line 365) | func (opts *Update) checkoutMergeOffCurrent() error {
    method mergeUpgradeIntoMerge (line 377) | func (opts *Update) mergeUpgradeIntoMerge() error {
    method Validate (line 403) | func (opts *Update) Validate() error {
    method loadConfigFile (line 437) | func (opts *Update) loadConfigFile() (store.Store, error) {
    method defineFromVersion (line 450) | func (opts *Update) defineFromVersion() error {
    method validateBinaryAvailability (line 468) | func (opts *Update) validateBinaryAvailability() error {
    method validateGitRepo (line 502) | func (opts *Update) validateGitRepo() error {
    method validateFromBranch (line 524) | func (opts *Update) validateFromBranch() error {
  function runMakeTargets (line 212) | func runMakeTargets() error {

FILE: internal/cli/alpha/internal/update/helpers/conflict.go
  type ConflictSummary (line 31) | type ConflictSummary struct
  type ConflictResult (line 38) | type ConflictResult struct
  function isGeneratedKB (line 46) | func isGeneratedKB(path string) bool {
  function FindConflictFiles (line 56) | func FindConflictFiles() ConflictResult {
  function DetectConflicts (line 100) | func DetectConflicts() ConflictSummary {
  function getGitIndexConflicts (line 105) | func getGitIndexConflicts() []string {
  function scanFilesystemForConflicts (line 128) | func scanFilesystemForConflicts() []string {
  function hasConflictInFiles (line 211) | func hasConflictInFiles(conflicts map[string]bool, paths ...string) bool {
  function hasConflictInPaths (line 220) | func hasConflictInPaths(conflicts map[string]bool, pathPrefixes ...strin...
  function hasGoConflictInFiles (line 231) | func hasGoConflictInFiles(conflicts map[string]bool) bool {
  function DecideMakeTargets (line 241) | func DecideMakeTargets(cs ConflictSummary) []string {

FILE: internal/cli/alpha/internal/update/helpers/download.go
  constant KubebuilderReleaseURL (line 33) | KubebuilderReleaseURL = "https://github.com/kubernetes-sigs/kubebuilder/...
  function BuildReleaseURL (line 35) | func BuildReleaseURL(version string) string {
  function DownloadReleaseVersionWith (line 42) | func DownloadReleaseVersionWith(version string) (string, error) {

FILE: internal/cli/alpha/internal/update/helpers/git_commands.go
  function CommitIgnoreEmpty (line 27) | func CommitIgnoreEmpty(msg, ctx string) error {
  function CleanWorktree (line 43) | func CleanWorktree(label string) error {
  function GitCmd (line 52) | func GitCmd(gitConfig []string, args ...string) *exec.Cmd {
  function MergeCommitMessage (line 62) | func MergeCommitMessage(from, to string) string {
  function ConflictCommitMessage (line 67) | func ConflictCommitMessage(from, to string) string {

FILE: internal/cli/alpha/internal/update/helpers/open_gh_issue.go
  constant selectedDiffTotalCap (line 31) | selectedDiffTotalCap     = 96 << 10
  constant selectedDiffLinesPerFile (line 32) | selectedDiffLinesPerFile = 120
  constant selectedDiffLinesGoMod (line 33) | selectedDiffLinesGoMod   = 240
  constant IssueTitleTmpl (line 37) | IssueTitleTmpl = "[Action Required] Upgrade the Scaffold: %[2]s -> %[1]s"
  constant IssueBodyTmpl (line 42) | IssueBodyTmpl = `## Description
  constant IssueBodyTmplWithConflicts (line 68) | IssueBodyTmplWithConflicts = `## Description
  constant AiPRPrompt (line 111) | AiPRPrompt = `You are a senior Go/K8s engineer. Produce a concise, revie...
  function listConflictFiles (line 178) | func listConflictFiles() (src []string, gen []string) {
  function bulletList (line 183) | func bulletList(items []string) string {
  function FirstURL (line 191) | func FirstURL(s string) string {
  function IssueNumberFromURL (line 202) | func IssueNumberFromURL(u string) string {
  function listChangedFiles (line 211) | func listChangedFiles(base, head string) (src []string, gen []string) {
  function BuildFullPrompet (line 235) | func BuildFullPrompet(
  function excludedFromDiff (line 278) | func excludedFromDiff(p string) bool {
  function importantFile (line 292) | func importantFile(p string) bool {
  function filePriority (line 345) | func filePriority(p string) int {
  function keepGoModLine (line 390) | func keepGoModLine(s string) bool {
  function interestingLine (line 414) | func interestingLine(path, line string) bool {
  function selectedDiff (line 438) | func selectedDiff(base, head, path string, maxLines int) string {
  function concatSelectedDiffs (line 487) | func concatSelectedDiffs(base, head string, files []string, perFileLineC...

FILE: internal/cli/alpha/internal/update/helpers/suite_test.go
  function TestCommand (line 26) | func TestCommand(t *testing.T) {

FILE: internal/cli/alpha/internal/update/integration_test.go
  constant fromVersion (line 41) | fromVersion           = "v4.5.2"
  constant toVersion (line 42) | toVersion             = "v4.6.0"
  constant toVersionWithConflict (line 43) | toVersionWithConflict = "v4.7.0"
  constant memcachedFromVersion (line 47) | memcachedFromVersion = "v4.11.1"
  constant memcachedHelmCustomRegistry (line 50) | memcachedHelmCustomRegistry = "myregistry.io/custom/controller"
  constant memcachedAffinityCommentedRegex (line 54) | memcachedAffinityCommentedRegex = `(?s)// TODO\(user\): Uncomment the fo...
  constant memcachedAffinityUncommented (line 57) | memcachedAffinityUncommented = `// Node affinity for multi-arch (customi...
  constant controllerImplementation (line 71) | controllerImplementation = `// Fetch the TestOperator instance
  constant customField (line 85) | customField = `// +kubebuilder:validation:Minimum=0
  function modifyMakefileControllerTools (line 512) | func modifyMakefileControllerTools(projectDir, newVersion string) {
  function validateMakefileContent (line 534) | func validateMakefileContent(projectDir string) {
  function validateCommonGoModule (line 552) | func validateCommonGoModule(projectDir string) {
  function downloadKubebuilderVersion (line 560) | func downloadKubebuilderVersion(version string) (string, error) {
  function updateController (line 603) | func updateController(projectDir string) {
  function updateAPI (line 609) | func updateAPI(projectDir string) {
  function initializeGitRepo (line 615) | func initializeGitRepo(projectDir string) {
  function validateCustomCodePreservation (line 636) | func validateCustomCodePreservation(projectDir string) {
  function hasConflictMarkers (line 652) | func hasConflictMarkers(projectDir string) bool {
  function validateConflictState (line 678) | func validateConflictState(projectDir string) {
  function expectModuleVersion (line 701) | func expectModuleVersion(projectDir, module, version string) {
  function expectFileExists (line 712) | func expectFileExists(projectDir, relPath string) {
  function expectNoConflictMarkersInPath (line 720) | func expectNoConflictMarkersInPath(projectDir, dir string) {

FILE: internal/cli/alpha/internal/update/prepare.go
  constant defaultBranch (line 30) | defaultBranch = "main"
  type releaseResponse (line 32) | type releaseResponse struct
  method Prepare (line 38) | func (opts *Update) Prepare() error {
  method defineFromVersion (line 62) | func (opts *Update) defineFromVersion(config store.Store) (string, error) {
  method defineToVersion (line 81) | func (opts *Update) defineToVersion() string {
  function fetchLatestRelease (line 94) | func fetchLatestRelease() (string, error) {

FILE: internal/cli/alpha/internal/update/prepare_test.go
  constant testFromVersion (line 37) | testFromVersion = "v4.5.0"
  constant testToVersion (line 38) | testToVersion   = "v4.6.0"

FILE: internal/cli/alpha/internal/update/suite_test.go
  function TestCommand (line 26) | func TestCommand(t *testing.T) {

FILE: internal/cli/alpha/internal/update/update.go
  type Update (line 37) | type Update struct
    method Update (line 130) | func (opts *Update) Update() error {
    method openGitHubIssue (line 230) | func (opts *Update) openGitHubIssue(hasConflicts bool) error {
    method cleanupTempBranches (line 349) | func (opts *Update) cleanupTempBranches() {
    method getOutputBranchName (line 373) | func (opts *Update) getOutputBranchName() string {
    method preservePaths (line 381) | func (opts *Update) preservePaths() {
    method squashToOutputBranch (line 396) | func (opts *Update) squashToOutputBranch(hasConflicts bool) error {
    method prepareAncestorBranch (line 445) | func (opts *Update) prepareAncestorBranch() error {
    method prepareOriginalBranch (line 618) | func (opts *Update) prepareOriginalBranch() error {
    method prepareUpgradeBranch (line 645) | func (opts *Update) prepareUpgradeBranch() error {
    method mergeOriginalToUpgrade (line 675) | func (opts *Update) mergeOriginalToUpgrade() (bool, error) {
    method getMergeMessage (line 726) | func (opts *Update) getMergeMessage(hasConflicts bool) string {
  function regenerateProjectWithVersion (line 432) | func regenerateProjectWithVersion(version string) error {
  function cleanupBranch (line 472) | func cleanupBranch() error {
  function runMakeTargets (line 484) | func runMakeTargets(skipConflicts bool) {
  function runAlphaGenerate (line 524) | func runAlphaGenerate(tempDir, version string) error {
  function forwardAndReformat (line 559) | func forwardAndReformat(reader io.Reader, isStderr bool) {
  function envWithPrefixedPath (line 603) | func envWithPrefixedPath(dir string) []string {

FILE: internal/cli/alpha/internal/update/update_test.go
  function mockBinResponse (line 35) | func mockBinResponse(script, mockBin string) error {
  function mockURLResponse (line 45) | func mockURLResponse(body, url string, times, reply int) {

FILE: internal/cli/alpha/internal/update/validate.go
  method Validate (line 33) | func (opts *Update) Validate() error {
  function isGhModelsExtensionInstalled (line 69) | func isGhModelsExtensionInstalled() bool {
  method validateGitRepo (line 78) | func (opts *Update) validateGitRepo() error {
  method validateFromBranch (line 99) | func (opts *Update) validateFromBranch() error {
  method validateSemanticVersions (line 111) | func (opts *Update) validateSemanticVersions() error {
  function validateReleaseAvailability (line 124) | func validateReleaseAvailability(version string) error {
  method validateEqualVersions (line 151) | func (opts *Update) validateEqualVersions() error {

FILE: internal/cli/alpha/suite_test.go
  function TestCommand (line 30) | func TestCommand(t *testing.T) {

FILE: internal/cli/alpha/update.go
  function NewUpdateCommand (line 30) | func NewUpdateCommand() *cobra.Command {

FILE: internal/cli/cmd/cmd.go
  function Run (line 42) | func Run() {

FILE: internal/cli/version/version.go
  constant unknown (line 28) | unknown                 = "unknown"
  constant develVersion (line 29) | develVersion            = "(devel)"
  constant kubernetesVendorVersion (line 30) | kubernetesVendorVersion = "1.35.0"
  type Version (line 33) | type Version struct
    method GetKubeBuilderVersion (line 68) | func (v Version) GetKubeBuilderVersion() string {
    method applyVCSMetadata (line 85) | func (v *Version) applyVCSMetadata(settings []debug.BuildSetting) {
    method PrintVersion (line 116) | func (v Version) PrintVersion() string {
  function New (line 42) | func New() Version {
  function resolveMainVersion (line 72) | func resolveMainVersion(main debug.Module) string {
  function isPseudoVersion (line 81) | func isPseudoVersion(v string) bool {

FILE: internal/cli/version/version_test.go
  function TestNew (line 25) | func TestNew(t *testing.T) {
  function TestGetKubeBuilderVersion (line 79) | func TestGetKubeBuilderVersion(t *testing.T) {
  function TestResolveMainVersion (line 102) | func TestResolveMainVersion(t *testing.T) {
  function TestApplyVCSMetadata (line 122) | func TestApplyVCSMetadata(t *testing.T) {
  function TestPrintVersion (line 200) | func TestPrintVersion(t *testing.T) {

FILE: internal/logging/handler.go
  constant ColorReset (line 28) | ColorReset = "\033[0m"
  constant ColorError (line 29) | ColorError = "\033[31m"
  constant ColorWarn (line 30) | ColorWarn  = "\033[33m"
  constant ColorInfo (line 31) | ColorInfo  = "\033[36m"
  constant ColorDebug (line 32) | ColorDebug = "\033[32m"
  type HandlerOptions (line 35) | type HandlerOptions struct
  type Handler (line 39) | type Handler struct
    method Enabled (line 44) | func (h *Handler) Enabled(ctx context.Context, level slog.Level) bool {
    method Handle (line 48) | func (h *Handler) Handle(_ context.Context, r slog.Record) error {
    method WithAttrs (line 70) | func (h *Handler) WithAttrs(_ []slog.Attr) slog.Handler {
    method WithGroup (line 74) | func (h *Handler) WithGroup(_ string) slog.Handler {
  function NewHandler (line 78) | func NewHandler(out io.Writer, opts HandlerOptions) *Handler {

FILE: main.go
  function main (line 21) | func main() {

FILE: pkg/cli/alpha.go
  constant alphaCommand (line 29) | alphaCommand = "alpha"
  function newAlphaCommand (line 38) | func newAlphaCommand() *cobra.Command {
  method newAlphaCmd (line 45) | func (c *CLI) newAlphaCmd() *cobra.Command {
  method addAlphaCmd (line 64) | func (c *CLI) addAlphaCmd() {
  method addExtraAlphaCommands (line 70) | func (c *CLI) addExtraAlphaCommands() error {

FILE: pkg/cli/api.go
  constant apiErrorMsg (line 28) | apiErrorMsg = "failed to create API"
  method newCreateAPICmd (line 30) | func (c CLI) newCreateAPICmd() *cobra.Command {

FILE: pkg/cli/cli.go
  constant noticeColor (line 38) | noticeColor    = "\033[1;33m%s\033[0m"
  constant deprecationFmt (line 39) | deprecationFmt = "[Deprecation Notice] %s\n\n"
  constant pluginsFlag (line 41) | pluginsFlag        = "plugins"
  constant projectVersionFlag (line 42) | projectVersionFlag = "project-version"
  type CLI (line 46) | type CLI struct
    method buildCmd (line 148) | func (c *CLI) buildCmd() error {
    method getInfo (line 184) | func (c *CLI) getInfo() error {
    method getInfoFromConfigFile (line 210) | func (c *CLI) getInfoFromConfigFile() error {
    method getInfoFromConfig (line 324) | func (c *CLI) getInfoFromConfig(projectConfig config.Config) error {
    method getInfoFromFlags (line 338) | func (c *CLI) getInfoFromFlags(hasConfigFile bool) error {
    method getInfoFromDefaults (line 425) | func (c *CLI) getInfoFromDefaults() {
    method resolvePlugins (line 464) | func (c *CLI) resolvePlugins() error {
    method addSubcommands (line 538) | func (c *CLI) addSubcommands() {
    method addExtraCommands (line 571) | func (c *CLI) addExtraCommands() error {
    method printDeprecationWarnings (line 584) | func (c CLI) printDeprecationWarnings() {
    method metadata (line 593) | func (c CLI) metadata() plugin.CLIMetadata {
    method Run (line 602) | func (c CLI) Run() error {
    method Command (line 615) | func (c CLI) Command() *cobra.Command {
  function New (line 95) | func New(options ...Option) (*CLI, error) {
  function newCLI (line 126) | func newCLI(options ...Option) (*CLI, error) {
  function isAlphaGenerateCommand (line 239) | func isAlphaGenerateCommand(args []string) bool {
  function patchProjectFileInMemoryIfNeeded (line 281) | func patchProjectFileInMemoryIfNeeded(fs afero.Fs, path string) error {
  constant unstablePluginMsg (line 460) | unstablePluginMsg = " (plugin version is unstable, there may be an upgra...

FILE: pkg/cli/cli_test.go
  function makeMockPluginsFor (line 39) | func makeMockPluginsFor(projectVersion config.Version, pluginKeys ...str...
  function makeMapFor (line 48) | func makeMapFor(plugins ...plugin.Plugin) map[string]plugin.Plugin {
  function setFlag (line 56) | func setFlag(flag, value string) {
  function setBoolFlag (line 60) | func setBoolFlag(flag string) {
  function setProjectVersionFlag (line 64) | func setProjectVersionFlag(value string) {
  function setPluginsFlag (line 68) | func setPluginsFlag(value string) {
  function hasSubCommand (line 72) | func hasSubCommand(cmd *cobra.Command, name string) bool {
  type pluginChainCapturingSubcommand (line 81) | type pluginChainCapturingSubcommand struct
    method Scaffold (line 85) | func (s *pluginChainCapturingSubcommand) Scaffold(machinery.Filesystem...
    method SetPluginChain (line 89) | func (s *pluginChainCapturingSubcommand) SetPluginChain(chain []string) {
  type testCreateAPIPlugin (line 93) | type testCreateAPIPlugin struct
    method Name (line 109) | func (p testCreateAPIPlugin) Name() string                            ...
    method Version (line 110) | func (p testCreateAPIPlugin) Version() plugin.Version                 ...
    method SupportedProjectVersions (line 111) | func (p testCreateAPIPlugin) SupportedProjectVersions() []config.Versi...
    method GetCreateAPISubcommand (line 112) | func (p testCreateAPIPlugin) GetCreateAPISubcommand() plugin.CreateAPI...
  function newTestCreateAPIPlugin (line 100) | func newTestCreateAPIPlugin(name string, version plugin.Version) testCre...
  type testCreateAPISubcommand (line 116) | type testCreateAPISubcommand struct
    method InjectResource (line 118) | func (s *testCreateAPISubcommand) InjectResource(*resource.Resource) e...
    method Scaffold (line 122) | func (s *testCreateAPISubcommand) Scaffold(machinery.Filesystem) error {
  type fakeStore (line 126) | type fakeStore struct
    method New (line 130) | func (f *fakeStore) New(config.Version) error { return nil }
    method Load (line 131) | func (f *fakeStore) Load() error              { return nil }
    method LoadFrom (line 132) | func (f *fakeStore) LoadFrom(string) error    { return nil }
    method Save (line 133) | func (f *fakeStore) Save() error              { return nil }
    method SaveTo (line 134) | func (f *fakeStore) SaveTo(string) error      { return nil }
    method Config (line 135) | func (f *fakeStore) Config() config.Config    { return f.cfg }
  type captureSubcommand (line 137) | type captureSubcommand struct
    method Scaffold (line 141) | func (c *captureSubcommand) Scaffold(machinery.Filesystem) error { ret...

FILE: pkg/cli/cmd_helpers.go
  type noResolvedPluginError (line 37) | type noResolvedPluginError struct
    method Error (line 40) | func (e noResolvedPluginError) Error() string {
  type noAvailablePluginError (line 45) | type noAvailablePluginError struct
    method Error (line 50) | func (e noAvailablePluginError) Error() string {
  function cmdErr (line 56) | func cmdErr(cmd *cobra.Command, err error) {
  function errCmdFunc (line 62) | func errCmdFunc(err error) func(*cobra.Command, []string) error {
  type keySubcommandTuple (line 70) | type keySubcommandTuple struct
  type pluginChainSetter (line 79) | type pluginChainSetter interface
  method filterSubcommands (line 84) | func (c *CLI) filterSubcommands(
  function collectSubcommands (line 95) | func collectSubcommands(
  method applySubcommandHooks (line 123) | func (c *CLI) applySubcommandHooks(
  method appendPluginTable (line 172) | func (c *CLI) appendPluginTable(cmd *cobra.Command, filter func(plugin.P...
  type initHooksResult (line 179) | type initHooksResult struct
  function mergeFlagSetInto (line 187) | func mergeFlagSetInto(
  function syncDuplicateFlags (line 227) | func syncDuplicateFlags(flags *pflag.FlagSet, duplicateValues map[string...
  function initializationHooks (line 243) | func initializationHooks(
  type executionHooksFactory (line 290) | type executionHooksFactory struct
    method forEach (line 310) | func (factory *executionHooksFactory) forEach(cb func(subcommand plugi...
    method withPluginChain (line 337) | func (factory *executionHooksFactory) withPluginChain(tuple keySubcomm...
    method preRunEFunc (line 400) | func (factory *executionHooksFactory) preRunEFunc(
    method runEFunc (line 492) | func (factory *executionHooksFactory) runEFunc() func(*cobra.Command, ...
    method postRunEFunc (line 508) | func (factory *executionHooksFactory) postRunEFunc() func(*cobra.Comma...
  function moveKeyToFront (line 366) | func moveKeyToFront(chain []string, key string) []string {
  function equalStringSlices (line 386) | func equalStringSlices(a, b []string) bool {

FILE: pkg/cli/cmd_helpers_test.go
  type mockTestSubcommand (line 442) | type mockTestSubcommand struct
    method Scaffold (line 444) | func (m *mockTestSubcommand) Scaffold(machinery.Filesystem) error {
  type mockSubcommandWithForceFlag (line 449) | type mockSubcommandWithForceFlag struct
    method Scaffold (line 453) | func (m *mockSubcommandWithForceFlag) Scaffold(machinery.Filesystem) e...
    method BindFlags (line 457) | func (m *mockSubcommandWithForceFlag) BindFlags(flags *pflag.FlagSet) {
  type mockPluginWithSubcommand (line 461) | type mockPluginWithSubcommand struct
    method Name (line 479) | func (m *mockPluginWithSubcommand) Name() string {
    method Version (line 483) | func (m *mockPluginWithSubcommand) Version() plugin.Version {
    method SupportedProjectVersions (line 487) | func (m *mockPluginWithSubcommand) SupportedProjectVersions() []config...
  function newMockPluginWithSubcommand (line 467) | func newMockPluginWithSubcommand(
  type mockPluginBundle (line 491) | type mockPluginBundle struct
    method Name (line 505) | func (m *mockPluginBundle) Name() string {
    method Version (line 509) | func (m *mockPluginBundle) Version() plugin.Version {
    method SupportedProjectVersions (line 513) | func (m *mockPluginBundle) SupportedProjectVersions() []config.Version {
    method Plugins (line 517) | func (m *mockPluginBundle) Plugins() []plugin.Plugin {
  function newMockPluginBundle (line 497) | func newMockPluginBundle(name string, versions []config.Version, plugins...

FILE: pkg/cli/completion.go
  method newBashCmd (line 26) | func (c CLI) newBashCmd() *cobra.Command {
  method newZshCmd (line 45) | func (c CLI) newZshCmd() *cobra.Command {
  method newFishCmd (line 64) | func (c CLI) newFishCmd() *cobra.Command {
  method newPowerShellCmd (line 80) | func (CLI) newPowerShellCmd() *cobra.Command {
  method newCompletionCmd (line 90) | func (c CLI) newCompletionCmd() *cobra.Command {

FILE: pkg/cli/create.go
  method newCreateCmd (line 27) | func (c CLI) newCreateCmd() *cobra.Command {

FILE: pkg/cli/edit.go
  constant editErrorMsg (line 28) | editErrorMsg = "failed to edit project"
  method newEditCmd (line 30) | func (c CLI) newEditCmd() *cobra.Command {

FILE: pkg/cli/init.go
  constant initErrorMsg (line 31) | initErrorMsg = "failed to initialize project"
  method newInitCmd (line 33) | func (c CLI) newInitCmd() *cobra.Command {
  method getInitHelpExamples (line 84) | func (c CLI) getInitHelpExamples() string {
  method getAvailableProjectVersions (line 97) | func (c CLI) getAvailableProjectVersions() (projectVersions []string) {

FILE: pkg/cli/options.go
  type Option (line 43) | type Option
  function WithCommandName (line 46) | func WithCommandName(name string) Option {
  function WithVersion (line 54) | func WithVersion(version string) Option {
  function WithCliVersion (line 62) | func WithCliVersion(version string) Option {
  function WithDescription (line 70) | func WithDescription(description string) Option {
  function WithPlugins (line 80) | func WithPlugins(plugins ...plugin.Plugin) Option {
  function WithDefaultPlugins (line 99) | func WithDefaultPlugins(projectVersion config.Version, plugins ...plugin...
  function WithDefaultProjectVersion (line 123) | func WithDefaultProjectVersion(version config.Version) Option {
  function WithExtraCommands (line 136) | func WithExtraCommands(cmds ...*cobra.Command) Option {
  function WithExtraAlphaCommands (line 148) | func WithExtraAlphaCommands(cmds ...*cobra.Command) Option {
  function WithCompletion (line 158) | func WithCompletion() Option {
  function WithFilesystem (line 166) | func WithFilesystem(filesystem machinery.Filesystem) Option {
  function parseExternalPluginArgs (line 178) | func parseExternalPluginArgs() (args []string) {
  function isHostSupported (line 196) | func isHostSupported(host string) bool {
  function getPluginsRoot (line 201) | func getPluginsRoot(host string) (pluginsRoot string, err error) {
  function DiscoverExternalPlugins (line 247) | func DiscoverExternalPlugins(filesystem afero.Fs) (ps []plugin.Plugin, e...
  function isPluginExecutable (line 335) | func isPluginExecutable(mode fs.FileMode) bool {

FILE: pkg/cli/resource.go
  constant groupPresent (line 29) | groupPresent   = "group flag present but empty"
  constant versionPresent (line 30) | versionPresent = "version flag present but empty"
  constant kindPresent (line 31) | kindPresent    = "kind flag present but empty"
  type resourceOptions (line 35) | type resourceOptions struct
    method validate (line 50) | func (opts resourceOptions) validate() error {
    method newResource (line 73) | func (opts resourceOptions) newResource() *resource.Resource {
  function bindResourceFlags (line 39) | func bindResourceFlags(fs *pflag.FlagSet) *resourceOptions {

FILE: pkg/cli/root.go
  function isHelpFlag (line 37) | func isHelpFlag(s string) bool {
  function getShortKey (line 43) | func getShortKey(fullKey string) string {
  function getPluginDescription (line 72) | func getPluginDescription(_ string) string {
  method newRootCmd (line 77) | func (c CLI) newRootCmd() *cobra.Command {
  method rootExamples (line 118) | func (c CLI) rootExamples() string {
  method getPluginTable (line 147) | func (c CLI) getPluginTable() string {
  method getPluginTableFilteredForSubcommand (line 153) | func (c CLI) getPluginTableFilteredForSubcommand(filter func(plugin.Plug...
  method getPluginTableFiltered (line 160) | func (c CLI) getPluginTableFiltered(filter func(plugin.Plugin) bool) str...
  method getPluginTableFilteredWithOptions (line 165) | func (c CLI) getPluginTableFilteredWithOptions(filter func(plugin.Plugin...

FILE: pkg/cli/suite_test.go
  function TestCLI (line 29) | func TestCLI(t *testing.T) {
  type mockPlugin (line 40) | type mockPlugin struct
    method Name (line 54) | func (p mockPlugin) Name() string                               { retu...
    method Version (line 55) | func (p mockPlugin) Version() plugin.Version                    { retu...
    method SupportedProjectVersions (line 56) | func (p mockPlugin) SupportedProjectVersions() []config.Version { retu...
  function newMockPlugin (line 46) | func newMockPlugin(name, version string, projVers ...config.Version) plu...
  type mockDeprecatedPlugin (line 58) | type mockDeprecatedPlugin struct
    method DeprecationWarning (line 70) | func (p mockDeprecatedPlugin) DeprecationWarning() string { return p.d...
  function newMockDeprecatedPlugin (line 63) | func newMockDeprecatedPlugin(name, version, deprecation string, projVers...

FILE: pkg/cli/version.go
  method newVersionCmd (line 25) | func (c CLI) newVersionCmd() *cobra.Command {

FILE: pkg/cli/webhook.go
  constant webhookErrorMsg (line 28) | webhookErrorMsg = "failed to create webhook"
  method newCreateWebhookCmd (line 30) | func (c CLI) newCreateWebhookCmd() *cobra.Command {

FILE: pkg/config/errors.go
  type UnsupportedVersionError (line 26) | type UnsupportedVersionError struct
    method Error (line 31) | func (e UnsupportedVersionError) Error() string {
  type UnsupportedFieldError (line 37) | type UnsupportedFieldError struct
    method Error (line 43) | func (e UnsupportedFieldError) Error() string {
  type ResourceNotFoundError (line 48) | type ResourceNotFoundError struct
    method Error (line 53) | func (e ResourceNotFoundError) Error() string {
  type PluginKeyNotFoundError (line 58) | type PluginKeyNotFoundError struct
    method Error (line 63) | func (e PluginKeyNotFoundError) Error() string {
  type MarshalError (line 68) | type MarshalError struct
    method Error (line 73) | func (e MarshalError) Error() string {
    method Unwrap (line 78) | func (e MarshalError) Unwrap() error {
  type UnmarshalError (line 83) | type UnmarshalError struct
    method Error (line 88) | func (e UnmarshalError) Error() string {
    method Unwrap (line 93) | func (e UnmarshalError) Unwrap() error {

FILE: pkg/config/interface.go
  type Config (line 24) | type Config interface

FILE: pkg/config/registry.go
  function Register (line 22) | func Register(version Version, constructor func() Config) {
  function IsRegistered (line 27) | func IsRegistered(version Version) bool {
  function New (line 33) | func New(version Version) (Config, error) {

FILE: pkg/config/store/errors.go
  type LoadError (line 24) | type LoadError struct
    method Error (line 29) | func (e LoadError) Error() string {
    method Unwrap (line 34) | func (e LoadError) Unwrap() error {
  type SaveError (line 39) | type SaveError struct
    method Error (line 44) | func (e SaveError) Error() string {
    method Unwrap (line 49) | func (e SaveError) Unwrap() error {

FILE: pkg/config/store/errors_test.go
  function TestConfigStore (line 27) | func TestConfigStore(t *testing.T) {

FILE: pkg/config/store/interface.go
  type Store (line 24) | type Store interface

FILE: pkg/config/store/yaml/store.go
  constant DefaultPath (line 33) | DefaultPath = "PROJECT"
  constant commentStr (line 36) | commentStr = `# Code generated by tool. DO NOT EDIT.
  type yamlStore (line 45) | type yamlStore struct
    method New (line 60) | func (s *yamlStore) New(version config.Version) error {
    method Load (line 72) | func (s *yamlStore) Load() error {
    method LoadFrom (line 81) | func (s *yamlStore) LoadFrom(path string) error {
    method Save (line 113) | func (s yamlStore) Save() error {
    method SaveTo (line 118) | func (s yamlStore) SaveTo(path string) error {
    method Config (line 156) | func (s yamlStore) Config() config.Config {
  function New (line 55) | func New(fs machinery.Filesystem) store.Store {
  type versionedConfig (line 76) | type versionedConfig struct

FILE: pkg/config/store/yaml/store_test.go
  function TestConfigStoreYaml (line 35) | func TestConfigStoreYaml(t *testing.T) {

FILE: pkg/config/suite_test.go
  function TestConfig (line 26) | func TestConfig(t *testing.T) {

FILE: pkg/config/v3/config.go
  type stringSlice (line 35) | type stringSlice
    method UnmarshalJSON (line 37) | func (ss *stringSlice) UnmarshalJSON(b []byte) error {
  type Cfg (line 56) | type Cfg struct
    method GetVersion (line 94) | func (c Cfg) GetVersion() config.Version {
    method GetCliVersion (line 99) | func (c Cfg) GetCliVersion() string {
    method SetCliVersion (line 104) | func (c *Cfg) SetCliVersion(version string) error {
    method GetDomain (line 110) | func (c Cfg) GetDomain() string {
    method SetDomain (line 115) | func (c *Cfg) SetDomain(domain string) error {
    method GetRepository (line 121) | func (c Cfg) GetRepository() string {
    method SetRepository (line 126) | func (c *Cfg) SetRepository(repository string) error {
    method GetProjectName (line 132) | func (c Cfg) GetProjectName() string {
    method SetProjectName (line 137) | func (c *Cfg) SetProjectName(name string) error {
    method GetPluginChain (line 143) | func (c Cfg) GetPluginChain() []string {
    method SetPluginChain (line 148) | func (c *Cfg) SetPluginChain(pluginChain []string) error {
    method IsMultiGroup (line 154) | func (c Cfg) IsMultiGroup() bool {
    method SetMultiGroup (line 159) | func (c *Cfg) SetMultiGroup() error {
    method ClearMultiGroup (line 165) | func (c *Cfg) ClearMultiGroup() error {
    method IsNamespaced (line 171) | func (c Cfg) IsNamespaced() bool {
    method SetNamespaced (line 176) | func (c *Cfg) SetNamespaced() error {
    method ClearNamespaced (line 182) | func (c *Cfg) ClearNamespaced() error {
    method ResourcesLength (line 188) | func (c Cfg) ResourcesLength() int {
    method HasResource (line 193) | func (c Cfg) HasResource(gvk resource.GVK) bool {
    method GetResource (line 206) | func (c Cfg) GetResource(gvk resource.GVK) (resource.Resource, error) {
    method GetResources (line 224) | func (c Cfg) GetResources() ([]resource.Resource, error) {
    method AddResource (line 241) | func (c *Cfg) AddResource(res resource.Resource) error {
    method UpdateResource (line 257) | func (c *Cfg) UpdateResource(res resource.Resource) error {
    method HasGroup (line 281) | func (c Cfg) HasGroup(group string) bool {
    method ListCRDVersions (line 294) | func (c Cfg) ListCRDVersions() []string {
    method ListWebhookVersions (line 312) | func (c Cfg) ListWebhookVersions() []string {
    method DecodePluginConfig (line 330) | func (c Cfg) DecodePluginConfig(key string, configObj any) error {
    method EncodePluginConfig (line 351) | func (c *Cfg) EncodePluginConfig(key string, configObj any) error {
    method MarshalYAML (line 369) | func (c Cfg) MarshalYAML() ([]byte, error) {
    method UnmarshalYAML (line 390) | func (c *Cfg) UnmarshalYAML(b []byte) error {
  type pluginConfigs (line 79) | type pluginConfigs
  type pluginConfig (line 82) | type pluginConfig
  function New (line 85) | func New() config.Config {
  function init (line 89) | func init() {

FILE: pkg/config/v3/config_test.go
  function TestConfigV3 (line 30) | func TestConfigV3(t *testing.T) {

FILE: pkg/config/version.go
  type Version (line 35) | type Version struct
    method Parse (line 44) | func (v *Version) Parse(version string) error {
    method String (line 72) | func (v Version) String() string {
    method Validate (line 81) | func (v Version) Validate() error {
    method Compare (line 94) | func (v Version) Compare(other Version) int {
    method IsStable (line 105) | func (v Version) IsStable() bool {
    method MarshalJSON (line 110) | func (v Version) MarshalJSON() ([]byte, error) {
    method UnmarshalJSON (line 124) | func (v *Version) UnmarshalJSON(b []byte) error {

FILE: pkg/machinery/errors.go
  type ValidateError (line 27) | type ValidateError struct
    method Unwrap (line 32) | func (e ValidateError) Unwrap() error {
  type SetTemplateDefaultsError (line 37) | type SetTemplateDefaultsError struct
    method Unwrap (line 42) | func (e SetTemplateDefaultsError) Unwrap() error {
  type ExistsFileError (line 47) | type ExistsFileError struct
    method Unwrap (line 52) | func (e ExistsFileError) Unwrap() error {
  type OpenFileError (line 57) | type OpenFileError struct
    method Unwrap (line 62) | func (e OpenFileError) Unwrap() error {
  type CreateDirectoryError (line 67) | type CreateDirectoryError struct
    method Unwrap (line 72) | func (e CreateDirectoryError) Unwrap() error {
  type CreateFileError (line 77) | type CreateFileError struct
    method Unwrap (line 82) | func (e CreateFileError) Unwrap() error {
  type ReadFileError (line 87) | type ReadFileError struct
    method Unwrap (line 92) | func (e ReadFileError) Unwrap() error {
  type WriteFileError (line 97) | type WriteFileError struct
    method Unwrap (line 102) | func (e WriteFileError) Unwrap() error {
  type CloseFileError (line 107) | type CloseFileError struct
    method Unwrap (line 112) | func (e CloseFileError) Unwrap() error {
  type ModelAlreadyExistsError (line 117) | type ModelAlreadyExistsError struct
    method Error (line 122) | func (e ModelAlreadyExistsError) Error() string {
  type UnknownIfExistsActionError (line 127) | type UnknownIfExistsActionError struct
    method Error (line 133) | func (e UnknownIfExistsActionError) Error() string {
  type FileAlreadyExistsError (line 138) | type FileAlreadyExistsError struct
    method Error (line 143) | func (e FileAlreadyExistsError) Error() string {

FILE: pkg/machinery/file.go
  type IfExistsAction (line 20) | type IfExistsAction
  constant SkipFile (line 24) | SkipFile IfExistsAction = iota
  constant Error (line 27) | Error
  constant OverwriteFile (line 30) | OverwriteFile
  type IfNotExistsAction (line 34) | type IfNotExistsAction
  constant ErrorIfNotExist (line 38) | ErrorIfNotExist IfNotExistsAction = iota
  constant IgnoreFile (line 41) | IgnoreFile
  type File (line 45) | type File struct

FILE: pkg/machinery/filesystem.go
  type Filesystem (line 24) | type Filesystem struct

FILE: pkg/machinery/funcmap.go
  function DefaultFuncMap (line 29) | func DefaultFuncMap() template.FuncMap {
  function isEmptyString (line 40) | func isEmptyString(s string) bool {
  function hashFNV (line 45) | func hashFNV(s string) string {

FILE: pkg/machinery/injector.go
  type injector (line 25) | type injector struct
    method injectInto (line 37) | func (i injector) injectInto(builder Builder) {

FILE: pkg/machinery/injector_test.go
  type templateBase (line 28) | type templateBase struct
    method GetPath (line 33) | func (t templateBase) GetPath() string {
    method GetIfExistsAction (line 37) | func (t templateBase) GetIfExistsAction() IfExistsAction {
  type templateWithDomain (line 41) | type templateWithDomain struct
    method InjectDomain (line 46) | func (t *templateWithDomain) InjectDomain(domain string) {
  type templateWithRepository (line 50) | type templateWithRepository struct
    method InjectRepository (line 55) | func (t *templateWithRepository) InjectRepository(repository string) {
  type templateWithProjectName (line 59) | type templateWithProjectName struct
    method InjectProjectName (line 64) | func (t *templateWithProjectName) InjectProjectName(projectName string) {
  type templateWithMultiGroup (line 68) | type templateWithMultiGroup struct
    method InjectMultiGroup (line 73) | func (t *templateWithMultiGroup) InjectMultiGroup(multiGroup bool) {
  type templateWithBoilerplate (line 77) | type templateWithBoilerplate struct
    method InjectBoilerplate (line 82) | func (t *templateWithBoilerplate) InjectBoilerplate(boilerplate string) {
  type templateWithResource (line 86) | type templateWithResource struct
    method InjectResource (line 91) | func (t *templateWithResource) InjectResource(res *resource.Resource) {

FILE: pkg/machinery/interfaces.go
  type Builder (line 26) | type Builder interface
  type RequiresValidation (line 34) | type RequiresValidation interface
  type Template (line 41) | type Template interface
  type Inserter (line 54) | type Inserter interface
  type HasIfNotExistsAction (line 63) | type HasIfNotExistsAction interface
  type HasDomain (line 68) | type HasDomain interface
  type HasRepository (line 74) | type HasRepository interface
  type HasProjectName (line 80) | type HasProjectName interface
  type HasMultiGroup (line 86) | type HasMultiGroup interface
  type HasNamespaced (line 92) | type HasNamespaced interface
  type HasBoilerplate (line 98) | type HasBoilerplate interface
  type HasResource (line 104) | type HasResource interface
  type UseCustomFuncMap (line 110) | type UseCustomFuncMap interface

FILE: pkg/machinery/machinery_suite_test.go
  function TestMachinery (line 26) | func TestMachinery(t *testing.T) {

FILE: pkg/machinery/marker.go
  constant kbPrefix (line 25) | kbPrefix = "+kubebuilder:scaffold:"
  type Marker (line 35) | type Marker struct
    method String (line 68) | func (m Marker) String() string {
    method EqualsLine (line 73) | func (m Marker) EqualsLine(line string) bool {
  function NewMarkerFor (line 44) | func NewMarkerFor(path string, value string) Marker {
  function NewMarkerWithPrefixFor (line 50) | func NewMarkerWithPrefixFor(prefix string, path string, value string) Ma...
  type CodeFragments (line 80) | type CodeFragments
  type CodeFragmentsMap (line 83) | type CodeFragmentsMap
  function markerPrefix (line 85) | func markerPrefix(prefix string) string {

FILE: pkg/machinery/mixins.go
  type PathMixin (line 24) | type PathMixin struct
    method GetPath (line 30) | func (t *PathMixin) GetPath() string {
  type IfExistsActionMixin (line 35) | type IfExistsActionMixin struct
    method GetIfExistsAction (line 41) | func (t *IfExistsActionMixin) GetIfExistsAction() IfExistsAction {
  type TemplateMixin (line 46) | type TemplateMixin struct
    method GetBody (line 57) | func (t *TemplateMixin) GetBody() string {
    method SetDelim (line 62) | func (t *TemplateMixin) SetDelim(left, right string) {
    method GetDelim (line 68) | func (t *TemplateMixin) GetDelim() (string, string) {
  type InserterMixin (line 73) | type InserterMixin struct
    method GetIfExistsAction (line 78) | func (t *InserterMixin) GetIfExistsAction() IfExistsAction {
  type DomainMixin (line 84) | type DomainMixin struct
    method InjectDomain (line 90) | func (m *DomainMixin) InjectDomain(domain string) {
  type RepositoryMixin (line 97) | type RepositoryMixin struct
    method InjectRepository (line 103) | func (m *RepositoryMixin) InjectRepository(repository string) {
  type ProjectNameMixin (line 110) | type ProjectNameMixin struct
    method InjectProjectName (line 115) | func (m *ProjectNameMixin) InjectProjectName(projectName string) {
  type MultiGroupMixin (line 122) | type MultiGroupMixin struct
    method InjectMultiGroup (line 128) | func (m *MultiGroupMixin) InjectMultiGroup(flag bool) {
  type NamespacedMixin (line 133) | type NamespacedMixin struct
    method InjectNamespaced (line 139) | func (m *NamespacedMixin) InjectNamespaced(flag bool) {
  type BoilerplateMixin (line 144) | type BoilerplateMixin struct
    method InjectBoilerplate (line 150) | func (m *BoilerplateMixin) InjectBoilerplate(boilerplate string) {
  type ResourceMixin (line 157) | type ResourceMixin struct
    method InjectResource (line 162) | func (m *ResourceMixin) InjectResource(res *resource.Resource) {
  type IfNotExistsActionMixin (line 169) | type IfNotExistsActionMixin struct
    method GetIfNotExistsAction (line 175) | func (m *IfNotExistsActionMixin) GetIfNotExistsAction() IfNotExistsAct...

FILE: pkg/machinery/mixins_test.go
  type mockTemplate (line 26) | type mockTemplate struct
  type mockInserter (line 36) | type mockInserter struct

FILE: pkg/machinery/scaffold.go
  constant createOrUpdate (line 39) | createOrUpdate = os.O_WRONLY | os.O_CREATE | os.O_TRUNC
  constant DefaultDirectoryPermission (line 44) | DefaultDirectoryPermission os.FileMode = 0o755
  constant DefaultFilePermission (line 45) | DefaultFilePermission      os.FileMode = 0o644
  type Scaffold (line 56) | type Scaffold struct
    method Execute (line 126) | func (s *Scaffold) Execute(builders ...Builder) error {
    method buildFileModel (line 167) | func (Scaffold) buildFileModel(t Template, models map[string]*File) er...
    method updateFileModel (line 242) | func (s Scaffold) updateFileModel(i Inserter, models map[string]*File)...
    method loadPreviousModel (line 299) | func (s Scaffold) loadPreviousModel(i Inserter, models map[string]*Fil...
    method loadModelFromFile (line 340) | func (s Scaffold) loadModelFromFile(path string) (f *File, err error) {
    method writeFile (line 508) | func (s Scaffold) writeFile(f *File) error {
  type ScaffoldOption (line 69) | type ScaffoldOption
  function NewScaffold (line 72) | func NewScaffold(fs Filesystem, options ...ScaffoldOption) *Scaffold {
  function WithDirectoryPermissions (line 87) | func WithDirectoryPermissions(dirPerm os.FileMode) ScaffoldOption {
  function WithFilePermissions (line 94) | func WithFilePermissions(filePerm os.FileMode) ScaffoldOption {
  function WithConfig (line 101) | func WithConfig(cfg config.Config) ScaffoldOption {
  function WithBoilerplate (line 112) | func WithBoilerplate(boilerplate string) ScaffoldOption {
  function WithResource (line 119) | func WithResource(res *resource.Resource) ScaffoldOption {
  function doTemplate (line 202) | func doTemplate(t Template) ([]byte, error) {
  function getValidCodeFragments (line 360) | func getValidCodeFragments(i Inserter) CodeFragmentsMap {
  function filterExistingValues (line 377) | func filterExistingValues(content string, codeFragmentsMap CodeFragments...
  function codeFragmentExists (line 402) | func codeFragmentExists(content, codeFragment string) (exists bool, err ...
  function scanMultiline (line 430) | func scanMultiline(content string, scanLines int, scanFunc func(contentG...
  function insertStrings (line 484) | func insertStrings(content string, codeFragmentsMap CodeFragmentsMap) ([...

FILE: pkg/machinery/scaffold_test.go
  type fakeBuilder (line 527) | type fakeBuilder struct
    method GetPath (line 534) | func (f fakeBuilder) GetPath() string {
    method GetIfExistsAction (line 539) | func (f fakeBuilder) GetIfExistsAction() IfExistsAction {
  type fakeRequiresValidation (line 546) | type fakeRequiresValidation struct
    method Validate (line 553) | func (f fakeRequiresValidation) Validate() error {
  type fakeTemplate (line 560) | type fakeTemplate struct
    method SetDelim (line 569) | func (f *fakeTemplate) SetDelim(left, right string) {
    method GetDelim (line 574) | func (f *fakeTemplate) GetDelim() (string, string) {
    method GetBody (line 579) | func (f *fakeTemplate) GetBody() string {
    method SetTemplateDefaults (line 584) | func (f *fakeTemplate) SetTemplateDefaults() error {
  type fakeInserter (line 592) | type fakeInserter struct
    method GetMarkers (line 600) | func (f fakeInserter) GetMarkers() []Marker {
    method GetCodeFragments (line 613) | func (f fakeInserter) GetCodeFragments() CodeFragmentsMap {
  type fakeInserterWithIfNotExists (line 622) | type fakeInserterWithIfNotExists struct
    method GetIfNotExistsAction (line 627) | func (f fakeInserterWithIfNotExists) GetIfNotExistsAction() IfNotExist...

FILE: pkg/model/resource/api.go
  type API (line 24) | type API struct
    method Validate (line 33) | func (api API) Validate() error {
    method Copy (line 43) | func (api API) Copy() API {
    method Update (line 50) | func (api *API) Update(other *API) error {
    method IsEmpty (line 72) | func (api API) IsEmpty() bool {

FILE: pkg/model/resource/gvk.go
  constant versionInternal (line 28) | versionInternal = "__internal"
  constant groupRequired (line 30) | groupRequired   = "group cannot be empty if the domain is empty"
  constant versionRequired (line 31) | versionRequired = "version cannot be empty"
  constant kindRequired (line 32) | kindRequired    = "kind cannot be empty"
  type GVK (line 37) | type GVK struct
    method Validate (line 45) | func (gvk GVK) Validate() error {
    method QualifiedGroup (line 82) | func (gvk GVK) QualifiedGroup() string {
    method IsEqualTo (line 94) | func (gvk GVK) IsEqualTo(other GVK) bool {

FILE: pkg/model/resource/resource.go
  type Resource (line 27) | type Resource struct
    method Validate (line 59) | func (r Resource) Validate() error {
    method PackageName (line 91) | func (r Resource) PackageName() string {
    method ImportAlias (line 100) | func (r Resource) ImportAlias() string {
    method HasAPI (line 109) | func (r Resource) HasAPI() bool {
    method HasController (line 114) | func (r Resource) HasController() bool {
    method HasDefaultingWebhook (line 119) | func (r Resource) HasDefaultingWebhook() bool {
    method HasValidationWebhook (line 124) | func (r Resource) HasValidationWebhook() bool {
    method HasConversionWebhook (line 129) | func (r Resource) HasConversionWebhook() bool {
    method IsExternal (line 134) | func (r Resource) IsExternal() bool {
    method IsRegularPlural (line 139) | func (r Resource) IsRegularPlural() bool {
    method Copy (line 144) | func (r Resource) Copy() Resource {
    method Update (line 159) | func (r *Resource) Update(other Resource) error {
    method Replacer (line 207) | func (r Resource) Replacer() *strings.Replacer {
  function wrapKey (line 202) | func wrapKey(key string) string {

FILE: pkg/model/resource/suite_test.go
  constant v1 (line 26) | v1 = "v1"
  function TestResource (line 28) | func TestResource(t *testing.T) {

FILE: pkg/model/resource/utils.go
  function validateAPIVersion (line 28) | func validateAPIVersion(version string) error {
  function safeImport (line 38) | func safeImport(unsafe string) string {
  function APIPackagePath (line 49) | func APIPackagePath(repo, group, version string, multiGroup bool) string {
  function RegularPlural (line 57) | func RegularPlural(singular string) string {

FILE: pkg/model/resource/webhooks.go
  type Webhooks (line 25) | type Webhooks struct
    method Validate (line 50) | func (webhooks Webhooks) Validate() error {
    method Copy (line 69) | func (webhooks Webhooks) Copy() Webhooks {
    method Update (line 91) | func (webhooks *Webhooks) Update(other *Webhooks) error {
    method IsEmpty (line 140) | func (webhooks Webhooks) IsEmpty() bool {
    method AddSpoke (line 148) | func (webhooks *Webhooks) AddSpoke(version string) {

FILE: pkg/model/stage/stage.go
  type Stage (line 26) | type Stage
    method Parse (line 52) | func (s *Stage) Parse(stage string) error {
    method String (line 67) | func (s Stage) String() string {
    method Validate (line 81) | func (s Stage) Validate() error {
    method Compare (line 94) | func (s Stage) Compare(other Stage) int {
    method IsStable (line 107) | func (s Stage) IsStable() bool {
  constant Stable (line 32) | Stable Stage = iota
  constant Beta (line 34) | Beta Stage = iota
  constant Alpha (line 36) | Alpha Stage = iota
  constant alpha (line 40) | alpha  = "alpha"
  constant beta (line 41) | beta   = "beta"
  constant stable (line 42) | stable = ""
  function ParseStage (line 46) | func ParseStage(stage string) (Stage, error) {

FILE: pkg/model/stage/stage_test.go
  function TestStage (line 27) | func TestStage(t *testing.T) {

FILE: pkg/plugin/bundle.go
  type bundle (line 25) | type bundle struct
    method Name (line 110) | func (b bundle) Name() string {
    method Version (line 115) | func (b bundle) Version() Version {
    method SupportedProjectVersions (line 120) | func (b bundle) SupportedProjectVersions() []config.Version {
    method Plugins (line 125) | func (b bundle) Plugins() []Plugin {
    method Description (line 130) | func (b bundle) Description() string {
    method DeprecationWarning (line 135) | func (b bundle) DeprecationWarning() string {
  type BundleOption (line 36) | type BundleOption
  function WithName (line 39) | func WithName(name string) BundleOption {
  function WithVersion (line 46) | func WithVersion(version Version) BundleOption {
  function WithPlugins (line 53) | func WithPlugins(plugins ...Plugin) BundleOption {
  function WithDeprecationMessage (line 60) | func WithDeprecationMessage(msg string) BundleOption {
  function WithDescription (line 67) | func WithDescription(desc string) BundleOption {
  function NewBundleWithOptions (line 75) | func NewBundleWithOptions(opts ...BundleOption) (Bundle, error) {

FILE: pkg/plugin/errors.go
  type ExitError (line 24) | type ExitError struct
    method Error (line 30) | func (e ExitError) Error() string {

FILE: pkg/plugin/external/types.go
  type PluginRequest (line 23) | type PluginRequest struct
  type PluginResponse (line 51) | type PluginResponse struct
  type Flag (line 79) | type Flag struct

FILE: pkg/plugin/filter.go
  function FilterPluginsByKey (line 26) | func FilterPluginsByKey(plugins []Plugin, key string) ([]Plugin, error) {
  function FilterPluginsByProjectVersion (line 50) | func FilterPluginsByProjectVersion(plugins []Plugin, projectVersion conf...

FILE: pkg/plugin/helpers.go
  function KeyFor (line 31) | func KeyFor(p Plugin) string {
  function SplitKey (line 36) | func SplitKey(key string) (string, string) {
  function GetPluginKeyForConfig (line 48) | func GetPluginKeyForConfig(pluginChain []string, p Plugin) string {
  function Validate (line 88) | func Validate(p Plugin) error {
  function ValidateKey (line 107) | func ValidateKey(key string) error {
  function validateName (line 123) | func validateName(name string) error {
  function SupportsVersion (line 131) | func SupportsVersion(p Plugin, projectVersion config.Version) bool {
  function CommonSupportedProjectVersions (line 141) | func CommonSupportedProjectVersions(plugins ...Plugin) []config.Version {

FILE: pkg/plugin/helpers_test.go
  constant short (line 30) | short = "go"
  constant name (line 31) | name  = "go.kubebuilder.io"
  constant key (line 32) | key   = "go.kubebuilder.io/v1"

FILE: pkg/plugin/metadata.go
  type CLIMetadata (line 20) | type CLIMetadata struct
  type SubcommandMetadata (line 26) | type SubcommandMetadata struct

FILE: pkg/plugin/plugin.go
  type Plugin (line 24) | type Plugin interface
  type Deprecated (line 39) | type Deprecated interface
  type Describable (line 46) | type Describable interface
  type Init (line 52) | type Init interface
  type CreateAPI (line 59) | type CreateAPI interface
  type CreateWebhook (line 66) | type CreateWebhook interface
  type Edit (line 73) | type Edit interface
  type Full (line 80) | type Full interface
  type Bundle (line 88) | type Bundle interface

FILE: pkg/plugin/subcommand.go
  type UpdatesMetadata (line 28) | type UpdatesMetadata interface
  type HasFlags (line 34) | type HasFlags interface
  type RequiresConfig (line 40) | type RequiresConfig interface
  type RequiresResource (line 46) | type RequiresResource interface
  type HasPreScaffold (line 52) | type HasPreScaffold interface
  type Scaffolder (line 58) | type Scaffolder interface
  type HasPostScaffold (line 64) | type HasPostScaffold interface
  type Subcommand (line 70) | type Subcommand interface
  type InitSubcommand (line 75) | type InitSubcommand interface
  type CreateAPISubcommand (line 80) | type CreateAPISubcommand interface
  type CreateWebhookSubcommand (line 86) | type CreateWebhookSubcommand interface
  type EditSubcommand (line 92) | type EditSubcommand interface

FILE: pkg/plugin/suite_test.go
  function TestPlugin (line 28) | func TestPlugin(t *testing.T) {
  type mockPlugin (line 33) | type mockPlugin struct
    method Name (line 39) | func (p mockPlugin) Name() string                               { retu...
    method Version (line 40) | func (p mockPlugin) Version() Version                           { retu...
    method SupportedProjectVersions (line 41) | func (p mockPlugin) SupportedProjectVersions() []config.Version { retu...

FILE: pkg/plugin/util/exec.go
  function RunCmd (line 27) | func RunCmd(msg, cmd string, args ...string) error {

FILE: pkg/plugin/util/stdin.go
  function YesNo (line 28) | func YesNo(reader *bufio.Reader) bool {
  function readStdin (line 44) | func readStdin(reader *bufio.Reader) string {

FILE: pkg/plugin/util/suite_test.go
  function TestStage (line 26) | func TestStage(t *testing.T) {

FILE: pkg/plugin/util/util.go
  constant KubebuilderBinName (line 33) | KubebuilderBinName = "kubebuilder"
  function RandomSuffix (line 37) | func RandomSuffix() (string, error) {
  function GetNonEmptyLines (line 53) | func GetNonEmptyLines(output string) []string {
  function InsertCode (line 66) | func InsertCode(filename, target, code string) error {
  function InsertCodeIfNotExist (line 86) | func InsertCodeIfNotExist(filename, target, code string) error {
  function AppendCodeIfNotExist (line 102) | func AppendCodeIfNotExist(filename, code string) error {
  function AppendCodeAtTheEnd (line 116) | func AppendCodeAtTheEnd(filename, code string) error {
  function UncommentCode (line 136) | func UncommentCode(filename, target, prefix string) error {
  function CommentCode (line 185) | func CommentCode(filename, target, prefix string) error {
  function EnsureExistAndReplace (line 227) | func EnsureExistAndReplace(input, match, replace string) (string, error) {
  function ReplaceInFile (line 235) | func ReplaceInFile(path, oldValue, newValue string) error {
  function ReplaceRegexInFile (line 260) | func ReplaceRegexInFile(path, match, replace string) error {
  function HasFileContentWith (line 287) | func HasFileContentWith(path, text string) (bool, error) {

FILE: pkg/plugin/version.go
  type Version (line 34) | type Version struct
    method Parse (line 43) | func (v *Version) Parse(version string) error {
    method String (line 70) | func (v Version) String() string {
    method Validate (line 79) | func (v Version) Validate() error {
    method Compare (line 92) | func (v Version) Compare(other Version) int {
    method IsStable (line 103) | func (v Version) IsStable() bool {

FILE: pkg/plugins/common/kustomize/v2/api.go
  type createAPISubcommand (line 29) | type createAPISubcommand struct
    method Scaffold (line 33) | func (p *createAPISubcommand) Scaffold(fs machinery.Filesystem) error {

FILE: pkg/plugins/common/kustomize/v2/create.go
  type createSubcommand (line 26) | type createSubcommand struct
    method BindFlags (line 34) | func (p *createSubcommand) BindFlags(fs *pflag.FlagSet) {
    method InjectConfig (line 38) | func (p *createSubcommand) InjectConfig(c config.Config) error {
    method InjectResource (line 43) | func (p *createSubcommand) InjectResource(res *resource.Resource) error {

FILE: pkg/plugins/common/kustomize/v2/init.go
  type initSubcommand (line 36) | type initSubcommand struct
    method UpdateMetadata (line 44) | func (p *initSubcommand) UpdateMetadata(cliMeta plugin.CLIMetadata, su...
    method BindFlags (line 59) | func (p *initSubcommand) BindFlags(fs *pflag.FlagSet) {
    method InjectConfig (line 64) | func (p *initSubcommand) InjectConfig(c config.Config) error {
    method Scaffold (line 91) | func (p *initSubcommand) Scaffold(fs machinery.Filesystem) error {

FILE: pkg/plugins/common/kustomize/v2/init_test.go
  constant testDomain (line 30) | testDomain = "example.com"

FILE: pkg/plugins/common/kustomize/v2/plugin.go
  constant KustomizeVersion (line 28) | KustomizeVersion = "v5.8.1"
  constant pluginName (line 30) | pluginName = "kustomize.common." + plugins.DefaultNameQualifier
  type Plugin (line 44) | type Plugin struct
    method Name (line 51) | func (Plugin) Name() string { return pluginName }
    method Version (line 54) | func (Plugin) Version() plugin.Version { return pluginVersion }
    method SupportedProjectVersions (line 57) | func (Plugin) SupportedProjectVersions() []config.Version { return sup...
    method GetInitSubcommand (line 60) | func (p Plugin) GetInitSubcommand() plugin.InitSubcommand { return &p....
    method GetCreateAPISubcommand (line 63) | func (p Plugin) GetCreateAPISubcommand() plugin.CreateAPISubcommand { ...
    method GetCreateWebhookSubcommand (line 66) | func (p Plugin) GetCreateWebhookSubcommand() plugin.CreateWebhookSubco...
    method Description (line 71) | func (Plugin) Description() string {
    method DeprecationWarning (line 76) | func (p Plugin) DeprecationWarning() string {

FILE: pkg/plugins/common/kustomize/v2/scaffolds/api.go
  type apiScaffolder (line 38) | type apiScaffolder struct
    method InjectFS (line 59) | func (s *apiScaffolder) InjectFS(fs machinery.Filesystem) {
    method Scaffold (line 64) | func (s *apiScaffolder) Scaffold() error {
  function NewAPIScaffolder (line 50) | func NewAPIScaffolder(cfg config.Config, res resource.Resource, force bo...
  constant adminEditViewRulesCommentFragment (line 136) | adminEditViewRulesCommentFragment = `# For each CRD, "Admin", "Editor" a...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/edit.go
  type editScaffolder (line 31) | type editScaffolder struct
    method InjectFS (line 50) | func (s *editScaffolder) InjectFS(fs machinery.Filesystem) {
    method Scaffold (line 55) | func (s *editScaffolder) Scaffold() error {
  function NewEditScaffolder (line 41) | func NewEditScaffolder(cfg config.Config, namespaced bool, force bool) p...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/init.go
  constant imageName (line 34) | imageName = "controller:latest"
  type initScaffolder (line 39) | type initScaffolder struct
    method InjectFS (line 54) | func (s *initScaffolder) InjectFS(fs machinery.Filesystem) {
    method Scaffold (line 59) | func (s *initScaffolder) Scaffold() error {
  function NewInitScaffolder (line 47) | func NewInitScaffolder(cfg config.Config) plugins.Scaffolder {

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/certmanager/certificate_metrics.go
  type MetricsCertificate (line 28) | type MetricsCertificate struct
    method SetTemplateDefaults (line 34) | func (f *MetricsCertificate) SetTemplateDefaults() error {
  constant metricsCertManagerTemplate (line 48) | metricsCertManagerTemplate = `# The following manifests contain a self-s...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/certmanager/certificate_webhook.go
  type Certificate (line 28) | type Certificate struct
    method SetTemplateDefaults (line 34) | func (f *Certificate) SetTemplateDefaults() error {
  constant certManagerTemplate (line 47) | certManagerTemplate = `# The following manifests contain a self-signed i...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/certmanager/issuer.go
  type Issuer (line 28) | type Issuer struct
    method SetTemplateDefaults (line 34) | func (f *Issuer) SetTemplateDefaults() error {
  constant issuerTemplate (line 47) | issuerTemplate = `# The following manifest contains a self-signed issuer...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/certmanager/kustomization.go
  type Kustomization (line 28) | type Kustomization struct
    method SetTemplateDefaults (line 33) | func (f *Kustomization) SetTemplateDefaults() error {
  constant kustomizationTemplate (line 46) | kustomizationTemplate = `resources:

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/certmanager/kustomizeconfig.go
  type KustomizeConfig (line 28) | type KustomizeConfig struct
    method SetTemplateDefaults (line 33) | func (f *KustomizeConfig) SetTemplateDefaults() error {
  constant kustomizeConfigTemplate (line 46) | kustomizeConfigTemplate = `# This configuration is for teaching kustomiz...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/crd/kustomization.go
  type Kustomization (line 32) | type Kustomization struct
    method SetTemplateDefaults (line 39) | func (f *Kustomization) SetTemplateDefaults() error {
    method GetMarkers (line 60) | func (f *Kustomization) GetMarkers() []machinery.Marker {
    method GetCodeFragments (line 75) | func (f *Kustomization) GetCodeFragments() machinery.CodeFragmentsMap {
  constant resourceMarker (line 55) | resourceMarker     = "crdkustomizeresource"
  constant webhookPatchMarker (line 56) | webhookPatchMarker = "crdkustomizewebhookpatch"
  constant resourceCodeFragment (line 68) | resourceCodeFragment = `- bases/%s_%s.yaml
  constant webhookPatchCodeFragment (line 70) | webhookPatchCodeFragment = `- path: patches/webhook_in_%s.yaml

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/crd/kustomizeconfig.go
  type KustomizeConfig (line 28) | type KustomizeConfig struct
    method SetTemplateDefaults (line 34) | func (f *KustomizeConfig) SetTemplateDefaults() error {
  constant kustomizeConfigTemplate (line 45) | kustomizeConfigTemplate = `# This file is for teaching kustomize how to ...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/crd/patches/enablecainjection_patch.go
  type EnableCAInjectionPatch (line 28) | type EnableCAInjectionPatch struct
    method SetTemplateDefaults (line 35) | func (f *EnableCAInjectionPatch) SetTemplateDefaults() error {
  constant enableCAInjectionPatchTemplate (line 50) | enableCAInjectionPatchTemplate = `# The following patch adds a directive...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/crd/patches/enablewebhook_patch.go
  type EnableWebhookPatch (line 28) | type EnableWebhookPatch struct
    method SetTemplateDefaults (line 35) | func (f *EnableWebhookPatch) SetTemplateDefaults() error {
  constant enableWebhookPatchTemplate (line 50) | enableWebhookPatchTemplate = `# The following patch enables a conversion...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/kdefault/cert_metrics_manager_patch.go
  type CertManagerMetricsPatch (line 28) | type CertManagerMetricsPatch struct
    method SetTemplateDefaults (line 36) | func (f *CertManagerMetricsPatch) SetTemplateDefaults() error {
  constant metricsManagerPatchTemplate (line 54) | metricsManagerPatchTemplate = `# This patch adds the args, volumes, and ...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/kdefault/kustomization.go
  type Kustomization (line 28) | type Kustomization struct
    method SetTemplateDefaults (line 35) | func (f *Kustomization) SetTemplateDefaults() error {
  constant kustomizeTemplate (line 47) | kustomizeTemplate = `# Adds namespace to all resources.

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/kdefault/kustomization_conversion_updater.go
  constant caNamespace (line 27) | caNamespace = "crdkustomizecainjectionns"
  constant caName (line 28) | caName      = "crdkustomizecainjectionname"
  type KustomizationCAConversionUpdater (line 32) | type KustomizationCAConversionUpdater struct
    method SetTemplateDefaults (line 38) | func (f *KustomizationCAConversionUpdater) SetTemplateDefaults() error {
    method GetMarkers (line 47) | func (f *KustomizationCAConversionUpdater) GetMarkers() []machinery.Ma...
    method GetCodeFragments (line 55) | func (f *KustomizationCAConversionUpdater) GetCodeFragments() machiner...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/kdefault/manager_metrics_patch.go
  type ManagerMetricsPatch (line 28) | type ManagerMetricsPatch struct
    method SetTemplateDefaults (line 33) | func (f *ManagerMetricsPatch) SetTemplateDefaults() error {
  constant kustomizeMetricsPatchTemplate (line 45) | kustomizeMetricsPatchTemplate = `# This patch adds the args to allow exp...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/kdefault/metrics_service.go
  type MetricsService (line 28) | type MetricsService struct
    method SetTemplateDefaults (line 34) | func (f *MetricsService) SetTemplateDefaults() error {
  constant metricsServiceTemplate (line 44) | metricsServiceTemplate = `apiVersion: v1

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/kdefault/webhook_manager_patch.go
  type ManagerWebhookPatch (line 28) | type ManagerWebhookPatch struct
    method SetTemplateDefaults (line 36) | func (f *ManagerWebhookPatch) SetTemplateDefaults() error {
  constant managerWebhookPatchTemplate (line 54) | managerWebhookPatchTemplate = `# This patch ensures the webhook certific...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/manager/config.go
  type Config (line 28) | type Config struct
    method SetTemplateDefaults (line 41) | func (f *Config) SetTemplateDefaults() error {
  constant configTemplate (line 57) | configTemplate = `apiVersion: v1

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/manager/kustomization.go
  type Kustomization (line 28) | type Kustomization struct
    method SetTemplateDefaults (line 33) | func (f *Kustomization) SetTemplateDefaults() error {
  constant kustomizeManagerTemplate (line 45) | kustomizeManagerTemplate = `resources:

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/network-policy/allow-metrics-traffic.go
  type PolicyAllowMetrics (line 29) | type PolicyAllowMetrics struct
    method SetTemplateDefaults (line 35) | func (f *PolicyAllowMetrics) SetTemplateDefaults() error {
  constant metricsNetworkPolicyTemplate (line 45) | metricsNetworkPolicyTemplate = `# This NetworkPolicy allows ingress traffic

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/network-policy/allow-webhook-traffic.go
  type PolicyAllowWebhooks (line 29) | type PolicyAllowWebhooks struct
    method SetTemplateDefaults (line 35) | func (f *PolicyAllowWebhooks) SetTemplateDefaults() error {
  constant webhooksNetworkPolicyTemplate (line 45) | webhooksNetworkPolicyTemplate = `# This NetworkPolicy allows ingress tra...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/network-policy/kustomization.go
  type Kustomization (line 28) | type Kustomization struct
    method SetTemplateDefaults (line 33) | func (f *Kustomization) SetTemplateDefaults() error {
  constant kustomizationTemplate (line 43) | kustomizationTemplate = `resources:

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/prometheus/kustomization.go
  type Kustomization (line 28) | type Kustomization struct
    method SetTemplateDefaults (line 33) | func (f *Kustomization) SetTemplateDefaults() error {
  constant kustomizationTemplate (line 43) | kustomizationTemplate = `resources:

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/prometheus/monitor.go
  type Monitor (line 28) | type Monitor struct
    method SetTemplateDefaults (line 34) | func (f *Monitor) SetTemplateDefaults() error {
  constant serviceMonitorTemplate (line 45) | serviceMonitorTemplate = `# Prometheus Monitor Service (Metrics)

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/prometheus/monitor_tls_patch.go
  type ServiceMonitorPatch (line 29) | type ServiceMonitorPatch struct
    method SetTemplateDefaults (line 35) | func (f *ServiceMonitorPatch) SetTemplateDefaults() error {
  constant serviceMonitorPatchTemplate (line 45) | serviceMonitorPatchTemplate = `# Patch for Prometheus ServiceMonitor to ...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/rbac/cluster_role.go
  type ClusterRole (line 28) | type ClusterRole struct
    method SetTemplateDefaults (line 34) | func (f *ClusterRole) SetTemplateDefaults() error {
  constant clusterRoleTemplate (line 46) | clusterRoleTemplate = `apiVersion: rbac.authorization.k8s.io/v1

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/rbac/cluster_role_binding.go
  type ClusterRoleBinding (line 28) | type ClusterRoleBinding struct
    method SetTemplateDefaults (line 34) | func (f *ClusterRoleBinding) SetTemplateDefaults() error {
  constant clusterRoleBindingTemplate (line 46) | clusterRoleBindingTemplate = `apiVersion: rbac.authorization.k8s.io/v1

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/rbac/crd_admin_role.go
  type CRDAdminRole (line 31) | type CRDAdminRole struct
    method SetTemplateDefaults (line 42) | func (f *CRDAdminRole) SetTemplateDefaults() error {
  constant crdRoleAdminTemplate (line 70) | crdRoleAdminTemplate = `# This rule is not used by the project {{ .Proje...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/rbac/crd_editor_role.go
  type CRDEditorRole (line 31) | type CRDEditorRole struct
    method SetTemplateDefaults (line 42) | func (f *CRDEditorRole) SetTemplateDefaults() error {
  constant crdRoleEditorTemplate (line 70) | crdRoleEditorTemplate = `# This rule is not used by the project {{ .Proj...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/rbac/crd_viewer_role.go
  type CRDViewerRole (line 31) | type CRDViewerRole struct
    method SetTemplateDefaults (line 42) | func (f *CRDViewerRole) SetTemplateDefaults() error {
  constant crdRoleViewerTemplate (line 70) | crdRoleViewerTemplate = `# This rule is not used by the project {{ .Proj...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/rbac/kustomization.go
  type Kustomization (line 28) | type Kustomization struct
    method SetTemplateDefaults (line 33) | func (f *Kustomization) SetTemplateDefaults() error {
  constant kustomizeRBACTemplate (line 45) | kustomizeRBACTemplate = `resources:

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/rbac/leader_election_role.go
  type LeaderElectionRole (line 28) | type LeaderElectionRole struct
    method SetTemplateDefaults (line 34) | func (f *LeaderElectionRole) SetTemplateDefaults() error {
  constant leaderElectionRoleTemplate (line 44) | leaderElectionRoleTemplate = `# permissions to do leader election.

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/rbac/leader_election_role_binding.go
  type LeaderElectionRoleBinding (line 28) | type LeaderElectionRoleBinding struct
    method SetTemplateDefaults (line 34) | func (f *LeaderElectionRoleBinding) SetTemplateDefaults() error {
  constant leaderElectionRoleBindingTemplate (line 44) | leaderElectionRoleBindingTemplate = `apiVersion: rbac.authorization.k8s....

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/rbac/metrics_auth_role.go
  type MetricsAuthRole (line 25) | type MetricsAuthRole struct
    method SetTemplateDefaults (line 31) | func (f *MetricsAuthRole) SetTemplateDefaults() error {
  constant metricsAuthRoleTemplate (line 41) | metricsAuthRoleTemplate = `apiVersion: rbac.authorization.k8s.io/v1

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/rbac/metrics_auth_role_binding.go
  type MetricsAuthRoleBinding (line 25) | type MetricsAuthRoleBinding struct
    method SetTemplateDefaults (line 31) | func (f *MetricsAuthRoleBinding) SetTemplateDefaults() error {
  constant metricsAuthRoleBindingTemplate (line 41) | metricsAuthRoleBindingTemplate = `apiVersion: rbac.authorization.k8s.io/v1

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/rbac/metrics_reader_role.go
  type MetricsReaderRole (line 25) | type MetricsReaderRole struct
    method SetTemplateDefaults (line 31) | func (f *MetricsReaderRole) SetTemplateDefaults() error {
  constant metricsReaderRoleTemplate (line 41) | metricsReaderRoleTemplate = `apiVersion: rbac.authorization.k8s.io/v1

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/rbac/namespaced_role.go
  type NamespacedRole (line 28) | type NamespacedRole struct
    method SetTemplateDefaults (line 34) | func (f *NamespacedRole) SetTemplateDefaults() error {
  constant namespacedRoleTemplate (line 46) | namespacedRoleTemplate = `apiVersion: rbac.authorization.k8s.io/v1

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/rbac/namespaced_role_binding.go
  type NamespacedRoleBinding (line 28) | type NamespacedRoleBinding struct
    method SetTemplateDefaults (line 34) | func (f *NamespacedRoleBinding) SetTemplateDefaults() error {
  constant namespacedRoleBindingTemplate (line 46) | namespacedRoleBindingTemplate = `apiVersion: rbac.authorization.k8s.io/v1

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/rbac/service_account.go
  type ServiceAccount (line 28) | type ServiceAccount struct
    method SetTemplateDefaults (line 34) | func (f *ServiceAccount) SetTemplateDefaults() error {
  constant serviceAccountTemplate (line 44) | serviceAccountTemplate = `apiVersion: v1

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/samples/crd_sample.go
  type CRDSample (line 28) | type CRDSample struct
    method SetTemplateDefaults (line 37) | func (f *CRDSample) SetTemplateDefaults() error {
  constant crdSampleTemplate (line 58) | crdSampleTemplate = `apiVersion: {{ .Resource.QualifiedGroup }}/{{ .Reso...

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/samples/kustomization.go
  type Kustomization (line 32) | type Kustomization struct
    method SetTemplateDefaults (line 38) | func (f *Kustomization) SetTemplateDefaults() error {
    method GetMarkers (line 52) | func (f *Kustomization) GetMarkers() []machinery.Marker {
    method makeCRFileName (line 61) | func (f Kustomization) makeCRFileName() string {
    method GetCodeFragments (line 69) | func (f *Kustomization) GetCodeFragments() machinery.CodeFragmentsMap {
  constant samplesMarker (line 48) | samplesMarker = "manifestskustomizesamples"
  constant samplesCodeFragment (line 56) | samplesCodeFragment = `- %s
  constant kustomizationTemplate (line 75) | kustomizationTemplate = `## Append samples of your project ##

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/webhook/kustomization.go
  type Kustomization (line 28) | type Kustomization struct
    method SetTemplateDefaults (line 36) | func (f *Kustomization) SetTemplateDefaults() error {
  constant kustomizeWebhookTemplate (line 53) | kustomizeWebhookTemplate = `resources:

FILE: pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/webhook/service.go
  type Service (line 28) | type Service struct
    method SetTemplateDefaults (line 34) | func (f *Service) SetTemplateDefaults() error {
  constant serviceTemplate (line 47) | serviceTemplate = `apiVersion: v1

FILE: pkg/plugins/common/kustomize/v2/scaffolds/webhook.go
  constant kustomizeFilePath (line 40) | kustomizeFilePath    = "config/default/kustomization.yaml"
  constant kustomizeCRDFilePath (line 41) | kustomizeCRDFilePath = "config/crd/kustomization.yaml"
  type webhookScaffolder (line 44) | type webhookScaffolder struct
    method InjectFS (line 65) | func (s *webhookScaffolder) InjectFS(fs machinery.Filesystem) { s.fs =...
    method Scaffold (line 68) | func (s *webhookScaffolder) Scaffold() error {
  function NewWebhookScaffolder (line 56) | func NewWebhookScaffolder(cfg config.Config, res resource.Resource, forc...
  function uncommentCodeForConversionWebhooks (line 169) | func uncommentCodeForConversionWebhooks(r resource.Resource) {
  function uncommentCodeForDefaultWebhooks (line 238) | func uncommentCodeForDefaultWebhooks() {
  function uncommentCodeForValidationWebhooks (line 287) | func uncommentCodeForValidationWebhooks() {
  function enableWebhookDefaults (line 336) | func enableWebhookDefaults() {
  function addNetworkPoliciesForWebhooks (line 446) | func addNetworkPoliciesForWebhooks() {
  function validateScaffoldedProject (line 458) | func validateScaffoldedProject() {
  constant allowWebhookTrafficFragment (line 517) | allowWebhookTrafficFragment = `

FILE: pkg/plugins/common/kustomize/v2/suite_test.go
  function TestKustomizeV2Plugin (line 26) | func TestKustomizeV2Plugin(t *testing.T) {

FILE: pkg/plugins/common/kustomize/v2/webhook.go
  type createWebhookSubcommand (line 29) | type createWebhookSubcommand struct
    method Scaffold (line 33) | func (p *createWebhookSubcommand) Scaffold(fs machinery.Filesystem) er...

FILE: pkg/plugins/domain.go
  constant DefaultNameQualifier (line 20) | DefaultNameQualifier = "kubebuilder.io"

FILE: pkg/plugins/external/api.go
  constant defaultAPIVersion (line 32) | defaultAPIVersion = "v1alpha1"
  type createAPISubcommand (line 35) | type createAPISubcommand struct
    method InjectConfig (line 43) | func (p *createAPISubcommand) InjectConfig(c config.Config) error {
    method SetPluginChain (line 57) | func (p *createAPISubcommand) SetPluginChain(chain []string) {
    method InjectResource (line 66) | func (p *createAPISubcommand) InjectResource(*resource.Resource) error {
    method UpdateMetadata (line 71) | func (p *createAPISubcommand) UpdateMetadata(_ plugin.CLIMetadata, sub...
    method BindFlags (line 75) | func (p *createAPISubcommand) BindFlags(fs *pflag.FlagSet) {
    method Scaffold (line 79) | func (p *createAPISubcommand) Scaffold(fs machinery.Filesystem) error {

FILE: pkg/plugins/external/edit.go
  type editSubcommand (line 31) | type editSubcommand struct
    method InjectConfig (line 40) | func (p *editSubcommand) InjectConfig(c config.Config) error {
    method SetPluginChain (line 54) | func (p *editSubcommand) SetPluginChain(chain []string) {
    method UpdateMetadata (line 63) | func (p *editSubcommand) UpdateMetadata(_ plugin.CLIMetadata, subcmdMe...
    method BindFlags (line 67) | func (p *editSubcommand) BindFlags(fs *pflag.FlagSet) {
    method Scaffold (line 71) | func (p *editSubcommand) Scaffold(fs machinery.Filesystem) error {

FILE: pkg/plugins/external/external_test.go
  type chainAwareSubcommand (line 38) | type chainAwareSubcommand interface
  function TestExternalPlugin (line 70) | func TestExternalPlugin(t *testing.T) {
  type mockValidOutputGetter (line 75) | type mockValidOutputGetter struct
    method GetExecOutput (line 81) | func (m *mockValidOutputGetter) GetExecOutput(_ []byte, _ string) ([]b...
  type mockInValidOutputGetter (line 77) | type mockInValidOutputGetter struct
    method GetExecOutput (line 92) | func (m *mockInValidOutputGetter) GetExecOutput(_ []byte, _ string) ([...
  type mockPluginChainCaptureGetter (line 96) | type mockPluginChainCaptureGetter struct
    method GetExecOutput (line 102) | func (m *mockPluginChainCaptureGetter) GetExecOutput(request []byte, _...
  type mockValidOsWdGetter (line 121) | type mockValidOsWdGetter struct
    method GetCurrentDir (line 125) | func (m *mockValidOsWdGetter) GetCurrentDir() (string, error) {
  type mockInValidOsWdGetter (line 129) | type mockInValidOsWdGetter struct
    method GetCurrentDir (line 133) | func (m *mockInValidOsWdGetter) GetCurrentDir() (string, error) {
  type mockConfigOutputGetter (line 137) | type mockConfigOutputGetter struct
    method GetExecOutput (line 143) | func (m *mockConfigOutputGetter) GetExecOutput(reqBytes []byte, _ stri...
  type mockValidFlagOutputGetter (line 157) | type mockValidFlagOutputGetter struct
    method GetExecOutput (line 159) | func (m *mockValidFlagOutputGetter) GetExecOutput(_ []byte, _ string) ...
  type mockValidMEOutputGetter (line 174) | type mockValidMEOutputGetter struct
    method GetExecOutput (line 176) | func (m *mockValidMEOutputGetter) GetExecOutput(_ []byte, _ string) ([...
  constant externalPlugin (line 193) | externalPlugin = "myexternalplugin.sh"
  constant floatVal (line 194) | floatVal       = "float"
  function getFlags (line 1184) | func getFlags() []external.Flag {
  function getMetadata (line 1213) | func getMetadata() plugin.SubcommandMetadata {

FILE: pkg/plugins/external/helpers.go
  constant defaultMetadataTemplate (line 44) | defaultMetadataTemplate = `
  type ExecOutputGetter (line 52) | type ExecOutputGetter interface
  type execOutputGetter (line 56) | type execOutputGetter struct
    method GetExecOutput (line 58) | func (e *execOutputGetter) GetExecOutput(request []byte, path string) ...
  type OsWdGetter (line 73) | type OsWdGetter interface
  type osWdGetter (line 77) | type osWdGetter struct
    method GetCurrentDir (line 79) | func (o *osWdGetter) GetCurrentDir() (string, error) {
  function makePluginRequest (line 88) | func makePluginRequest(req external.PluginRequest, path string) (*extern...
  function getUniverseMap (line 116) | func getUniverseMap(fs machinery.Filesystem) (map[string]string, error) {
  function handlePluginResponse (line 155) | func handlePluginResponse(fs machinery.Filesystem, req external.PluginRe...
  function getExternalPluginFlags (line 219) | func getExternalPluginFlags(req external.PluginRequest, path string) ([]...
  function isBooleanFlag (line 231) | func isBooleanFlag(argIndex int, args []string) bool {
  function bindAllFlags (line 238) | func bindAllFlags(fs *pflag.FlagSet, args []string) {
  function bindSpecificFlags (line 257) | func bindSpecificFlags(fs *pflag.FlagSet, flags []external.Flag) {
  function filterFlags (line 276) | func filterFlags(flags []external.Flag, externalFlagFilters []externalFl...
  function filterArgs (line 293) | func filterArgs(args []string, argFilters []argFilterFunc) []string {
  type externalFlagFilterFunc (line 311) | type externalFlagFilterFunc
  type argFilterFunc (line 312) | type argFilterFunc
  function bindExternalPluginFlags (line 340) | func bindExternalPluginFlags(fs *pflag.FlagSet, subcommand string, path ...
  function setExternalPluginMetadata (line 372) | func setExternalPluginMetadata(subcommand, path string, subcmdMeta *plug...
  function getExternalPluginMetadata (line 392) | func getExternalPluginMetadata(subcommand, path string) (*plugin.Subcomm...

FILE: pkg/plugins/external/init.go
  type initSubcommand (line 31) | type initSubcommand struct
    method InjectConfig (line 40) | func (p *initSubcommand) InjectConfig(c config.Config) error {
    method SetPluginChain (line 54) | func (p *initSubcommand) SetPluginChain(chain []string) {
    method UpdateMetadata (line 63) | func (p *initSubcommand) UpdateMetadata(_ plugin.CLIMetadata, subcmdMe...
    method BindFlags (line 67) | func (p *initSubcommand) BindFlags(fs *pflag.FlagSet) {
    method Scaffold (line 71) | func (p *initSubcommand) Scaffold(fs machinery.Filesystem) error {

FILE: pkg/plugins/external/plugin.go
  type Plugin (line 27) | type Plugin struct
    method Name (line 37) | func (p Plugin) Name() string { return p.PName }
    method Version (line 40) | func (p Plugin) Version() plugin.Version { return p.PVersion }
    method SupportedProjectVersions (line 43) | func (p Plugin) SupportedProjectVersions() []config.Version { return p...
    method GetInitSubcommand (line 46) | func (p Plugin) GetInitSubcommand() plugin.InitSubcommand {
    method GetCreateAPISubcommand (line 54) | func (p Plugin) GetCreateAPISubcommand() plugin.CreateAPISubcommand {
    method GetCreateWebhookSubcommand (line 62) | func (p Plugin) GetCreateWebhookSubcommand() plugin.CreateWebhookSubco...
    method GetEditSubcommand (line 70) | func (p Plugin) GetEditSubcommand() plugin.EditSubcommand {
    method DeprecationWarning (line 78) | func (p Plugin) DeprecationWarning() string {

FILE: pkg/plugins/external/webhook.go
  type createWebhookSubcommand (line 31) | type createWebhookSubcommand struct
    method InjectConfig (line 39) | func (p *createWebhookSubcommand) InjectConfig(c config.Config) error {
    method SetPluginChain (line 53) | func (p *createWebhookSubcommand) SetPluginChain(chain []string) {
    method InjectResource (line 62) | func (p *createWebhookSubcommand) InjectResource(*resource.Resource) e...
    method UpdateMetadata (line 67) | func (p *createWebhookSubcommand) UpdateMetadata(_ plugin.CLIMetadata,...
    method BindFlags (line 71) | func (p *createWebhookSubcommand) BindFlags(fs *pflag.FlagSet) {
    method Scaffold (line 75) | func (p *createWebhookSubcommand) Scaffold(fs machinery.Filesystem) er...

FILE: pkg/plugins/golang/deploy-image/v1alpha1/api.go
  type createAPISubcommand (line 39) | type createAPISubcommand struct
    method UpdateMetadata (line 65) | func (p *createAPISubcommand) UpdateMetadata(cliMeta plugin.CLIMetadat...
    method BindFlags (line 105) | func (p *createAPISubcommand) BindFlags(fs *pflag.FlagSet) {
    method InjectConfig (line 126) | func (p *createAPISubcommand) InjectConfig(c config.Config) error {
    method InjectResource (line 132) | func (p *createAPISubcommand) InjectResource(res *resource.Resource) e...
    method PreScaffold (line 153) | func (p *createAPISubcommand) PreScaffold(machinery.Filesystem) error {
    method Scaffold (line 177) | func (p *createAPISubcommand) Scaffold(fs machinery.Filesystem) error {
    method PostScaffold (line 238) | func (p *createAPISubcommand) PostScaffold() error {

FILE: pkg/plugins/golang/deploy-image/v1alpha1/plugin.go
  constant pluginName (line 27) | pluginName = "deploy-image." + golang.DefaultNameQualifier
  type Plugin (line 37) | type Plugin struct
    method Name (line 42) | func (Plugin) Name() string { return pluginName }
    method Version (line 45) | func (Plugin) Version() plugin.Version { return pluginVersion }
    method SupportedProjectVersions (line 48) | func (Plugin) SupportedProjectVersions() []config.Version { return sup...
    method GetCreateAPISubcommand (line 51) | func (p Plugin) GetCreateAPISubcommand() plugin.CreateAPISubcommand { ...
    method Description (line 75) | func (Plugin) Description() string {
    method DeprecationWarning (line 80) | func (p Plugin) DeprecationWarning() string {
  type PluginConfig (line 54) | type PluginConfig struct
  type ResourceData (line 59) | type ResourceData struct
  type options (line 67) | type options struct

FILE: pkg/plugins/golang/deploy-image/v1alpha1/plugin_test.go
  function TestGetPluginKeyForConfigIntegration (line 27) | func TestGetPluginKeyForConfigIntegration(t *testing.T) {

FILE: pkg/plugins/golang/deploy-image/v1alpha1/scaffolds/api.go
  type apiScaffolder (line 44) | type apiScaffolder struct
    method InjectFS (line 71) | func (s *apiScaffolder) InjectFS(fs machinery.Filesystem) {
    method Scaffold (line 76) | func (s *apiScaffolder) Scaffold() error {
    method addEnvVarIntoManager (line 151) | func (s *apiScaffolder) addEnvVarIntoManager() error {
    method scaffoldCreateAPI (line 170) | func (s *apiScaffolder) scaffoldCreateAPI() error {
    method updateMainByAddingEventRecorder (line 184) | func (s *apiScaffolder) updateMainByAddingEventRecorder(defaultMainPat...
    method updateControllerCode (line 200) | func (s *apiScaffolder) updateControllerCode(controller controllers.Co...
    method scaffoldCreateAPIFromKustomize (line 277) | func (s *apiScaffolder) scaffoldCreateAPIFromKustomize() error {
    method scaffoldCreateAPIFromGolang (line 293) | func (s *apiScaffolder) scaffoldCreateAPIFromGolang() error {
  function NewDeployImageScaffolder (line 57) | func NewDeployImageScaffolder(cfg config.Config, res resource.Resource, ...
  constant containerTemplate (line 304) | containerTemplate = `Containers: []corev1.Container{{
  constant runAsUserTemplate (line 321) | runAsUserTemplate = `
  constant commandTemplate (line 324) | commandTemplate = `
  constant portTemplate (line 327) | portTemplate = `
  constant recorderTemplate (line 333) | recorderTemplate = `
  constant envVarTemplate (line 336) | envVarTemplate = `

FILE: pkg/plugins/golang/deploy-image/v1alpha1/scaffolds/internal/templates/api/types.go
  type Types (line 31) | type Types struct
    method SetTemplateDefaults (line 42) | func (f *Types) SetTemplateDefaults() error {
  constant typesTemplate (line 62) | typesTemplate = `{{ .Boilerplate }}

FILE: pkg/plugins/golang/deploy-image/v1alpha1/scaffolds/internal/templates/config/samples/crd_sample.go
  type CRDSample (line 29) | type CRDSample struct
    method SetTemplateDefaults (line 39) | func (f *CRDSample) SetTemplateDefaults() error {
  constant crdSampleTemplate (line 57) | crdSampleTemplate = `apiVersion: {{ .Resource.QualifiedGroup }}/{{ .Reso...

FILE: pkg/plugins/golang/deploy-image/v1alpha1/scaffolds/internal/templates/controllers/controller-test.go
  type ControllerTest (line 31) | type ControllerTest struct
    method SetTemplateDefaults (line 42) | func (f *ControllerTest) SetTemplateDefaults() error {
  constant controllerTestTemplate (line 62) | controllerTestTemplate = `{{ .Boilerplate }}

FILE: pkg/plugins/golang/deploy-image/v1alpha1/scaffolds/internal/templates/controllers/controller.go
  type Controller (line 31) | type Controller struct
    method SetTemplateDefaults (line 45) | func (f *Controller) SetTemplateDefaults() error {
  constant controllerTemplate (line 68) | controllerTemplate = `{{ .Boilerplate }}

FILE: pkg/plugins/golang/deploy-image/v1alpha1/suite_test.go
  function TestDeployImageV1Alpha1 (line 26) | func TestDeployImageV1Alpha1(t *testing.T) {

FILE: pkg/plugins/golang/domain.go
  constant DefaultNameQualifier (line 22) | DefaultNameQualifier = "go." + plugins.DefaultNameQualifier

FILE: pkg/plugins/golang/go_version.go
  constant goVerPattern (line 28) | goVerPattern = `^go(?P<major>[0-9]+)\.(?P<minor>[0-9]+)(?:\.(?P<patch>[0...
  type GoVersion (line 34) | type GoVersion struct
    method String (line 39) | func (v GoVersion) String() string {
    method parse (line 57) | func (v *GoVersion) parse(verStr string) error {
    method Compare (line 88) | func (v GoVersion) Compare(other GoVersion) int {
  function MustParse (line 50) | func MustParse(verStr string) (v GoVersion) {
  function ValidateGoVersion (line 126) | func ValidateGoVersion(minVersion, maxVersion GoVersion) error {
  function fetchAndCheckGoVersion (line 134) | func fetchAndCheckGoVersion(minVersion, maxVersion GoVersion) error {
  function checkGoVersion (line 152) | func checkGoVersion(verStr string, minVersion, maxVersion GoVersion) err...

FILE: pkg/plugins/golang/options.go
  type Options (line 53) | type Options struct
    method UpdateResource (line 89) | func (opts Options) UpdateResource(res *resource.Resource, c config.Co...

FILE: pkg/plugins/golang/repository.go
  type goMod (line 30) | type goMod struct
  type module (line 33) | type module struct
  function findGoModulePath (line 38) | func findGoModulePath() (string, error) {
  function FindCurrentRepo (line 58) | func FindCurrentRepo() (string, error) {

FILE: pkg/plugins/golang/suite_test.go
  function TestGoPlugin (line 26) | func TestGoPlugin(t *testing.T) {

FILE: pkg/plugins/golang/v4/api.go
  constant DefaultMainPath (line 38) | DefaultMainPath = "cmd/main.go"
  type createAPISubcommand (line 42) | type createAPISubcommand struct
    method UpdateMetadata (line 60) | func (p *createAPISubcommand) UpdateMetadata(cliMeta plugin.CLIMetadat...
    method BindFlags (line 93) | func (p *createAPISubcommand) BindFlags(fs *pflag.FlagSet) {
    method InjectConfig (line 124) | func (p *createAPISubcommand) InjectConfig(c config.Config) error {
    method InjectResource (line 129) | func (p *createAPISubcommand) InjectResource(res *resource.Resource) e...
    method PreScaffold (line 180) | func (p *createAPISubcommand) PreScaffold(machinery.Filesystem) error {
    method Scaffold (line 189) | func (p *createAPISubcommand) Scaffold(fs machinery.Filesystem) error {
    method PostScaffold (line 199) | func (p *createAPISubcommand) PostScaffold() error {

FILE: pkg/plugins/golang/v4/edit.go
  type editSubcommand (line 32) | type editSubcommand struct
    method UpdateMetadata (line 43) | func (p *editSubcommand) UpdateMetadata(cliMeta plugin.CLIMetadata, su...
    method BindFlags (line 92) | func (p *editSubcommand) BindFlags(fs *pflag.FlagSet) {
    method InjectConfig (line 99) | func (p *editSubcommand) InjectConfig(c config.Config) error {
    method PreScaffold (line 105) | func (p *editSubcommand) PreScaffold(machinery.Filesystem) error {
    method Scaffold (line 118) | func (p *editSubcommand) Scaffold(fs machinery.Filesystem) error {

FILE: pkg/plugins/golang/v4/init.go
  type initSubcommand (line 45) | type initSubcommand struct
    method UpdateMetadata (line 64) | func (p *initSubcommand) UpdateMetadata(cliMeta plugin.CLIMetadata, su...
    method BindFlags (line 121) | func (p *initSubcommand) BindFlags(fs *pflag.FlagSet) {
    method InjectConfig (line 142) | func (p *initSubcommand) InjectConfig(c config.Config) error {
    method PreScaffold (line 173) | func (p *initSubcommand) PreScaffold(machinery.Filesystem) error {
    method Scaffold (line 185) | func (p *initSubcommand) Scaffold(fs machinery.Filesystem) error {
    method PostScaffold (line 208) | func (p *initSubcommand) PostScaffold() error {
  function checkDir (line 221) | func checkDir() error {

FILE: pkg/plugins/golang/v4/init_test.go
  constant testRepo (line 30) | testRepo = "github.com/example/test"

FILE: pkg/plugins/golang/v4/plugin.go
  constant pluginName (line 27) | pluginName = "base." + golang.DefaultNameQualifier
  type Plugin (line 37) | type Plugin struct
    method Name (line 45) | func (Plugin) Name() string { return pluginName }
    method Version (line 48) | func (Plugin) Version() plugin.Version { return pluginVersion }
    method SupportedProjectVersions (line 51) | func (Plugin) SupportedProjectVersions() []config.Version { return sup...
    method GetInitSubcommand (line 54) | func (p Plugin) GetInitSubcommand() plugin.InitSubcommand { return &p....
    method GetCreateAPISubcommand (line 57) | func (p Plugin) GetCreateAPISubcommand() plugin.CreateAPISubcommand { ...
    method GetCreateWebhookSubcommand (line 60) | func (p Plugin) GetCreateWebhookSubcommand() plugin.CreateWebhookSubco...
    method GetEditSubcommand (line 65) | func (p Plugin) GetEditSubcommand() plugin.EditSubcommand { return &p....
    method Description (line 68) | func (Plugin) Description() string {
    method DeprecationWarning (line 73) | func (p Plugin) DeprecationWarning() string {

FILE: pkg/plugins/golang/v4/scaffolds/api.go
  type apiScaffolder (line 40) | type apiScaffolder struct
    method InjectFS (line 61) | func (s *apiScaffolder) InjectFS(fs machinery.Filesystem) {
    method Scaffold (line 66) | func (s *apiScaffolder) Scaffold() error {
  function NewAPIScaffolder (line 52) | func NewAPIScaffolder(cfg config.Config, res resource.Resource, force bo...

FILE: pkg/plugins/golang/v4/scaffolds/edit.go
  type editScaffolder (line 33) | type editScaffolder struct
    method InjectFS (line 54) | func (s *editScaffolder) InjectFS(fs machinery.Filesystem) {
    method Scaffold (line 59) | func (s *editScaffolder) Scaffold() error {
    method scaffoldNamespacedRBAC (line 151) | func (s *editScaffolder) scaffoldNamespacedRBAC(force bool) error {
    method scaffoldClusterRBAC (line 161) | func (s *editScaffolder) scaffoldClusterRBAC(force bool) error {
    method hasWebhooks (line 172) | func (s *editScaffolder) hasWebhooks() bool {
  function NewEditScaffolder (line 44) | func NewEditScaffolder(cfg config.Config, multigroup bool, namespaced bo...

FILE: pkg/plugins/golang/v4/scaffolds/init.go
  constant GolangciLintVersion (line 42) | GolangciLintVersion = "v2.8.0"
  constant ControllerRuntimeVersion (line 44) | ControllerRuntimeVersion = "v0.23.3"
  constant ControllerToolsVersion (line 46) | ControllerToolsVersion = "v0.20.1"
  constant imageName (line 48) | imageName = "controller:latest"
  type initScaffolder (line 55) | type initScaffolder struct
    method InjectFS (line 78) | func (s *initScaffolder) InjectFS(fs machinery.Filesystem) {
    method Scaffold (line 97) | func (s *initScaffolder) Scaffold() error {
  function NewInitScaffolder (line 67) | func NewInitScaffolder(cfg config.Config, license, owner, commandName st...
  function getControllerRuntimeReleaseBranch (line 84) | func getControllerRuntimeReleaseBranch() string {

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/agents.go
  type Agents (line 28) | type Agents struct
    method SetTemplateDefaults (line 39) | func (f *Agents) SetTemplateDefaults() error {
  constant agentsFileTemplate (line 55) | agentsFileTemplate = `# {{ .ProjectName }} - AI Agent Guide

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/api/group.go
  type Group (line 29) | type Group struct
    method SetTemplateDefaults (line 37) | func (f *Group) SetTemplateDefaults() error {
  constant groupTemplate (line 54) | groupTemplate = `{{ .Boilerplate }}

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/api/hub.go
  type Hub (line 31) | type Hub struct
    method SetTemplateDefaults (line 41) | func (f *Hub) SetTemplateDefaults() error {
  constant hubTemplate (line 64) | hubTemplate = `{{ .Boilerplate }}

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/api/spoke.go
  type Spoke (line 29) | type Spoke struct
    method SetTemplateDefaults (line 40) | func (f *Spoke) SetTemplateDefaults() error {
  constant spokeTemplate (line 66) | spokeTemplate = `{{ .Boilerplate }}

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/api/types.go
  type Types (line 31) | type Types struct
    method SetTemplateDefaults (line 41) | func (f *Types) SetTemplateDefaults() error {
  constant typesTemplate (line 65) | typesTemplate = `{{ .Boilerplate }}

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/api/types_updater.go
  constant storageVersionMarker (line 32) | storageVersionMarker = "\n// +kubebuilder:storageversion"
  type TypesUpdater (line 38) | type TypesUpdater struct
    method GetPath (line 45) | func (f *TypesUpdater) GetPath() string {
    method GetIfExistsAction (line 56) | func (*TypesUpdater) GetIfExistsAction() machinery.IfExistsAction {
    method SetTemplateDefaults (line 61) | func (f *TypesUpdater) SetTemplateDefaults() error {
    method addStorageVersionMarker (line 92) | func (f *TypesUpdater) addStorageVersionMarker(content string) string {

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/cmd/main.go
  constant defaultMainPath (line 26) | defaultMainPath = "cmd/main.go"
  type Main (line 31) | type Main struct
    method SetTemplateDefaults (line 42) | func (f *Main) SetTemplateDefaults() error {
  type MainUpdater (line 59) | type MainUpdater struct
    method GetPath (line 75) | func (*MainUpdater) GetPath() string {
    method GetIfExistsAction (line 80) | func (*MainUpdater) GetIfExistsAction() machinery.IfExistsAction {
    method GetMarkers (line 91) | func (f *MainUpdater) GetMarkers() []machinery.Marker {
    method GetCodeFragments (line 148) | func (f *MainUpdater) GetCodeFragments() machinery.CodeFragmentsMap {
  constant importMarker (line 85) | importMarker    = "imports"
  constant addSchemeMarker (line 86) | addSchemeMarker = "scheme"
  constant setupMarker (line 87) | setupMarker     = "builder"
  constant apiImportCodeFragment (line 100) | apiImportCodeFragment = `%s "%s"
  constant controllerImportCodeFragment (line 102) | controllerImportCodeFragment = `"%s/internal/controller"
  constant webhookImportCodeFragment (line 104) | webhookImportCodeFragment = `%s "%s/internal/webhook/%s"
  constant multiGroupWebhookImportCodeFragment (line 106) | multiGroupWebhookImportCodeFragment = `%s "%s/internal/webhook/%s/%s"
  constant multiGroupControllerImportCodeFragment (line 108) | multiGroupControllerImportCodeFragment = `%scontroller "%s/internal/cont...
  constant addschemeCodeFragment (line 110) | addschemeCodeFragment = `utilruntime.Must(%s.AddToScheme(scheme))
  constant reconcilerSetupCodeFragment (line 112) | reconcilerSetupCodeFragment = `if err := (&controller.%sReconciler{
  constant multiGroupReconcilerSetupCodeFragment (line 120) | multiGroupReconcilerSetupCodeFragment = `if err := (&%scontroller.%sReco...
  constant webhookSetupCodeFragmentLegacy (line 128) | webhookSetupCodeFragmentLegacy = `// nolint:goconst
  constant webhookSetupCodeFragment (line 137) | webhookSetupCodeFragment = `// nolint:goconst

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/controllers/controller.go
  type Controller (line 31) | type Controller struct
    method SetTemplateDefaults (line 45) | func (f *Controller) SetTemplateDefaults() error {
  constant controllerTemplate (line 69) | controllerTemplate = `{{ .Boilerplate }}

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/controllers/controller_suitetest.go
  type SuiteTest (line 35) | type SuiteTest struct
    method SetTemplateDefaults (line 48) | func (f *SuiteTest) SetTemplateDefaults() error {
    method GetMarkers (line 85) | func (f *SuiteTest) GetMarkers() []machinery.Marker {
    method GetCodeFragments (line 102) | func (f *SuiteTest) GetCodeFragments() machinery.CodeFragmentsMap {
  constant importMarker (line 80) | importMarker    = "imports"
  constant addSchemeMarker (line 81) | addSchemeMarker = "scheme"
  constant apiImportCodeFragment (line 93) | apiImportCodeFragment = `%s "%s"
  constant addschemeCodeFragment (line 95) | addschemeCodeFragment = `err = %s.AddToScheme(scheme.Scheme)
  constant controllerSuiteTestTemplate (line 128) | controllerSuiteTestTemplate = `{{ .Boilerplate }}

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/controllers/controller_test_template.go
  type ControllerTest (line 31) | type ControllerTest struct
    method SetTemplateDefaults (line 43) | func (f *ControllerTest) SetTemplateDefaults() error {
  constant controllerTestTemplate (line 64) | controllerTestTemplate = `{{ .Boilerplate }}

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/customgcl.go
  type CustomGcl (line 26) | type CustomGcl struct
    method SetTemplateDefaults (line 35) | func (f *CustomGcl) SetTemplateDefaults() error {
  constant customGclTemplate (line 47) | customGclTemplate = `# This file configures golangci-lint with module pl...

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/devcontainer.go
  constant devContainerTemplate (line 33) | devContainerTemplate = `{
  constant postInstallScript (line 70) | postInstallScript = `#!/bin/bash
  type DevContainer (line 231) | type DevContainer struct
    method SetTemplateDefaults (line 241) | func (f *DevContainer) SetTemplateDefaults() error {
  type DevContainerPostInstallScript (line 236) | type DevContainerPostInstallScript struct
    method SetTemplateDefaults (line 252) | func (f *DevContainerPostInstallScript) SetTemplateDefaults() error {

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/dockerfile.go
  type Dockerfile (line 26) | type Dockerfile struct
    method SetTemplateDefaults (line 31) | func (f *Dockerfile) SetTemplateDefaults() error {
  constant dockerfileTemplate (line 41) | dockerfileTemplate = `# Build the manager binary

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/dockerignore.go
  type DockerIgnore (line 26) | type DockerIgnore struct
    method SetTemplateDefaults (line 31) | func (f *DockerIgnore) SetTemplateDefaults() error {
  constant dockerignorefileTemplate (line 41) | dockerignorefileTemplate = `# More info: https://docs.docker.com/engine/...

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/github/lint.go
  type LintCi (line 28) | type LintCi struct
    method SetTemplateDefaults (line 37) | func (f *LintCi) SetTemplateDefaults() error {
  constant lintCiTemplate (line 49) | lintCiTemplate = `name: Lint

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/github/test-e2e.go
  type E2eTestCi (line 28) | type E2eTestCi struct
    method SetTemplateDefaults (line 35) | func (f *E2eTestCi) SetTemplateDefaults() error {
  constant e2eTestCiTemplate (line 47) | e2eTestCiTemplate = `name: E2E Tests

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/github/test.go
  type TestCi (line 28) | type TestCi struct
    method SetTemplateDefaults (line 34) | func (f *TestCi) SetTemplateDefaults() error {
  constant testCiTemplate (line 46) | testCiTemplate = `name: Tests

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/gitignore.go
  type GitIgnore (line 26) | type GitIgnore struct
    method SetTemplateDefaults (line 31) | func (f *GitIgnore) SetTemplateDefaults() error {
  constant gitignoreTemplate (line 41) | gitignoreTemplate = `# Binaries for programs and plugins

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/golangci.go
  type Golangci (line 26) | type Golangci struct
    method SetTemplateDefaults (line 32) | func (f *Golangci) SetTemplateDefaults() error {
  constant golangciTemplate (line 44) | golangciTemplate = `version: "2"

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/gomod.go
  type GoMod (line 26) | type GoMod struct
    method SetTemplateDefaults (line 34) | func (f *GoMod) SetTemplateDefaults() error {
  constant goModTemplate (line 46) | goModTemplate = `module {{ .Repo }}

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/hack/boilerplate.go
  type Boilerplate (line 33) | type Boilerplate struct
    method Validate (line 51) | func (f *Boilerplate) Validate() error {
    method SetTemplateDefaults (line 63) | func (f *Boilerplate) SetTemplateDefaults() error {
  constant boilerplateTemplate (line 97) | boilerplateTemplate = `/*
  constant apache2 (line 110) | apache2 = `

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/makefile.go
  type Makefile (line 26) | type Makefile struct
    method SetTemplateDefaults (line 47) | func (f *Makefile) SetTemplateDefaults() error {
  constant makefileTemplate (line 76) | makefileTemplate = `# Image URL to use all building/pushing image targets

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/readme.go
  type Readme (line 29) | type Readme struct
    method SetTemplateDefaults (line 41) | func (f *Readme) SetTemplateDefaults() error {
  constant readmeFileTemplate (line 67) | readmeFileTemplate = `# {{ .ProjectName }}
  function codeFence (line 170) | func codeFence(code string) string {

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/test/e2e/suite.go
  type SuiteTest (line 26) | type SuiteTest struct
    method SetTemplateDefaults (line 34) | func (f *SuiteTest) SetTemplateDefaults() error {

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/test/e2e/test.go
  constant webhookChecksMarker (line 36) | webhookChecksMarker           = "e2e-webhooks-checks"
  constant metricsWebhookReadinessMarker (line 37) | metricsWebhookReadinessMarker = "e2e-metrics-webhooks-readiness"
  type Test (line 41) | type Test struct
    method SetTemplateDefaults (line 49) | func (f *Test) SetTemplateDefaults() error {
  type WebhookTestUpdater (line 61) | type WebhookTestUpdater struct
    method GetPath (line 69) | func (*WebhookTestUpdater) GetPath() string {
    method GetIfExistsAction (line 74) | func (*WebhookTestUpdater) GetIfExistsAction() machinery.IfExistsAction {
    method GetMarkers (line 79) | func (f *WebhookTestUpdater) GetMarkers() []machinery.Marker {
    method GetCodeFragments (line 87) | func (f *WebhookTestUpdater) GetCodeFragments() machinery.CodeFragment...
  constant webhookChecksFragment (line 188) | webhookChecksFragment = `It("should provisioned cert-manager", func() {
  constant mutatingWebhookChecksFragment (line 200) | mutatingWebhookChecksFragment = `It("should have CA injection for mutati...
  constant validatingWebhookChecksFragment (line 216) | validatingWebhookChecksFragment = `It("should have CA injection for vali...
  constant conversionWebhookChecksFragment (line 232) | conversionWebhookChecksFragment = `It("should have CA injection for %[1]...
  constant webhookEndpointsReadinessFragment (line 248) | webhookEndpointsReadinessFragment = `By("waiting for the webhook service...
  constant mutatingWebhookReadinessFragment (line 261) | mutatingWebhookReadinessFragment = `By("verifying the mutating webhook s...
  constant validatingWebhookReadinessFragment (line 274) | validatingWebhookReadinessFragment = `By("verifying the validating webho...
  constant webhookStabilizationFragment (line 287) | webhookStabilizationFragment = `By("waiting additional time for webhook ...

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/test/utils/utils.go
  type Utils (line 26) | type Utils struct
    method SetTemplateDefaults (line 33) | func (f *Utils) SetTemplateDefaults() error {

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/webhooks/webhook.go
  type Webhook (line 30) | type Webhook struct
    method SetTemplateDefaults (line 52) | func (f *Webhook) SetTemplateDefaults() error {
  constant webhookTemplate (line 92) | webhookTemplate = `{{ .Boilerplate }}
  constant defaultingWebhookTemplate (line 163) | defaultingWebhookTemplate = `
  constant validatingWebhookTemplate (line 194) | validatingWebhookTemplate = `

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/webhooks/webhook_suitetest.go
  type WebhookSuite (line 33) | type WebhookSuite struct
    method SetTemplateDefaults (line 57) | func (f *WebhookSuite) SetTemplateDefaults() error {
    method GetMarkers (line 121) | func (f *WebhookSuite) GetMarkers() []machinery.Marker {
    method GetCodeFragments (line 147) | func (f *WebhookSuite) GetCodeFragments() machinery.CodeFragmentsMap {
  constant admissionImportAlias (line 113) | admissionImportAlias    = "admissionv1"
  constant admissionPath (line 114) | admissionPath           = "k8s.io/api/admission/v1"
  constant importMarker (line 115) | importMarker            = "imports"
  constant addWebhookManagerMarker (line 116) | addWebhookManagerMarker = "webhook"
  constant addSchemeMarker (line 117) | addSchemeMarker         = "scheme"
  constant apiImportCodeFragment (line 130) | apiImportCodeFragment = `%s "%s"
  constant addWebhookManagerCodeFragmentLegacy (line 135) | addWebhookManagerCodeFragmentLegacy = `err = (&%s{}).SetupWebhookWithMan...
  constant addWebhookManagerCodeFragment (line 140) | addWebhookManagerCodeFragment = `err = Setup%sWebhookWithManager(mgr)
  constant webhookTestSuiteTemplate (line 180) | webhookTestSuiteTemplate = `{{ .Boilerplate }}
  constant webhookTestSuiteTemplateLegacy (line 328) | webhookTestSuiteTemplateLegacy = `{{ .Boilerplate }}

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/webhooks/webhook_test_template.go
  type WebhookTest (line 31) | type WebhookTest struct
    method SetTemplateDefaults (line 48) | func (f *WebhookTest) SetTemplateDefaults() error {
  constant webhookTestTemplate (line 87) | webhookTestTemplate = `{{ .Boilerplate }}
  constant conversionWebhookTestTemplate (line 146) | conversionWebhookTestTemplate = `
  constant validateWebhookTestTemplate (line 162) | validateWebhookTestTemplate = `
  constant defaultWebhookTestTemplate (line 201) | defaultWebhookTestTemplate = `

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/webhooks/webhook_test_updater.go
  constant testClosingLine (line 33) | testClosingLine = "\n})\n"
  type WebhookTestUpdater (line 39) | type WebhookTestUpdater struct
    method GetPath (line 46) | func (f *WebhookTestUpdater) GetPath() string {
    method GetIfExistsAction (line 60) | func (*WebhookTestUpdater) GetIfExistsAction() machinery.IfExistsAction {
    method SetTemplateDefaults (line 65) | func (f *WebhookTestUpdater) SetTemplateDefaults() error {
    method addValidatorVariable (line 115) | func (f *WebhookTestUpdater) addValidatorVariable(content string) stri...
    method addDefaulterVariable (line 122) | func (f *WebhookTestUpdater) addDefaulterVariable(content string) stri...
    method addVariableToBlock (line 129) | func (f *WebhookTestUpdater) addVariableToBlock(content, varName, type...
    method detectIndentationInBlock (line 156) | func (f *WebhookTestUpdater) detectIndentationInBlock(blockContent str...
    method addValidatorInit (line 172) | func (f *WebhookTestUpdater) addValidatorInit(content string) string {
    method addDefaulterInit (line 179) | func (f *WebhookTestUpdater) addDefaulterInit(content string) string {
    method addWebhookInit (line 186) | func (f *WebhookTestUpdater) addWebhookInit(content, varName, typeName...
    method addValidationTestContext (line 222) | func (f *WebhookTestUpdater) addValidationTestContext(content string) ...
    method addDefaultingTestContext (line 252) | func (f *WebhookTestUpdater) addDefaultingTestContext(content string) ...
    method addConversionTestContext (line 272) | func (f *WebhookTestUpdater) addConversionTestContext(content string) ...
    method addContextToEnd (line 289) | func (f *WebhookTestUpdater) addContextToEnd(content, testContext stri...

FILE: pkg/plugins/golang/v4/scaffolds/internal/templates/webhooks/webhook_updater.go
  constant coreGroup (line 31) | coreGroup = "core"
  type WebhookUpdater (line 36) | type WebhookUpdater struct
    method GetPath (line 51) | func (f *WebhookUpdater) GetPath() string {
    method GetIfExistsAction (line 65) | func (*WebhookUpdater) GetIfExistsAction() machinery.IfExistsAction {
    method SetTemplateDefaults (line 70) | func (f *WebhookUpdater) SetTemplateDefaults() error {
    method injectBeforeComplete (line 140) | func (f *WebhookUpdater) injectBeforeComplete(content, code string) st...
    method detectIndentationBeforeComplete (line 162) | func (f *WebhookUpdater) detectIndentationBeforeComplete(beforeComplet...
    method adjustCodeIndentation (line 185) | func (f *WebhookUpdater) adjustCodeIndentation(code, targetIndent stri...
    method addAdmissionImport (line 207) | func (f *WebhookUpdater) addAdmissionImport(content string) string {
    method generateDefaulterSetupCode (line 247) | func (f *WebhookUpdater) generateDefaulterSetupCode() string {
    method generateValidatorSetupCode (line 256) | func (f *WebhookUpdater) generateValidatorSetupCode() string {
    method generateDefaultingWebhookCode (line 265) | func (f *WebhookUpdater) generateDefaultingWebhookCode() string {
    method generateValidationWebhookCode (line 320) | func (f *WebhookUpdater) generateValidationWebhookCode() string {
    method getGroupValue (line 399) | func (f *WebhookUpdater) getGroupValue() string {

FILE: pkg/plugins/golang/v4/scaffolds/suite_test.go
  function TestScaffolds (line 28) | func TestScaffolds(t *testing.T) {

FILE: pkg/plugins/golang/v4/scaffolds/webhook.go
  type webhookScaffolder (line 41) | type webhookScaffolder struct
    method InjectFS (line 67) | func (s *webhookScaffolder) InjectFS(fs machinery.Filesystem) {
    method Scaffold (line 72) | func (s *webhookScaffolder) Scaffold() error {
    method getWebhookFilePath (line 195) | func (s *webhookScaffolder) getWebhookFilePath() string {
    method getWebhookTestFilePath (line 214) | func (s *webhookScaffolder) getWebhookTestFilePath() string {
    method scaffoldWebhookFile (line 233) | func (s *webhookScaffolder) scaffoldWebhookFile(scaffold *machinery.Sc...
    method scaffoldWebhookTestFile (line 252) | func (s *webhookScaffolder) scaffoldWebhookTestFile(scaffold *machiner...
  function NewWebhookScaffolder (line 57) | func NewWebhookScaffolder(cfg config.Config, res resource.Resource, forc...

FILE: pkg/plugins/golang/v4/suite_test.go
  function TestV4Plugin (line 26) | func TestV4Plugin(t *testing.T) {

FILE: pkg/plugins/golang/v4/webhook.go
  type createWebhookSubcommand (line 38) | type createWebhookSubcommand struct
    method UpdateMetadata (line 58) | func (p *createWebhookSubcommand) UpdateMetadata(cliMeta plugin.CLIMet...
    method BindFlags (line 89) | func (p *createWebhookSubcommand) BindFlags(fs *pflag.FlagSet) {
    method InjectConfig (line 133) | func (p *createWebhookSubcommand) InjectConfig(c config.Config) error {
    method InjectResource (line 138) | func (p *createWebhookSubcommand) InjectResource(res *resource.Resourc...
    method Scaffold (line 205) | func (p *createWebhookSubcommand) Scaffold(fs machinery.Filesystem) er...
    method PostScaffold (line 215) | func (p *createWebhookSubcommand) PostScaffold() error {
  function isValidVersion (line 244) | func isValidVersion(version string, res *resource.Resource, cfg config.C...

FILE: pkg/plugins/optional/autoupdate/v1alpha/edit.go
  type editSubcommand (line 33) | type editSubcommand struct
    method UpdateMetadata (line 38) | func (p *editSubcommand) UpdateMetadata(cliMeta plugin.CLIMetadata, su...
    method BindFlags (line 49) | func (p *editSubcommand) BindFlags(fs *pflag.FlagSet) {
    method InjectConfig (line 54) | func (p *editSubcommand) InjectConfig(c config.Config) error {
    method PreScaffold (line 59) | func (p *editSubcommand) PreScaffold(machinery.Filesystem) error {
    method Scaffold (line 70) | func (p *editSubcommand) Scaffold(fs machinery.Filesystem) error {
    method PostScaffold (line 84) | func (p *editSubcommand) PostScaffold() error {

FILE: pkg/plugins/optional/autoupdate/v1alpha/init.go
  type initSubcommand (line 33) | type initSubcommand struct
    method UpdateMetadata (line 38) | func (p *initSubcommand) UpdateMetadata(cliMeta plugin.CLIMetadata, su...
    method BindFlags (line 49) | func (p *initSubcommand) BindFlags(fs *pflag.FlagSet) {
    method InjectConfig (line 54) | func (p *initSubcommand) InjectConfig(c config.Config) error {
    method Scaffold (line 59) | func (p *initSubcommand) Scaffold(fs machinery.Filesystem) error {
    method PostScaffold (line 73) | func (p *initSubcommand) PostScaffold() error {

FILE: pkg/plugins/optional/autoupdate/v1alpha/plugin.go
  constant metaDataDescription (line 31) | metaDataDescription = `This plugin scaffolds a GitHub Action that helps ...
  constant pluginName (line 53) | pluginName = "autoupdate." + plugins.DefaultNameQualifier
  type Plugin (line 61) | type Plugin struct
    method Name (line 74) | func (Plugin) Name() string { return pluginName }
    method Version (line 77) | func (Plugin) Version() plugin.Version { return pluginVersion }
    method SupportedProjectVersions (line 80) | func (Plugin) SupportedProjectVersions() []config.Version { return sup...
    method GetEditSubcommand (line 83) | func (p Plugin) GetEditSubcommand() plugin.EditSubcommand { return &p....
    method GetInitSubcommand (line 86) | func (p Plugin) GetInitSubcommand() plugin.InitSubcommand { return &p....
    method Description (line 89) | func (Plugin) Description() string {
    method DeprecationWarning (line 94) | func (p Plugin) DeprecationWarning() string {
  type PluginConfig (line 69) | type PluginConfig struct
  function insertPluginMetaToConfig (line 99) | func insertPluginMetaToConfig(target config.Config, cfg PluginConfig) er...

FILE: pkg/plugins/optional/autoupdate/v1alpha/scaffolds/init.go
  type initScaffolder (line 31) | type initScaffolder struct
    method InjectFS (line 49) | func (s *initScaffolder) InjectFS(fs machinery.Filesystem) {
    method Scaffold (line 54) | func (s *initScaffolder) Scaffold() error {
  function NewInitScaffolder (line 42) | func NewInitScaffolder(useGHModels bool) plugins.Scaffolder {

FILE: pkg/plugins/optional/autoupdate/v1alpha/scaffolds/internal/github/auto_update.go
  type AutoUpdate (line 28) | type AutoUpdate struct
    method SetTemplateDefaults (line 37) | func (f *AutoUpdate) SetTemplateDefaults() error {
  constant autoUpdateTemplate (line 48) | autoUpdateTemplate = `name: Auto Update

FILE: pkg/plugins/optional/autoupdate/v1alpha/suite_test.go
  function TestAutoupdateV1Alpha (line 26) | func TestAutoupdateV1Alpha(t *testing.T) {

FILE: pkg/plugins/optional/grafana/v1alpha/commons.go
  function InsertPluginMetaToConfig (line 28) | func InsertPluginMetaToConfig(target config.Config, cfg pluginConfig) er...

FILE: pkg/plugins/optional/grafana/v1alpha/constants.go
  constant metaDataDescription (line 20) | metaDataDescription = `This command will add Grafana manifests to the pr...

FILE: pkg/plugins/optional/grafana/v1alpha/edit.go
  type editSubcommand (line 31) | type editSubcommand struct
    method UpdateMetadata (line 35) | func (p *editSubcommand) UpdateMetadata(cliMeta plugin.CLIMetadata, su...
    method InjectConfig (line 43) | func (p *editSubcommand) InjectConfig(c config.Config) error {
    method Scaffold (line 48) | func (p *editSubcommand) Scaffold(fs machinery.Filesystem) error {

FILE: pkg/plugins/optional/grafana/v1alpha/init.go
  type initSubcommand (line 31) | type initSubcommand struct
    method UpdateMetadata (line 35) | func (p *initSubcommand) UpdateMetadata(cliMeta plugin.CLIMetadata, su...
    method InjectConfig (line 43) | func (p *initSubcommand) InjectConfig(c config.Config) error {
    method Scaffold (line 48) | func (p *initSubcommand) Scaffold(fs machinery.Filesystem) error {

FILE: pkg/plugins/optional/grafana/v1alpha/plugin.go
  constant pluginName (line 27) | pluginName = "grafana." + plugins.DefaultNameQualifier
  type Plugin (line 35) | type Plugin struct
    method Name (line 43) | func (Plugin) Name() string { return pluginName }
    method Version (line 46) | func (Plugin) Version() plugin.Version { return pluginVersion }
    method SupportedProjectVersions (line 49) | func (Plugin) SupportedProjectVersions() []config.Version { return sup...
    method GetInitSubcommand (line 52) | func (p Plugin) GetInitSubcommand() plugin.InitSubcommand { return &p....
    method GetEditSubcommand (line 55) | func (p Plugin) GetEditSubcommand() plugin.EditSubcommand { return &p....
    method Description (line 60) | func (Plugin) Description() string {
    method DeprecationWarning (line 65) | func (p Plugin) DeprecationWarning() string {
  type pluginConfig (line 57) | type pluginConfig struct

FILE: pkg/plugins/optional/grafana/v1alpha/scaffolds/edit.go
  constant configFilePath (line 35) | configFilePath = "grafana/custom-metrics/config.yaml"
  type editScaffolder (line 37) | type editScaffolder struct
    method InjectFS (line 48) | func (s *editScaffolder) InjectFS(fs machinery.Filesystem) {
    method Scaffold (line 166) | func (s *editScaffolder) Scaffold() error {
  function NewEditScaffolder (line 43) | func NewEditScaffolder() plugins.Scaffolder {
  function fileExist (line 52) | func fileExist(configFilePath string) bool {
  function loadConfig (line 59) | func loadConfig(configPath string) ([]templates.CustomMetricItem, error) {
  function configReader (line 82) | func configReader(reader io.Reader) ([]templates.CustomMetricItem, error) {
  function validateCustomMetricItems (line 100) | func validateCustomMetricItems(rawItems []templates.CustomMetricItem) []...
  function hasFields (line 119) | func hasFields(item templates.CustomMetricItem) bool {
  function fillMissingExpr (line 135) | func fillMissingExpr(item templates.CustomMetricItem) templates.CustomMe...
  function fillMissingUnit (line 150) | func fillMissingUnit(item templates.CustomMetricItem) templates.CustomMe...

FILE: pkg/plugins/optional/grafana/v1alpha/scaffolds/edit_test.go
  function fileExists (line 502) | func fileExists(path string) bool {

FILE: pkg/plugins/optional/grafana/v1alpha/scaffolds/init.go
  type initScaffolder (line 30) | type initScaffolder struct
    method InjectFS (line 41) | func (s *initScaffolder) InjectFS(fs machinery.Filesystem) {
    method Scaffold (line 46) | func (s *initScaffolder) Scaffold() error {
  function NewInitScaffolder (line 36) | func NewInitScaffolder() plugins.Scaffolder {

FILE: pkg/plugins/optional/grafana/v1alpha/scaffolds/init_test.go
  function fileExistsInit (line 83) | func fileExistsInit(path string) bool {

FILE: pkg/plugins/optional/grafana/v1alpha/scaffolds/internal/templates/custom.go
  type CustomMetricsConfigManifest (line 26) | type CustomMetricsConfigManifest struct
    method SetTemplateDefaults (line 32) | func (f *CustomMetricsConfigManifest) SetTemplateDefaults() error {
  constant customMetricsConfigTemplate (line 42) | customMetricsConfigTemplate = `---

FILE: pkg/plugins/optional/grafana/v1alpha/scaffolds/internal/templates/custom_metrics.go
  type CustomMetricsConfig (line 30) | type CustomMetricsConfig struct
  type CustomMetricItem (line 35) | type CustomMetricItem struct
  type CustomMetricsDashManifest (line 45) | type CustomMetricsDashManifest struct
    method SetTemplateDefaults (line 52) | func (f *CustomMetricsDashManifest) SetTemplateDefaults() error {
    method createTemplate (line 76) | func (f *CustomMetricsDashManifest) createTemplate() (string, error) {
  constant customMetricsDashTemplate (line 87) | customMetricsDashTemplate = `{

FILE: pkg/plugins/optional/grafana/v1alpha/scaffolds/internal/templates/resources.go
  type ResourcesManifest (line 28) | type ResourcesManifest struct
    method SetTemplateDefaults (line 33) | func (f *ResourcesManifest) SetTemplateDefaults() error {
  constant controllerResourcesTemplate (line 48) | controllerResourcesTemplate = `{

FILE: pkg/plugins/optional/grafana/v1alpha/scaffolds/internal/templates/runtime.go
  type RuntimeManifest (line 28) | type RuntimeManifest struct
    method SetTemplateDefaults (line 33) | func (f *RuntimeManifest) SetTemplateDefaults() error {
  constant controllerRuntimeTemplate (line 48) | controllerRuntimeTemplate = `{

FILE: pkg/plugins/optional/grafana/v1alpha/scaffolds/scaffolds_test.go
  function fileExistsScaffolds (line 160) | func fileExistsScaffolds(path string) bool {

FILE: pkg/plugins/optional/grafana/v1alpha/scaffolds/suite_test.go
  function TestGrafanaScaffolders (line 26) | func TestGrafanaScaffolders(t *testing.T) {

FILE: pkg/plugins/optional/helm/v1alpha/commons.go
  function insertPluginMetaToConfig (line 27) | func insertPluginMetaToConfig(target config.Config, cfg pluginConfig) er...

FILE: pkg/plugins/optional/helm/v1alpha/edit.go
  type editSubcommand (line 36) | type editSubcommand struct
    method UpdateMetadata (line 42) | func (p *editSubcommand) UpdateMetadata(cliMeta plugin.CLIMetadata, su...
    method BindFlags (line 72) | func (p *editSubcommand) BindFlags(fs *pflag.FlagSet) {
    method InjectConfig (line 76) | func (p *editSubcommand) InjectConfig(c config.Config) error {
    method Scaffold (line 81) | func (p *editSubcommand) Scaffold(fs machinery.Filesystem) error {
    method PostScaffold (line 94) | func (p *editSubcommand) PostScaffold() error {
  function hasWebhooksWith (line 130) | func hasWebhooksWith(c config.Config) bool {

FILE: pkg/plugins/optional/helm/v1alpha/plugin.go
  constant pluginName (line 27) | pluginName = "helm." + plugins.DefaultNameQualifier
  type Plugin (line 35) | type Plugin struct
    method Name (line 44) | func (Plugin) Name() string { return pluginName }
    method Version (line 47) | func (Plugin) Version() plugin.Version { return pluginVersion }
    method SupportedProjectVersions (line 50) | func (Plugin) SupportedProjectVersions() []config.Version { return sup...
    method GetEditSubcommand (line 53) | func (p Plugin) GetEditSubcommand() plugin.EditSubcommand { return &p....
    method Description (line 56) | func (Plugin) Description() string {
    method DeprecationWarning (line 61) | func (p Plugin) DeprecationWarning() string {
  type pluginConfig (line 41) | type pluginConfig struct

FILE: pkg/plugins/optional/helm/v1alpha/scaffolds/edit.go
  type editScaffolder (line 47) | type editScaffolder struct
    method InjectFS (line 64) | func (s *editScaffolder) InjectFS(fs machinery.Filesystem) {
    method Scaffold (line 69) | func (s *editScaffolder) Scaffold() error {
    method getDeployImagesEnvVars (line 135) | func (s *editScaffolder) getDeployImagesEnvVars() map[string]string {
    method extractWebhooksFromGeneratedFiles (line 181) | func (s *editScaffolder) extractWebhooksFromGeneratedFiles() (mutating...
    method copyConfigFiles (line 251) | func (s *editScaffolder) copyConfigFiles() error {
  function NewHelmScaffolder (line 56) | func NewHelmScaffolder(cfg config.Config, force bool) plugins.Scaffolder {
  function copyFileWithHelmLogic (line 313) | func copyFileWithHelmLogic(srcFile, destFile, subDir, projectName string...
  function extractKindAndGroupFromFileName (line 475) | func extractKindAndGroupFromFileName(fileName string) (kind, group strin...
  function getCRDPatchContent (line 485) | func getCRDPatchContent(kind, group string) (string, bool, error) {
  function extractConversionSpec (line 515) | func extractConversionSpec(patchContent string) string {
  function injectConversionSpecWithCondition (line 524) | func injectConversionSpecWithCondition(contentStr, conversionSpec string...
  function injectAnnotations (line 536) | func injectAnnotations(contentStr string, hasWebhookPatch bool) string {
  function isMetricRBACFile (line 558) | func isMetricRBACFile(subDir, srcFile string) bool {
  function removeLabels (line 565) | func removeLabels(content string) string {
  function hasWebhooksWith (line 572) | func hasWebhooksWith(c config.Config) bool {

FILE: pkg/plugins/optional/helm/v1alpha/scaffolds/internal/templates/chart-templates/cert-manager/certificate.go
  type Certificate (line 27) | type Certificate struct
    method SetTemplateDefaults (line 36) | func (f *Certificate) SetTemplateDefaults() error {
  constant certificateTemplate (line 48) | certificateTemplate = `{{` + "`" + `{{- if .Values.certmanager.enable }}...

FILE: pkg/plugins/optional/helm/v1alpha/scaffolds/internal/templates/chart-templates/helpers_tpl.go
  type HelmHelpers (line 28) | type HelmHelpers struct
    method SetTemplateDefaults (line 34) | func (f *HelmHelpers) SetTemplateDefaults() error {
  constant helmHelpersTemplate (line 46) | helmHelpersTemplate = `{{` + "`" + `{{- define "chart.name" -}}` + "`" +...

FILE: pkg/plugins/optional/helm/v1alpha/scaffolds/internal/templates/chart-templates/manager/manager.go
  type Deployment (line 28) | type Deployment struct
    method SetTemplateDefaults (line 41) | func (f *Deployment) SetTemplateDefaults() error {
  constant managerDeploymentTemplate (line 58) | managerDeploymentTemplate = `apiVersion: apps/v1

FILE: pkg/plugins/optional/helm/v1alpha/scaffolds/internal/templates/chart-templates/metrics/metrics_service.go
  type Service (line 27) | type Service struct
    method SetTemplateDefaults (line 33) | func (f *Service) SetTemplateDefaults() error {
  constant metricsServiceTemplate (line 45) | metricsServiceTemplate = `{{` + "`" + `{{- if .Values.metrics.enable }}`...

FILE: pkg/plugins/optional/helm/v1alpha/scaffolds/internal/templates/chart-templates/prometheus/monitor.go
  type Monitor (line 27) | type Monitor struct
    method SetTemplateDefaults (line 33) | func (f *Monitor) SetTemplateDefaults() error {
  constant monitorTemplate (line 45) | monitorTemplate = `# To integrate with Prometheus.

FILE: pkg/plugins/optional/helm/v1alpha/scaffolds/internal/templates/chart-templates/webhook/service.go
  type Service (line 27) | type Service struct
    method SetTemplateDefaults (line 36) | func (f *Service) SetTemplateDefaults() error {
  constant webhookServiceTemplate (line 48) | webhookServiceTemplate = `{{` + "`" + `{{- if .Values.webhook.enable }}`...

FILE: pkg/plugins/optional/helm/v1alpha/scaffolds/internal/templates/chart-templates/webhook/webhook.go
  type Template (line 27) | type Template struct
    method SetTemplateDefaults (line 36) | func (f *Template) SetTemplateDefaults() error {
  type DataWebhook (line 47) | type DataWebhook struct
  type DataWebhookRule (line 59) | type DataWebhookRule struct
  constant webhookTemplate (line 66) | webhookTemplate = `{{` + "`" + `{{- if .Values.webhook.enable }}` + "`" ...

FILE: pkg/plugins/optional/helm/v1alpha/scaffolds/internal/templates/chart.go
  type HelmChart (line 28) | type HelmChart struct
    method SetTemplateDefaults (line 34) | func (f *HelmChart) SetTemplateDefaults() error {
  constant helmChartTemplate (line 46) | helmChartTemplate = `apiVersion: v2

FILE: pkg/plugins/optional/helm/v1alpha/scaffolds/internal/templates/github/test_chart.go
  type HelmChartCI (line 28) | type HelmChartCI struct
    method SetTemplateDefaults (line 34) | func (f *HelmChartCI) SetTemplateDefaults() error {
  constant testChartTemplate (line 47) | testChartTemplate = `name: Test Chart

FILE: pkg/plugins/optional/helm/v1alpha/scaffolds/internal/templates/helmignore.go
  type HelmIgnore (line 28) | type HelmIgnore struct
    method SetTemplateDefaults (line 33) | func (f *HelmIgnore) SetTemplateDefaults() error {
  constant helmIgnoreTemplate (line 45) | helmIgnoreTemplate = `# Patterns to ignore when building Helm packages.

FILE: pkg/plugins/optional/helm/v1alpha/scaffolds/internal/templates/values.go
  type HelmValues (line 27) | type HelmValues struct
    method SetTemplateDefaults (line 40) | func (f *HelmValues) SetTemplateDefaults() error {
  constant helmValuesTemplate (line 55) | helmValuesTemplate = `# [MANAGER]: Manager Deployment Configurations

FILE: pkg/plugins/optional/helm/v2alpha/edit.go
  constant DefaultManifestsFile (line 41) | DefaultManifestsFile = "dist/install.yaml"
  constant DefaultOutputDir (line 43) | DefaultOutputDir = "dist"
  constant v1AlphaPluginKey (line 45) | v1AlphaPluginKey = "helm.kubebuilder.io/v1-alpha"
  type editSubcommand (line 50) | type editSubcommand struct
    method UpdateMetadata (line 58) | func (p *editSubcommand) UpdateMetadata(cliMeta plugin.CLIMetadata, su...
    method BindFlags (line 104) | func (p *editSubcommand) BindFlags(fs *pflag.FlagSet) {
    method InjectConfig (line 111) | func (p *editSubcommand) InjectConfig(c config.Config) error {
    method Scaffold (line 116) | func (p *editSubcommand) Scaffold(fs machinery.Filesystem) error {
    method ensureManifestsExist (line 188) | func (p *editSubcommand) ensureManifestsExist() error {
    method PostScaffold (line 209) | func (p *editSubcommand) PostScaffold() error {
    method addHelmMakefileTargets (line 247) | func (p *editSubcommand) addHelmMakefileTargets(namespace string) error {
    method extractNamespaceFromManifests (line 268) | func (p *editSubcommand) extractNamespaceFromManifests() string {
    method removeV1AlphaPluginEntry (line 400) | func (p *editSubcommand) removeV1AlphaPluginEntry() {
  function getHelmMakefileTargets (line 317) | func getHelmMakefileTargets(projectName, namespace, outputDir string) st...
  constant helmMakefileTemplateFormat (line 330) | helmMakefileTemplateFormat = `
  function helmMakefileTemplate (line 379) | func helmMakefileTemplate(namespace, release, outputDir string) string {
  function hasWebhooksWith (line 383) | func hasWebhooksWith(c config.Config) bool {

FILE: pkg/plugins/optional/helm/v2alpha/plugin.go
  constant pluginName (line 27) | pluginName = "helm." + plugins.DefaultNameQualifier
  type Plugin (line 35) | type Plugin struct
    method Name (line 48) | func (Plugin) Name() string { return pluginName }
    method Version (line 51) | func (Plugin) Version() plugin.Version { return pluginVersion }
    method SupportedProjectVersions (line 54) | func (Plugin) SupportedProjectVersions() []config.Version { return sup...
    method GetEditSubcommand (line 57) | func (p Plugin) GetEditSubcommand() plugin.EditSubcommand { return &p....
    method Description (line 60) | func (Plugin) Description() string {
    method DeprecationWarning (line 65) | func (p Plugin) DeprecationWarning() string {
  type pluginConfig (line 42) | type pluginConfig struct

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/chart_generation_integration_test.go
  function createBasicKustomizeOutput (line 422) | func createBasicKustomizeOutput(projectName string) string {
  function createKustomizeWithCRDAndRBAC (line 466) | func createKustomizeWithCRDAndRBAC(projectName string) string {
  function createKustomizeWithWebhooks (line 502) | func createKustomizeWithWebhooks(projectName string) string {
  function createKustomizeWithWebhooksAndCertManager (line 539) | func createKustomizeWithWebhooksAndCertManager(projectName string) string {
  function createKustomizeWithCustomPrefix (line 571) | func createKustomizeWithCustomPrefix(prefix, projectName string) string {
  function createKustomizeWithFullDeploymentConfig (line 619) | func createKustomizeWithFullDeploymentConfig(projectName string) string {
  function setupKustomizeFile (line 671) | func setupKustomizeFile(filePath, content string) error {

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/edit_kustomize.go
  constant defaultManifestsFile (line 37) | defaultManifestsFile = "dist/install.yaml"
  type editKustomizeScaffolder (line 42) | type editKustomizeScaffolder struct
    method InjectFS (line 61) | func (s *editKustomizeScaffolder) InjectFS(fs machinery.Filesystem) {
    method Scaffold (line 66) | func (s *editKustomizeScaffolder) Scaffold() error {
    method generateKustomizeOutput (line 192) | func (s *editKustomizeScaffolder) generateKustomizeOutput() error {
    method ensureChartDirectoryExists (line 218) | func (s *editKustomizeScaffolder) ensureChartDirectoryExists() error {
  function NewKustomizeHelmScaffolder (line 51) | func NewKustomizeHelmScaffolder(cfg config.Config, force bool, manifests...

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/kustomize/chart_converter.go
  type ChartConverter (line 30) | type ChartConverter struct
    method WriteChartFiles (line 70) | func (c *ChartConverter) WriteChartFiles(fs machinery.Filesystem) error {
    method ExtractDeploymentConfig (line 108) | func (c *ChartConverter) ExtractDeploymentConfig() map[string]any {
  function NewChartConverter (line 45) | func NewChartConverter(resources *ParsedResources, detectedPrefix, chart...
  function dedupeResources (line 90) | func dedupeResources(resources []*unstructured.Unstructured) []*unstruct...
  function extractDeploymentSpec (line 140) | func extractDeploymentSpec(deployment *unstructured.Unstructured) map[st...
  function extractImagePullSecrets (line 154) | func extractImagePullSecrets(specMap map[string]any, config map[string]a...
  function extractPodSecurityContext (line 168) | func extractPodSecurityContext(specMap map[string]any, config map[string...
  function extractPodNodeSelector (line 182) | func extractPodNodeSelector(specMap map[string]any, config map[string]an...
  function extractPodTolerations (line 196) | func extractPodTolerations(specMap map[string]any, config map[string]any) {
  function extractPodAffinity (line 210) | func extractPodAffinity(specMap map[string]any, config map[string]any) {
  function firstManagerContainer (line 224) | func firstManagerContainer(specMap map[string]any) map[string]any {
  function extractContainerEnv (line 243) | func extractContainerEnv(container map[string]any, config map[string]any) {
  function extractContainerImage (line 257) | func extractContainerImage(container map[string]any, config map[string]a...
  function extractContainerArgs (line 286) | func extractContainerArgs(container map[string]any, config map[string]an...
  function extractPortFromArg (line 332) | func extractPortFromArg(arg string) int {
  function extractContainerPorts (line 353) | func extractContainerPorts(container map[string]any, config map[string]a...
  function extractContainerResources (line 392) | func extractContainerResources(container map[string]any, config map[stri...
  function extractContainerSecurityContext (line 406) | func extractContainerSecurityContext(container map[string]any, config ma...

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/kustomize/chart_writer.go
  type ChartWriter (line 33) | type ChartWriter struct
    method WriteResourceGroup (line 49) | func (w *ChartWriter) WriteResourceGroup(
    method writeNamespaceFile (line 68) | func (w *ChartWriter) writeNamespaceFile(fs machinery.Filesystem, name...
    method writeGroupDirectory (line 79) | func (w *ChartWriter) writeGroupDirectory(
    method convertToYAML (line 104) | func (w *ChartWriter) convertToYAML(resource *unstructured.Unstructure...
    method shouldSplitFiles (line 113) | func (w *ChartWriter) shouldSplitFiles(groupName string) bool {
    method writeSplitFiles (line 120) | func (w *ChartWriter) writeSplitFiles(
    method generateFileName (line 147) | func (w *ChartWriter) generateFileName(resource *unstructured.Unstruct...
    method writeFileWithNewline (line 190) | func (w *ChartWriter) writeFileWithNewline(fs machinery.Filesystem, fi...
  function NewChartWriter (line 40) | func NewChartWriter(templater *HelmTemplater, outputDir string, managerN...

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/kustomize/helm_templater.go
  constant kindNamespace (line 29) | kindNamespace          = "Namespace"
  constant kindCertificate (line 30) | kindCertificate        = "Certificate"
  constant kindService (line 31) | kindService            = "Service"
  constant kindServiceAccount (line 32) | kindServiceAccount     = "ServiceAccount"
  constant kindRole (line 33) | kindRole               = "Role"
  constant kindClusterRole (line 34) | kindClusterRole        = "ClusterRole"
  constant kindRoleBinding (line 35) | kindRoleBinding        = "RoleBinding"
  constant kindClusterRoleBinding (line 36) | kindClusterRoleBinding = "ClusterRoleBinding"
  constant kindServiceMonitor (line 37) | kindServiceMonitor     = "ServiceMonitor"
  constant kindIssuer (line 38) | kindIssuer             = "Issuer"
  constant kindValidatingWebhook (line 39) | kindValidatingWebhook  = "ValidatingWebhookConfiguration"
  constant kindMutatingWebhook (line 40) | kindMutatingWebhook    = "MutatingWebhookConfiguration"
  constant kindDeployment (line 41) | kindDeployment         = "Deployment"
  constant kindCRD (line 42) | kindCRD                = "CustomResourceDefinition"
  constant apiVersionCertManager (line 45) | apiVersionCertManager = "cert-manager.io/v1"
  constant apiVersionMonitoring (line 46) | apiVersionMonitoring  = "monitoring.coreos.com/v1"
  type HelmTemplater (line 50) | type HelmTemplater struct
    method getDefaultContainerName (line 68) | func (t *HelmTemplater) getDefaultContainerName(yamlContent string) st...
    method resourceNameTemplate (line 82) | func (t *HelmTemplater) resourceNameTemplate(suffix string) string {
    method ApplyHelmSubstitutions (line 87) | func (t *HelmTemplater) ApplyHelmSubstitutions(yamlContent string, res...
    method escapeExistingTemplateSyntax (line 160) | func (t *HelmTemplater) escapeExistingTemplateSyntax(yamlContent strin...
    method substituteProjectNames (line 213) | func (t *HelmTemplater) substituteProjectNames(yamlContent string, _ *...
    method substituteNamespace (line 237) | func (t *HelmTemplater) substituteNamespace(yamlContent string, resour...
    method substituteCertificateDNSNames (line 277) | func (t *HelmTemplater) substituteCertificateDNSNames(yamlContent stri...
    method substituteCertManagerReferences (line 307) | func (t *HelmTemplater) substituteCertManagerReferences(
    method substituteResourceNamesWithPrefix (line 331) | func (t *HelmTemplater) substituteResourceNamesWithPrefix(yamlContent ...
    method addHelmLabelsAndAnnotations (line 388) | func (t *HelmTemplater) addHelmLabelsAndAnnotations(
    method addStandardHelmLabels (line 462) | func (t *HelmTemplater) addStandardHelmLabels(yamlContent string, _ *u...
    method substituteRBACValues (line 531) | func (t *HelmTemplater) substituteRBACValues(yamlContent string) string {
    method substituteCertManagerAnnotations (line 547) | func (t *HelmTemplater) substituteCertManagerAnnotations(yamlContent s...
    method templateDeploymentFields (line 558) | func (t *HelmTemplater) templateDeploymentFields(yamlContent string) s...
    method templateReplicas (line 597) | func (t *HelmTemplater) templateReplicas(yamlContent string) string {
    method templateEnvironmentVariables (line 608) | func (t *HelmTemplater) templateEnvironmentVariables(yamlContent strin...
    method templateResources (line 680) | func (t *HelmTemplater) templateResources(yamlContent string) string {
    method templateSecurityContexts (line 741) | func (t *HelmTemplater) templateSecurityContexts(yamlContent string) s...
    method templateVolumeMounts (line 748) | func (t *HelmTemplater) templateVolumeMounts(yamlContent string) string {
    method templateVolumes (line 755) | func (t *HelmTemplater) templateVolumes(yamlContent string) string {
    method templateImagePullSecrets (line 762) | func (t *HelmTemplater) templateImagePullSecrets(yamlContent string) s...
    method templatePodSecurityContext (line 813) | func (t *HelmTemplater) templatePodSecurityContext(yamlContent string)...
    method templateContainerSecurityContext (line 871) | func (t *HelmTemplater) templateContainerSecurityContext(yamlContent s...
    method templateControllerManagerArgs (line 941) | func (t *HelmTemplater) templateControllerManagerArgs(yamlContent stri...
    method templateImageReference (line 1046) | func (t *HelmTemplater) templateImageReference(yamlContent string) str...
    method templateBasicWithStatement (line 1117) | func (t *HelmTemplater) templateBasicWithStatement(
    method makeWebhookAnnotationsConditional (line 1200) | func (t *HelmTemplater) makeWebhookAnnotationsConditional(yamlContent ...
    method makeContainerArgsConditional (line 1225) | func (t *HelmTemplater) makeContainerArgsConditional(yamlContent strin...
    method makeWebhookVolumesConditional (line 1291) | func (t *HelmTemplater) makeWebhookVolumesConditional(yamlContent stri...
    method makeWebhookVolumeMountsConditional (line 1303) | func (t *HelmTemplater) makeWebhookVolumeMountsConditional(yamlContent...
    method makeMetricsVolumesConditional (line 1317) | func (t *HelmTemplater) makeMetricsVolumesConditional(yamlContent stri...
    method makeMetricsVolumeMountsConditional (line 1359) | func (t *HelmTemplater) makeMetricsVolumeMountsConditional(yamlContent...
    method injectCRDResourcePolicyAnnotation (line 1400) | func (t *HelmTemplater) injectCRDResourcePolicyAnnotation(yamlContent ...
    method addConditionalWrappers (line 1461) | func (t *HelmTemplater) addConditionalWrappers(yamlContent string, res...
    method collapseBlankLineAfterIf (line 1529) | func (t *HelmTemplater) collapseBlankLineAfterIf(yamlContent string) s...
    method templatePorts (line 1556) | func (t *HelmTemplater) templatePorts(yamlContent string, resource *un...
  function NewHelmTemplater (line 57) | func NewHelmTemplater(detectedPrefix, chartName, managerNamespace string...
  function checkExistingLabels (line 409) | func checkExistingLabels(lines []string, currentIndex int, indent string...
  function leadingWhitespace (line 934) | func leadingWhitespace(line string) (string, int) {
  function makeYamlContent (line 1263) | func makeYamlContent(match string) string {

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/kustomize/helm_templater_test.go
  constant expectedIssuerName (line 29) | expectedIssuerName = `name: {{ include "test-project.resourceName" (dict...

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/kustomize/parser.go
  type ParsedResources (line 30) | type ParsedResources struct
    method GetIgnoredCustomResources (line 204) | func (pr *ParsedResources) GetIgnoredCustomResources() []*unstructured...
    method EstimatePrefix (line 221) | func (pr *ParsedResources) EstimatePrefix(projectName string) string {
  type Parser (line 63) | type Parser struct
    method Parse (line 73) | func (p *Parser) Parse() (*ParsedResources, error) {
    method ParseFromReader (line 86) | func (p *Parser) ParseFromReader(reader io.Reader) (*ParsedResources, ...
    method categorizeResource (line 128) | func (p *Parser) categorizeResource(obj *unstructured.Unstructured, re...
    method identifyCustomResources (line 165) | func (p *Parser) identifyCustomResources(resources *ParsedResources) {
  function NewParser (line 68) | func NewParser(filePath string) *Parser {
  function extractAPIGroup (line 213) | func extractAPIGroup(apiVersion string) string {

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/kustomize/resource_organizer.go
  type ResourceOrganizer (line 26) | type ResourceOrganizer struct
    method OrganizeByFunction (line 38) | func (o *ResourceOrganizer) OrganizeByFunction() map[string][]*unstruc...
    method collectRBACResources (line 92) | func (o *ResourceOrganizer) collectRBACResources() []*unstructured.Uns...
    method collectWebhookResources (line 110) | func (o *ResourceOrganizer) collectWebhookResources() []*unstructured....
    method collectCertManagerResources (line 127) | func (o *ResourceOrganizer) collectCertManagerResources() []*unstructu...
    method collectMetricsResources (line 142) | func (o *ResourceOrganizer) collectMetricsResources() []*unstructured....
    method collectPrometheusResources (line 156) | func (o *ResourceOrganizer) collectPrometheusResources() []*unstructur...
    method isWebhookService (line 167) | func (o *ResourceOrganizer) isWebhookService(service *unstructured.Uns...
    method isMetricsService (line 180) | func (o *ResourceOrganizer) isMetricsService(service *unstructured.Uns...
    method collectExtrasResources (line 191) | func (o *ResourceOrganizer) collectExtrasResources() []*unstructured.U...
  function NewResourceOrganizer (line 31) | func NewResourceOrganizer(resources *ParsedResources) *ResourceOrganizer {

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/kustomize/suite_test.go
  function TestKustomize (line 26) | func TestKustomize(t *testing.T) {

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/templates/chart-templates/consts.go
  constant defaultOutputDir (line 19) | defaultOutputDir = "dist"

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/templates/chart-templates/helpers_tpl.go
  type HelmHelpers (line 29) | type HelmHelpers struct
    method SetTemplateDefaults (line 40) | func (f *HelmHelpers) SetTemplateDefaults() error {
    method generateHelpersTemplate (line 61) | func (f *HelmHelpers) generateHelpersTemplate() string {
  constant helmHelpersTemplate (line 70) | helmHelpersTemplate = `{{` + "`" + `{{/*

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/templates/chart-templates/notes.go
  type Notes (line 28) | type Notes struct
    method SetTemplateDefaults (line 39) | func (f *Notes) SetTemplateDefaults() error {
    method generateNotesTemplate (line 60) | func (f *Notes) generateNotesTemplate() string {
  constant notesTemplate (line 64) | notesTemplate = `Thank you for installing {{` + "`" + `{{ .Chart.Name }}...

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/templates/chart-templates/servicemonitor.go
  type ServiceMonitor (line 29) | type ServiceMonitor struct
    method SetTemplateDefaults (line 43) | func (f *ServiceMonitor) SetTemplateDefaults() error {
  constant serviceMonitorTemplate (line 60) | serviceMonitorTemplate = `{{` + "`" + `{{- if .Values.prometheus.enable ...

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/templates/chart-templates/suite_test.go
  function TestChartTemplates (line 26) | func TestChartTemplates(t *testing.T) {

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/templates/chart.go
  constant defaultOutputDir (line 25) | defaultOutputDir = "dist"
  type HelmChart (line 30) | type HelmChart struct
    method SetTemplateDefaults (line 41) | func (f *HelmChart) SetTemplateDefaults() error {
  constant helmChartTemplate (line 58) | helmChartTemplate = `apiVersion: v2

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/templates/github/test_chart.go
  type HelmChartCI (line 28) | type HelmChartCI struct
    method SetTemplateDefaults (line 37) | func (f *HelmChartCI) SetTemplateDefaults() error {
  constant testChartTemplate (line 53) | testChartTemplate = `name: Test Chart

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/templates/helmignore.go
  type HelmIgnore (line 28) | type HelmIgnore struct
    method SetTemplateDefaults (line 38) | func (f *HelmIgnore) SetTemplateDefaults() error {
  constant helmIgnoreTemplate (line 58) | helmIgnoreTemplate = `# Patterns to ignore when building Helm packages.

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/templates/suite_test.go
  function TestTemplates (line 26) | func TestTemplates(t *testing.T) {

FILE: pkg/plugins/optional/helm/v2alpha/scaffolds/internal/templates/values_basic.go
  type He
Condensed preview — 1314 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (7,877K chars).
[
  {
    "path": ".github/ISSUE_TEMPLATE/bug_report.yaml",
    "chars": 3926,
    "preview": "name: Bug Report\ndescription: Problems and issues with code or docs\nlabels:\n- kind/bug\nbody: \n- type: markdown\n  attribu"
  },
  {
    "path": ".github/ISSUE_TEMPLATE/config.yml",
    "chars": 753,
    "preview": "# allow free form issues as an escape hatch.  This can be taken away if people abuse it ;-)\nblank_issues_enabled: true\n\n"
  },
  {
    "path": ".github/ISSUE_TEMPLATE/feature_request.yaml",
    "chars": 2498,
    "preview": "name: Feature request\ndescription: Suggest an idea for this project or its docs\nlabels:\n- kind/feature\nbody:\n- type: mar"
  },
  {
    "path": ".github/PULL_REQUEST_TEMPLATE.md",
    "chars": 912,
    "preview": "<!--\n\nHiya!  Welcome to Kubebuilder!  For a smooth PR process, please ensure\nthat you include the following information:"
  },
  {
    "path": ".github/SECURITY.md",
    "chars": 3133,
    "preview": "# Security Policy\n\n## Security Announcements\n\nJoin the [kubernetes-security-announce] group for security and vulnerabili"
  },
  {
    "path": ".github/dependabot.yml",
    "chars": 1587,
    "preview": "# To get started with Dependabot version updates, you'll need to specify which\n# package ecosystems to update and where "
  },
  {
    "path": ".github/instructions/kubebuilder.instructions.md",
    "chars": 58,
    "preview": "See [AGENTS.md](../../AGENTS.md) for AI agent guidelines.\n"
  },
  {
    "path": ".github/workflows/apidiff.yml",
    "chars": 760,
    "preview": "name: APIDiff\n\non:\n  push:\n    paths-ignore:\n      - '**/*.md'\n  pull_request:\n    paths-ignore:\n      - '**/*.md'\n\njobs"
  },
  {
    "path": ".github/workflows/codeql.yml",
    "chars": 1653,
    "preview": "name: \"CodeQL Advanced\"\n\non:\n  # We are checking both `master` and `book-v4` branches:\n  # - `master` represents the lat"
  },
  {
    "path": ".github/workflows/coverage.yml",
    "chars": 811,
    "preview": "name: Coverage\n\non:\n  push:\n    paths-ignore: ['**/*.md']\n  pull_request:\n    paths-ignore: ['**/*.md']\n\njobs:\n  coverag"
  },
  {
    "path": ".github/workflows/cross-platform-tests.yml",
    "chars": 1104,
    "preview": "name: Cross-Platform Tests\n\n# Trigger the workflow on pull requests and direct pushes to any branch\non:\n  push:\n    path"
  },
  {
    "path": ".github/workflows/external-plugin.yml",
    "chars": 810,
    "preview": "name: External Plugin\n\non:\n  push:\n    paths:\n      - 'pkg/'\n      - 'docs/book/src/simple-external-plugin-tutorial/test"
  },
  {
    "path": ".github/workflows/legacy-webhook-path.yml",
    "chars": 952,
    "preview": "# This test ensure that the legacy webhook path\n# still working. The option is deprecated\n# and should be removed when w"
  },
  {
    "path": ".github/workflows/lint-sample.yml",
    "chars": 1523,
    "preview": "name: Lint Samples\n\non:\n  push:\n    paths:\n      - 'testdata/**'\n      - 'docs/book/src/**/testdata/**'\n      - '.github"
  },
  {
    "path": ".github/workflows/lint.yml",
    "chars": 1247,
    "preview": "name: Lint\n\non:\n  push:\n    paths-ignore:\n      - '**/*.md'\n  pull_request:\n    paths-ignore:\n      - '**/*.md'\n\njobs:\n "
  },
  {
    "path": ".github/workflows/release-version-ci.yml",
    "chars": 1595,
    "preview": "name: Test GoReleaser and CLI Version\n\non:\n  pull_request:\n    branches:\n      - master\n    paths:\n      - 'pkg/**'\n    "
  },
  {
    "path": ".github/workflows/release.yml",
    "chars": 1096,
    "preview": "name: release\non:\n  push:\n    tags:\n      - '*'\n\npermissions:\n  contents: write\n\njobs:\n  goreleaser:\n    runs-on: ubuntu"
  },
  {
    "path": ".github/workflows/scorecard.yml",
    "chars": 3235,
    "preview": "name: Scorecard supply-chain security\non:\n  # For Branch-Protection check. Only the default branch is supported. See\n  #"
  },
  {
    "path": ".github/workflows/spaces.yml",
    "chars": 525,
    "preview": "name: Trailing\n\non:\n  push:\n    paths:\n      - '**/*.md'\n  pull_request:\n    paths:\n      - '**/*.md'\n\njobs:\n  lint:\n   "
  },
  {
    "path": ".github/workflows/test-alpha-generate.yml",
    "chars": 1558,
    "preview": "name: Test Alpha Generate\n\non:\n  push:\n    paths:\n      - 'pkg/cli/alpha/**'\n      - '.github/workflows/test-alpha-gener"
  },
  {
    "path": ".github/workflows/test-book.yml",
    "chars": 1821,
    "preview": "name: E2E Book Samples\r\n\r\non:\r\n  push:\r\n    paths:\r\n      - 'docs/book/src/getting-started/testdata/project/**'\r\n      -"
  },
  {
    "path": ".github/workflows/test-devcontainer.yml",
    "chars": 3620,
    "preview": "name: Test DevContainer Image\n\non:\n  push:\n    paths:\n      - 'testdata/**'\n      - '.github/workflows/test-devcontainer"
  },
  {
    "path": ".github/workflows/test-e2e-samples.yml",
    "chars": 4946,
    "preview": "name: E2E Testdata Sample\r\n\r\non:\r\n  push:\r\n    paths:\r\n      - 'testdata/**'\r\n      - '.github/workflows/test-e2e-sample"
  },
  {
    "path": ".github/workflows/test-helm-book.yml",
    "chars": 3621,
    "preview": "name: Helm Docs Tutorials\n\non:\n  push:\n    paths:\n      - \"docs/book/src/cronjob-tutorial/testdata/project/**\"\n      - \""
  },
  {
    "path": ".github/workflows/test-helm-samples.yml",
    "chars": 6150,
    "preview": "name: Helm Testdata Sample\n\non:\n  push:\n    paths:\n      - \"testdata/project-v4-with-plugins/**\"\n      - \".github/workfl"
  },
  {
    "path": ".github/workflows/testdata.yml",
    "chars": 904,
    "preview": "name: Testdata verification\n\non:\n  push:\n  pull_request:\n\njobs:\n\n  testdata:\n    name: Verify testdata directory\n    run"
  },
  {
    "path": ".github/workflows/verify.yml",
    "chars": 1075,
    "preview": "name: \"PR Title Verifier\"\n\non:\n  pull_request:\n    types: [opened, edited, synchronize, reopened]\n\njobs:\n  verify:\n    r"
  },
  {
    "path": ".gitignore",
    "chars": 743,
    "preview": ".idea/\n.vscode/\nWORKSPACE\n.DS_Store\n# don't check in the build output of the book\ndocs/book/book/\n\n# ignore auto-generat"
  },
  {
    "path": ".golangci.yml",
    "chars": 4072,
    "preview": "version: \"2\"\nrun:\n  allow-parallel-runners: true\nlinters:\n  default: none\n  enable:\n    - asciicheck\n    - bidichk\n    -"
  },
  {
    "path": ".yamllint",
    "chars": 1307,
    "preview": "# yamllint configuration for Kubebuilder\n# Aligns with Kubernetes YAML best practices:\n# - 2-space indentation, spaces o"
  },
  {
    "path": ".yamllint-helm",
    "chars": 237,
    "preview": "# yamllint config for Helm-rendered manifest output (stdin or temp files).\n# Extends repo .yamllint; relaxes rules that "
  },
  {
    "path": "AGENTS.md",
    "chars": 16534,
    "preview": "# Kubebuilder AI Agent Guide\n\n**Kubebuilder** is a **framework** and **command-line interface (CLI)** for building **Kub"
  },
  {
    "path": "CONTRIBUTING.md",
    "chars": 12808,
    "preview": "# Contributing guidelines\n\nThis document describes how to contribute to the project.\n\n## Sign the CLA\n\nKubernetes projec"
  },
  {
    "path": "DESIGN.md",
    "chars": 5868,
    "preview": "# Kubebuilder Design Principles\n\nThis lays out some of the guiding design principles behind the Kubebuilder\nproject and "
  },
  {
    "path": "LICENSE",
    "chars": 11356,
    "preview": "                                 Apache License\n                           Version 2.0, January 2004\n                   "
  },
  {
    "path": "Makefile",
    "chars": 10577,
    "preview": "#!/usr/bin/env bash\n\n#  Copyright 2023 The Kubernetes Authors.\n#\n#  Licensed under the Apache License, Version 2.0 (the "
  },
  {
    "path": "OWNERS",
    "chars": 228,
    "preview": "# See the OWNERS docs: https://git.k8s.io/community/contributors/guide/owners.md\n\napprovers:\n  - kubebuilder-admins\n  - "
  },
  {
    "path": "OWNERS_ALIASES",
    "chars": 849,
    "preview": "# See the OWNERS docs: https://git.k8s.io/community/contributors/guide/owners.md\n\naliases:\n  # active folks who can be c"
  },
  {
    "path": "README.md",
    "chars": 9835,
    "preview": "[![OpenSSF Scorecard](https://api.scorecard.dev/projects/github.com/kubernetes-sigs/kubebuilder/badge)](https://scorecar"
  },
  {
    "path": "RELEASE.md",
    "chars": 7287,
    "preview": "# Release Process\n\nThe Kubebuilder Project is released on an as-needed basis. The process is as follows:\n\n**Note:** Rele"
  },
  {
    "path": "SECURITY_CONTACTS",
    "chars": 607,
    "preview": "# Defined below are the security contacts for this repo.\n#\n# They are the contact point for the Product Security Team to"
  },
  {
    "path": "VERSIONING.md",
    "chars": 2435,
    "preview": "# Versioning and Releasing for Kubebuilder\n\nWe (mostly) follow the [common Kubebuilder versioning\nguidelines][guidelines"
  },
  {
    "path": "build/.goreleaser.yml",
    "chars": 2076,
    "preview": "#  Copyright 2020 The Kubernetes Authors.\n#\n#  Licensed under the Apache License, Version 2.0 (the \"License\");\n#  you ma"
  },
  {
    "path": "code-of-conduct.md",
    "chars": 147,
    "preview": "# Kubernetes Community Code of Conduct\n\nPlease refer to our [Kubernetes Community Code of Conduct](https://git.k8s.io/co"
  },
  {
    "path": "designs/README.md",
    "chars": 1430,
    "preview": "Designs\n=======\n\nThese are design documents for changes to Kubebuilder (and\ncross-repository changes for related project"
  },
  {
    "path": "designs/code-generate-image-plugin.md",
    "chars": 14404,
    "preview": "| Authors       | Creation Date | Status      | Extra |\n|---------------|---------------|-------------|---|\n| @camilamac"
  },
  {
    "path": "designs/crd_version_conversion.md",
    "chars": 10645,
    "preview": "| Authors       | Creation Date | Status      | Extra |\n|---------------|---------------|-------------|-------|\n| @droot"
  },
  {
    "path": "designs/discontinue_usage_of_kube_rbac_proxy.md",
    "chars": 24039,
    "preview": "| Authors         | Creation Date | Status        | Extra |\n|-----------------|---------------|---------------|-------|\n"
  },
  {
    "path": "designs/extensible-cli-and-scaffolding-plugins-phase-1-5.md",
    "chars": 13247,
    "preview": "| Authors       | Creation Date | Status      | Extra                                                           |\n|-----"
  },
  {
    "path": "designs/extensible-cli-and-scaffolding-plugins-phase-1.md",
    "chars": 9459,
    "preview": "\n| Authors       | Creation Date | Status      | Extra                                                           |\n|----"
  },
  {
    "path": "designs/extensible-cli-and-scaffolding-plugins-phase-2.md",
    "chars": 24265,
    "preview": "| Authors       | Creation Date | Status      | Extra                                                           |\n|-----"
  },
  {
    "path": "designs/helm-chart-autogenerate-plugin.md",
    "chars": 23724,
    "preview": "| Authors                                | Creation Date | Status       | Extra |\n|-------------------------------------"
  },
  {
    "path": "designs/helper_to_upgrade_projects_by_rescaffolding.md",
    "chars": 10900,
    "preview": "| Authors                            | Creation Date | Status      | Extra |\n|------------------------------------|-----"
  },
  {
    "path": "designs/integrating-kubebuilder-and-osdk.md",
    "chars": 3923,
    "preview": "| Authors       | Creation Date | Status      | Extra |\n|---------------|---------------|-------------|-------|\n| @joela"
  },
  {
    "path": "designs/simplified-scaffolding.md",
    "chars": 16152,
    "preview": "| Authors       | Creation Date | Status      | Extra |\n|---------------|---------------|-------------|---|\n| @DirectXMa"
  },
  {
    "path": "designs/template.md",
    "chars": 4536,
    "preview": "| Authors       | Creation Date | Status      | Extra |\n|---------------|---------------|-------------|---|\n| @name | da"
  },
  {
    "path": "designs/update_action.md",
    "chars": 22823,
    "preview": "| Authors         | Creation Date | Status      | Extra |\n|-----------------|---------------|-------------|-------|\n| @c"
  },
  {
    "path": "docs/CONTRIBUTING-ROLES.md",
    "chars": 6176,
    "preview": "Contributing Roles\n==================\n\n## Direct Code-Related Roles\n\nWhile anyone (who's signed the [CLA and follows the"
  },
  {
    "path": "docs/README.md",
    "chars": 851,
    "preview": "# Running mdBook\n\nThe kubebuilder book is served using [mdBook](https://github.com/rust-lang-nursery/mdBook). If you wan"
  },
  {
    "path": "docs/book/.firebaserc",
    "chars": 3,
    "preview": "{}\n"
  },
  {
    "path": "docs/book/book.toml",
    "chars": 587,
    "preview": "[book]\nauthors = [\"The Kubebuilder Maintainers\"]\nsrc = \"src\"\ntitle = \"The Kubebuilder Book\"\n\n[output.html]\ndefault-theme"
  },
  {
    "path": "docs/book/functions/handle-version.js",
    "chars": 1274,
    "preview": "function notFound(info) {\n    return {\n        statusCode: 404,\n        headers: {'content-type': 'text/html'},\n        "
  },
  {
    "path": "docs/book/install-and-build.sh",
    "chars": 2506,
    "preview": "#!/bin/bash\n\n#  Copyright 2020 The Kubernetes Authors.\n#\n#  Licensed under the Apache License, Version 2.0 (the \"License"
  },
  {
    "path": "docs/book/litgo.sh",
    "chars": 740,
    "preview": "#!/bin/bash\n\n#  Copyright 2020 The Kubernetes Authors.\n#\n#  Licensed under the Apache License, Version 2.0 (the \"License"
  },
  {
    "path": "docs/book/markerdocs.sh",
    "chars": 745,
    "preview": "#!/bin/bash\n\n#  Copyright 2020 The Kubernetes Authors.\n#\n#  Licensed under the Apache License, Version 2.0 (the \"License"
  },
  {
    "path": "docs/book/src/SUMMARY.md",
    "chars": 5384,
    "preview": "# Summary\n\n[Introduction](./introduction.md)\n\n[Architecture](./architecture.md)\n\n[Quick Start](./quick-start.md)\n\n[Getti"
  },
  {
    "path": "docs/book/src/TODO.md",
    "chars": 752,
    "preview": "# Page Not Found\n\nThe page you are looking for could not be found. This might be because:\n\n1. The page has been moved or"
  },
  {
    "path": "docs/book/src/architecture.md",
    "chars": 238,
    "preview": "# Architecture Concept Diagram\n\nThe following diagram will help you get a better idea over the Kubebuilder concepts and "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/api-design.md",
    "chars": 2012,
    "preview": "# Designing an API\n\nIn Kubernetes, we have a few rules for how we design APIs. Namely, all\nserialized fields *must* be `"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/basic-project.md",
    "chars": 2264,
    "preview": "# What's in a basic project?\n\nWhen scaffolding out a new project, Kubebuilder provides us with a few\nbasic pieces of boi"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/cert-manager.md",
    "chars": 1691,
    "preview": "# Deploying cert-manager\n\nWe suggest using [cert-manager](https://github.com/cert-manager/cert-manager) for\nprovisioning"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/controller-implementation.md",
    "chars": 741,
    "preview": "# Implementing a controller\n\nThe basic logic of our CronJob controller is this:\n\n1. Load the named CronJob\n\n2. List all "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/controller-overview.md",
    "chars": 978,
    "preview": "# What's in a controller?\n\nControllers are the core of Kubernetes, and of any operator.\n\nIt's a controller's job to ensu"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/cronjob-tutorial.md",
    "chars": 2993,
    "preview": "# Tutorial: Building CronJob\n\nToo many tutorials start out with some really contrived setup, or some toy\napplication tha"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/empty-main.md",
    "chars": 164,
    "preview": "# Every journey needs a start, every program needs a main\n\n{{#literatego ./testdata/emptymain.go}}\n\nWith that out of the"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/gvks.md",
    "chars": 4725,
    "preview": "# Groups and Versions and Kinds, oh my!\n\nBefore we get started with our API, we should talk about terminology\na bit.\n\nWh"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/main-revisited.md",
    "chars": 291,
    "preview": "# You said something about main?\n\nBut first, remember how we said we'd [come back to `main.go`\nagain](/cronjob-tutorial/"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/new-api.md",
    "chars": 1124,
    "preview": "# Adding a new API\n\nTo scaffold out a new Kind (you were paying attention to the [last\nchapter](./gvks.md#kinds-and-reso"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/other-api-files.md",
    "chars": 1104,
    "preview": "# A Brief Aside: What's the rest of this stuff?\n\nIf you've taken a peek at the rest of the files in the\n[`api/v1/`](http"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/running-webhook.md",
    "chars": 3180,
    "preview": "# Deploying Admission Webhooks\n\n## cert-manager\n\nYou need to follow [this](./cert-manager.md) to install the cert-manage"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/running.md",
    "chars": 3795,
    "preview": "# Running and deploying the controller\n\n### Optional\nIf opting to make any changes to the API definitions, then before p"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/emptyapi.go",
    "chars": 3812,
    "preview": "/*\nCopyright 2022.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/emptycontroller.go",
    "chars": 3884,
    "preview": "/*\nCopyright 2022.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/emptymain.go",
    "chars": 6472,
    "preview": "/*\nCopyright 2022 The Kubernetes authors.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not u"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/finalizer_example.go",
    "chars": 3741,
    "preview": "/*\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/.custom-gcl.yml",
    "chars": 470,
    "preview": "# This file configures golangci-lint with module plugins.\n# When you run 'make lint', it will automatically build a cust"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/.devcontainer/devcontainer.json",
    "chars": 784,
    "preview": "{\n  \"name\": \"Kubebuilder DevContainer\",\n  \"image\": \"golang:1.25\",\n  \"features\": {\n    \"ghcr.io/devcontainers/features/do"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/.devcontainer/post-install.sh",
    "chars": 4370,
    "preview": "#!/bin/bash\nset -euo pipefail\n\necho \"====================================\"\necho \"Kubebuilder DevContainer Setup\"\necho \"="
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/.dockerignore",
    "chars": 266,
    "preview": "# More info: https://docs.docker.com/engine/reference/builder/#dockerignore-file\n# Ignore everything by default and re-i"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/.github/workflows/lint.yml",
    "chars": 406,
    "preview": "name: Lint\n\non:\n  push:\n  pull_request:\n\njobs:\n  lint:\n    name: Run on Ubuntu\n    runs-on: ubuntu-latest\n    steps:\n   "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/.github/workflows/test-chart.yml",
    "chars": 1851,
    "preview": "name: Test Chart\n\non:\n  push:\n  pull_request:\n\njobs:\n  test-e2e:\n    name: Run on Ubuntu\n    runs-on: ubuntu-latest\n    "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/.github/workflows/test-e2e.yml",
    "chars": 679,
    "preview": "name: E2E Tests\n\non:\n  push:\n  pull_request:\n\njobs:\n  test-e2e:\n    name: Run on Ubuntu\n    runs-on: ubuntu-latest\n    s"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/.github/workflows/test.yml",
    "chars": 373,
    "preview": "name: Tests\n\non:\n  push:\n  pull_request:\n\njobs:\n  test:\n    name: Run on Ubuntu\n    runs-on: ubuntu-latest\n    steps:\n  "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/.gitignore",
    "chars": 460,
    "preview": "# Binaries for programs and plugins\n*.exe\n*.exe~\n*.dll\n*.so\n*.dylib\nbin/*\nDockerfile.cross\n\n# Test binary, built with `g"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/.golangci.yml",
    "chars": 1038,
    "preview": "version: \"2\"\nrun:\n  allow-parallel-runners: true\nlinters:\n  default: none\n  enable:\n    - copyloopvar\n    - dupl\n    - e"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/AGENTS.md",
    "chars": 12399,
    "preview": "# project - AI Agent Guide\n\n## Project Structure\n\n**Single-group layout (default):**\n```\ncmd/main.go                    "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/Dockerfile",
    "chars": 1232,
    "preview": "# Build the manager binary\nFROM golang:1.25 AS builder\nARG TARGETOS\nARG TARGETARCH\n\nWORKDIR /workspace\n# Copy the Go Mod"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/Makefile",
    "chars": 13260,
    "preview": "# Image URL to use all building/pushing image targets\nIMG ?= controller:latest\n\n# Get the currently used golang install "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/PROJECT",
    "chars": 743,
    "preview": "# Code generated by tool. DO NOT EDIT.\n# This file is used to track the info used to scaffold your project\n# and allow t"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/README.md",
    "chars": 3780,
    "preview": "# project\n// TODO(user): Add simple overview of use/purpose\n\n## Description\n// TODO(user): An in-depth paragraph about y"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/api/v1/cronjob_types.go",
    "chars": 7873,
    "preview": "/*\nCopyright 2026 The Kubernetes authors.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not u"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/api/v1/groupversion_info.go",
    "chars": 2172,
    "preview": "/*\nCopyright 2026 The Kubernetes authors.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not u"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/api/v1/zz_generated.deepcopy.go",
    "chars": 4368,
    "preview": "//go:build !ignore_autogenerated\n\n/*\nCopyright 2026 The Kubernetes authors.\n\nLicensed under the Apache License, Version "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/cmd/main.go",
    "chars": 9659,
    "preview": "/*\nCopyright 2026 The Kubernetes authors.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not u"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/certmanager/certificate-metrics.yaml",
    "chars": 745,
    "preview": "# The following manifests contain a self-signed issuer CR and a metrics certificate CR.\n# More document can be found at "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/certmanager/certificate-webhook.yaml",
    "chars": 736,
    "preview": "# The following manifests contain a self-signed issuer CR and a certificate CR.\n# More document can be found at https://"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/certmanager/issuer.yaml",
    "chars": 454,
    "preview": "# The following manifest contains a self-signed issuer CR.\n# More information can be found at https://docs.cert-manager."
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/certmanager/kustomization.yaml",
    "chars": 119,
    "preview": "resources:\n- issuer.yaml\n- certificate-webhook.yaml\n- certificate-metrics.yaml\n\nconfigurations:\n- kustomizeconfig.yaml\n"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/certmanager/kustomizeconfig.yaml",
    "chars": 231,
    "preview": "# This configuration is for teaching kustomize how to update name ref substitution\nnameReference:\n- kind: Issuer\n  group"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/crd/bases/batch.tutorial.kubebuilder.io_cronjobs.yaml",
    "chars": 227876,
    "preview": "---\napiVersion: apiextensions.k8s.io/v1\nkind: CustomResourceDefinition\nmetadata:\n  annotations:\n    controller-gen.kubeb"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/crd/kustomization.yaml",
    "chars": 693,
    "preview": "# This kustomization.yaml is not intended to be run by itself,\n# since it depends on service name and namespace that are"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/crd/kustomizeconfig.yaml",
    "chars": 338,
    "preview": "# This file is for teaching kustomize how to substitute name and namespace reference in CRD\nnameReference:\n- kind: Servi"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/default/cert_metrics_manager_patch.yaml",
    "chars": 870,
    "preview": "# This patch adds the args, volumes, and ports to allow the manager to use the metrics-server certs.\n\n# Add the volumeMo"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/default/kustomization.yaml",
    "chars": 7572,
    "preview": "# Adds namespace to all resources.\nnamespace: project-system\n\n# Value of this field is prepended to the\n# names of all r"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/default/manager_metrics_patch.yaml",
    "chars": 174,
    "preview": "# This patch adds the args to allow exposing the metrics endpoint using HTTPS\n- op: add\n  path: /spec/template/spec/cont"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/default/manager_webhook_patch.yaml",
    "chars": 992,
    "preview": "# This patch ensures the webhook certificates are properly mounted in the manager container.\n# It configures the necessa"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/default/metrics_service.yaml",
    "chars": 401,
    "preview": "apiVersion: v1\nkind: Service\nmetadata:\n  labels:\n    control-plane: controller-manager\n    app.kubernetes.io/name: proje"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/manager/kustomization.yaml",
    "chars": 156,
    "preview": "resources:\n- manager.yaml\napiVersion: kustomize.config.k8s.io/v1beta1\nkind: Kustomization\nimages:\n- name: controller\n  n"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/manager/manager.yaml",
    "chars": 3168,
    "preview": "apiVersion: v1\nkind: Namespace\nmetadata:\n  labels:\n    control-plane: controller-manager\n    app.kubernetes.io/name: pro"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/network-policy/allow-metrics-traffic.yaml",
    "chars": 827,
    "preview": "# This NetworkPolicy allows ingress traffic\n# with Pods running on namespaces labeled with 'metrics: enabled'. Only Pods"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/network-policy/allow-webhook-traffic.yaml",
    "chars": 879,
    "preview": "# This NetworkPolicy allows ingress traffic to your webhook server running\n# as part of the controller-manager from spec"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/network-policy/kustomization.yaml",
    "chars": 69,
    "preview": "resources:\n- allow-webhook-traffic.yaml\n- allow-metrics-traffic.yaml\n"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/prometheus/kustomization.yaml",
    "chars": 465,
    "preview": "resources:\n- monitor.yaml\n\n# [PROMETHEUS-WITH-CERTS] The following patch configures the ServiceMonitor in ../prometheus\n"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/prometheus/monitor.yaml",
    "chars": 1226,
    "preview": "# Prometheus Monitor Service (Metrics)\napiVersion: monitoring.coreos.com/v1\nkind: ServiceMonitor\nmetadata:\n  labels:\n   "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/prometheus/monitor_tls_patch.yaml",
    "chars": 553,
    "preview": "# Patch for Prometheus ServiceMonitor to enable secure TLS configuration\n# using certificates managed by cert-manager\n- "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/rbac/cronjob_admin_role.yaml",
    "chars": 767,
    "preview": "# This rule is not used by the project project itself.\n# It is provided to allow the cluster admin to help manage permis"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/rbac/cronjob_editor_role.yaml",
    "chars": 819,
    "preview": "# This rule is not used by the project project itself.\n# It is provided to allow the cluster admin to help manage permis"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/rbac/cronjob_viewer_role.yaml",
    "chars": 787,
    "preview": "# This rule is not used by the project project itself.\n# It is provided to allow the cluster admin to help manage permis"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/rbac/kustomization.yaml",
    "chars": 1207,
    "preview": "resources:\n# All RBAC will be applied under this service account in\n# the deployment namespace. You may comment out this"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/rbac/leader_election_role.yaml",
    "chars": 566,
    "preview": "# permissions to do leader election.\napiVersion: rbac.authorization.k8s.io/v1\nkind: Role\nmetadata:\n  labels:\n    app.kub"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/rbac/leader_election_role_binding.yaml",
    "chars": 364,
    "preview": "apiVersion: rbac.authorization.k8s.io/v1\nkind: RoleBinding\nmetadata:\n  labels:\n    app.kubernetes.io/name: project\n    a"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/rbac/metrics_auth_role.yaml",
    "chars": 287,
    "preview": "apiVersion: rbac.authorization.k8s.io/v1\nkind: ClusterRole\nmetadata:\n  name: metrics-auth-role\nrules:\n- apiGroups:\n  - a"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/rbac/metrics_auth_role_binding.yaml",
    "chars": 282,
    "preview": "apiVersion: rbac.authorization.k8s.io/v1\nkind: ClusterRoleBinding\nmetadata:\n  name: metrics-auth-rolebinding\nroleRef:\n  "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/rbac/metrics_reader_role.yaml",
    "chars": 150,
    "preview": "apiVersion: rbac.authorization.k8s.io/v1\nkind: ClusterRole\nmetadata:\n  name: metrics-reader\nrules:\n- nonResourceURLs:\n  "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/rbac/role.yaml",
    "chars": 668,
    "preview": "---\napiVersion: rbac.authorization.k8s.io/v1\nkind: ClusterRole\nmetadata:\n  name: manager-role\nrules:\n- apiGroups:\n  - ba"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/rbac/role_binding.yaml",
    "chars": 362,
    "preview": "apiVersion: rbac.authorization.k8s.io/v1\nkind: ClusterRoleBinding\nmetadata:\n  labels:\n    app.kubernetes.io/name: projec"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/rbac/service_account.yaml",
    "chars": 183,
    "preview": "apiVersion: v1\nkind: ServiceAccount\nmetadata:\n  labels:\n    app.kubernetes.io/name: project\n    app.kubernetes.io/manage"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/samples/batch_v1_cronjob.yaml",
    "chars": 942,
    "preview": "apiVersion: batch.tutorial.kubebuilder.io/v1\nkind: CronJob\nmetadata:\n  labels:\n    app.kubernetes.io/name: project\n    a"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/samples/kustomization.yaml",
    "chars": 122,
    "preview": "## Append samples of your project ##\nresources:\n- batch_v1_cronjob.yaml\n# +kubebuilder:scaffold:manifestskustomizesample"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/webhook/kustomization.yaml",
    "chars": 43,
    "preview": "resources:\n- manifests.yaml\n- service.yaml\n"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/webhook/manifests.yaml",
    "chars": 1094,
    "preview": "---\napiVersion: admissionregistration.k8s.io/v1\nkind: MutatingWebhookConfiguration\nmetadata:\n  name: mutating-webhook-co"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/config/webhook/service.yaml",
    "chars": 333,
    "preview": "apiVersion: v1\nkind: Service\nmetadata:\n  labels:\n    app.kubernetes.io/name: project\n    app.kubernetes.io/managed-by: k"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/.helmignore",
    "chars": 307,
    "preview": "# Patterns to ignore when building Helm packages.\n# Operating system files\n.DS_Store\n\n# Version control directories\n.git"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/Chart.yaml",
    "chars": 227,
    "preview": "apiVersion: v2\nname: project\ndescription: A Helm chart to distribute project\ntype: application\n\nversion: 0.1.0\nappVersio"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/NOTES.txt",
    "chars": 458,
    "preview": "Thank you for installing {{ .Chart.Name }}.\n\nYour release is named {{ .Release.Name }}.\n\nThe controller and CRDs have be"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/_helpers.tpl",
    "chars": 1674,
    "preview": "{{/*\nExpand the name of the chart.\n*/}}\n{{- define \"project.name\" -}}\n{{- default .Chart.Name .Values.nameOverride | tru"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/cert-manager/metrics-certs.yaml",
    "chars": 976,
    "preview": "{{- if and .Values.certManager.enable .Values.metrics.enable }}\napiVersion: cert-manager.io/v1\nkind: Certificate\nmetadat"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/cert-manager/selfsigned-issuer.yaml",
    "chars": 510,
    "preview": "{{- if .Values.certManager.enable }}\napiVersion: cert-manager.io/v1\nkind: Issuer\nmetadata:\n  labels:\n    app.kubernetes."
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/cert-manager/serving-cert.yaml",
    "chars": 910,
    "preview": "{{- if .Values.certManager.enable }}\napiVersion: cert-manager.io/v1\nkind: Certificate\nmetadata:\n  labels:\n    app.kubern"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/crd/cronjobs.batch.tutorial.kubebuilder.io.yaml",
    "chars": 227994,
    "preview": "{{- if .Values.crd.enable }}\napiVersion: apiextensions.k8s.io/v1\nkind: CustomResourceDefinition\nmetadata:\n  annotations:"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/manager/manager.yaml",
    "chars": 4409,
    "preview": "apiVersion: apps/v1\nkind: Deployment\nmetadata:\n  labels:\n    app.kubernetes.io/managed-by: {{ .Release.Service }}\n    ap"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/metrics/controller-manager-metrics-service.yaml",
    "chars": 761,
    "preview": "{{- if .Values.metrics.enable }}\napiVersion: v1\nkind: Service\nmetadata:\n  labels:\n    app.kubernetes.io/managed-by: {{ ."
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/prometheus/controller-manager-metrics-monitor.yaml",
    "chars": 1269,
    "preview": "{{- if .Values.prometheus.enable }}\napiVersion: monitoring.coreos.com/v1\nkind: ServiceMonitor\nmetadata:\n  labels:\n    ap"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/rbac/controller-manager.yaml",
    "chars": 432,
    "preview": "apiVersion: v1\nkind: ServiceAccount\nmetadata:\n  labels:\n    app.kubernetes.io/managed-by: {{ .Release.Service }}\n    app"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/rbac/cronjob-admin-role.yaml",
    "chars": 659,
    "preview": "{{- if .Values.rbacHelpers.enable }}\napiVersion: rbac.authorization.k8s.io/v1\nkind: ClusterRole\nmetadata:\n  labels:\n    "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/rbac/cronjob-editor-role.yaml",
    "chars": 722,
    "preview": "{{- if .Values.rbacHelpers.enable }}\napiVersion: rbac.authorization.k8s.io/v1\nkind: ClusterRole\nmetadata:\n  labels:\n    "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/rbac/cronjob-viewer-role.yaml",
    "chars": 679,
    "preview": "{{- if .Values.rbacHelpers.enable }}\napiVersion: rbac.authorization.k8s.io/v1\nkind: ClusterRole\nmetadata:\n  labels:\n    "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/rbac/leader-election-role.yaml",
    "chars": 798,
    "preview": "apiVersion: rbac.authorization.k8s.io/v1\nkind: Role\nmetadata:\n  labels:\n    app.kubernetes.io/managed-by: {{ .Release.Se"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/rbac/leader-election-rolebinding.yaml",
    "chars": 785,
    "preview": "apiVersion: rbac.authorization.k8s.io/v1\nkind: RoleBinding\nmetadata:\n  labels:\n    app.kubernetes.io/managed-by: {{ .Rel"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/rbac/manager-role.yaml",
    "chars": 731,
    "preview": "apiVersion: rbac.authorization.k8s.io/v1\nkind: ClusterRole\nmetadata:\n  name: {{ include \"project.resourceName\" (dict \"su"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/rbac/manager-rolebinding.yaml",
    "chars": 745,
    "preview": "apiVersion: rbac.authorization.k8s.io/v1\nkind: ClusterRoleBinding\nmetadata:\n  labels:\n    app.kubernetes.io/managed-by: "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/rbac/metrics-auth-role.yaml",
    "chars": 398,
    "preview": "{{- if .Values.metrics.enable }}\napiVersion: rbac.authorization.k8s.io/v1\nkind: ClusterRole\nmetadata:\n  name: {{ include"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/rbac/metrics-auth-rolebinding.yaml",
    "chars": 545,
    "preview": "{{- if .Values.metrics.enable }}\napiVersion: rbac.authorization.k8s.io/v1\nkind: ClusterRoleBinding\nmetadata:\n  name: {{ "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/rbac/metrics-reader.yaml",
    "chars": 259,
    "preview": "{{- if .Values.metrics.enable }}\napiVersion: rbac.authorization.k8s.io/v1\nkind: ClusterRole\nmetadata:\n  name: {{ include"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/webhook/mutating-webhook-configuration.yaml",
    "chars": 948,
    "preview": "{{- if .Values.webhook.enable }}\napiVersion: admissionregistration.k8s.io/v1\nkind: MutatingWebhookConfiguration\nmetadata"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/webhook/validating-webhook-configuration.yaml",
    "chars": 954,
    "preview": "{{- if .Values.webhook.enable }}\napiVersion: admissionregistration.k8s.io/v1\nkind: ValidatingWebhookConfiguration\nmetada"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/templates/webhook/webhook-service.yaml",
    "chars": 665,
    "preview": "{{- if .Values.webhook.enable }}\napiVersion: v1\nkind: Service\nmetadata:\n  labels:\n    app.kubernetes.io/managed-by: {{ ."
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/chart/values.yaml",
    "chars": 2081,
    "preview": "## String to partially override chart.fullname template (will maintain the release name)\n##\n# nameOverride: \"\"\n\n## Strin"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/dist/install.yaml",
    "chars": 239004,
    "preview": "apiVersion: v1\nkind: Namespace\nmetadata:\n  labels:\n    app.kubernetes.io/managed-by: kustomize\n    app.kubernetes.io/nam"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/go.mod",
    "chars": 4663,
    "preview": "module tutorial.kubebuilder.io/project\n\ngo 1.25.3\n\nrequire (\n\tgithub.com/onsi/ginkgo/v2 v2.27.2\n\tgithub.com/onsi/gomega "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/go.sum",
    "chars": 22873,
    "preview": "cel.dev/expr v0.24.0 h1:56OvJKSH3hDGL0ml5uSxZmz3/3Pq4tJ+fb1unVLAFcY=\ncel.dev/expr v0.24.0/go.mod h1:hLPLo1W4QUmuYdA72RBX"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/hack/boilerplate.go.txt",
    "chars": 569,
    "preview": "/*\nCopyright 2026 The Kubernetes authors.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not u"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/internal/controller/cronjob_controller.go",
    "chars": 28719,
    "preview": "/*\nCopyright 2026 The Kubernetes authors.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not u"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/internal/controller/cronjob_controller_test.go",
    "chars": 9256,
    "preview": "/*\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/internal/controller/suite_test.go",
    "chars": 7218,
    "preview": "/*\nCopyright 2026 The Kubernetes authors.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not u"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/internal/webhook/v1/cronjob_webhook.go",
    "chars": 9831,
    "preview": "/*\nCopyright 2026 The Kubernetes authors.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not u"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/internal/webhook/v1/cronjob_webhook_test.go",
    "chars": 6594,
    "preview": "/*\nCopyright 2026 The Kubernetes authors.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not u"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/internal/webhook/v1/webhook_suite_test.go",
    "chars": 4928,
    "preview": "/*\nCopyright 2026 The Kubernetes authors.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not u"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/test/e2e/e2e_suite_test.go",
    "chars": 4000,
    "preview": "//go:build e2e\n// +build e2e\n\n/*\nCopyright 2026 The Kubernetes authors.\n\nLicensed under the Apache License, Version 2.0 "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/test/e2e/e2e_test.go",
    "chars": 16171,
    "preview": "//go:build e2e\n// +build e2e\n\n/*\nCopyright 2026 The Kubernetes authors.\n\nLicensed under the Apache License, Version 2.0 "
  },
  {
    "path": "docs/book/src/cronjob-tutorial/testdata/project/test/utils/utils.go",
    "chars": 7808,
    "preview": "/*\nCopyright 2026 The Kubernetes authors.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not u"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/webhook-implementation.md",
    "chars": 2274,
    "preview": "# Implementing defaulting/validating webhooks\n\nIf you want to implement [admission webhooks](../reference/admission-webh"
  },
  {
    "path": "docs/book/src/cronjob-tutorial/writing-tests.md",
    "chars": 2540,
    "preview": "# Writing controller tests\n\nTesting Kubernetes controllers is a big subject, and the boilerplate testing\nfiles generated"
  },
  {
    "path": "docs/book/src/faq.md",
    "chars": 9015,
    "preview": "\n# FAQ\n\n<aside class=\"note\">\n<h1> Controller-Runtime FAQ </h1>\n\nKubebuilder is developed on top of the [controller-runti"
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/.custom-gcl.yml",
    "chars": 470,
    "preview": "# This file configures golangci-lint with module plugins.\n# When you run 'make lint', it will automatically build a cust"
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/.devcontainer/devcontainer.json",
    "chars": 784,
    "preview": "{\n  \"name\": \"Kubebuilder DevContainer\",\n  \"image\": \"golang:1.25\",\n  \"features\": {\n    \"ghcr.io/devcontainers/features/do"
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/.devcontainer/post-install.sh",
    "chars": 4370,
    "preview": "#!/bin/bash\nset -euo pipefail\n\necho \"====================================\"\necho \"Kubebuilder DevContainer Setup\"\necho \"="
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/.dockerignore",
    "chars": 266,
    "preview": "# More info: https://docs.docker.com/engine/reference/builder/#dockerignore-file\n# Ignore everything by default and re-i"
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/.github/workflows/auto_update.yml",
    "chars": 2754,
    "preview": "name: Auto Update\n\n# The 'kubebuilder alpha update' command requires write access to the repository to create a branch\n#"
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/.github/workflows/lint.yml",
    "chars": 406,
    "preview": "name: Lint\n\non:\n  push:\n  pull_request:\n\njobs:\n  lint:\n    name: Run on Ubuntu\n    runs-on: ubuntu-latest\n    steps:\n   "
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/.github/workflows/test-chart.yml",
    "chars": 1905,
    "preview": "name: Test Chart\n\non:\n  push:\n  pull_request:\n\njobs:\n  test-e2e:\n    name: Run on Ubuntu\n    runs-on: ubuntu-latest\n    "
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/.github/workflows/test-e2e.yml",
    "chars": 679,
    "preview": "name: E2E Tests\n\non:\n  push:\n  pull_request:\n\njobs:\n  test-e2e:\n    name: Run on Ubuntu\n    runs-on: ubuntu-latest\n    s"
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/.github/workflows/test.yml",
    "chars": 373,
    "preview": "name: Tests\n\non:\n  push:\n  pull_request:\n\njobs:\n  test:\n    name: Run on Ubuntu\n    runs-on: ubuntu-latest\n    steps:\n  "
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/.gitignore",
    "chars": 460,
    "preview": "# Binaries for programs and plugins\n*.exe\n*.exe~\n*.dll\n*.so\n*.dylib\nbin/*\nDockerfile.cross\n\n# Test binary, built with `g"
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/.golangci.yml",
    "chars": 1038,
    "preview": "version: \"2\"\nrun:\n  allow-parallel-runners: true\nlinters:\n  default: none\n  enable:\n    - copyloopvar\n    - dupl\n    - e"
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/AGENTS.md",
    "chars": 12399,
    "preview": "# project - AI Agent Guide\n\n## Project Structure\n\n**Single-group layout (default):**\n```\ncmd/main.go                    "
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/Dockerfile",
    "chars": 1232,
    "preview": "# Build the manager binary\nFROM golang:1.25 AS builder\nARG TARGETOS\nARG TARGETARCH\n\nWORKDIR /workspace\n# Copy the Go Mod"
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/Makefile",
    "chars": 12784,
    "preview": "# Image URL to use all building/pushing image targets\nIMG ?= controller:latest\n\n# Get the currently used golang install "
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/PROJECT",
    "chars": 677,
    "preview": "# Code generated by tool. DO NOT EDIT.\n# This file is used to track the info used to scaffold your project\n# and allow t"
  },
  {
    "path": "docs/book/src/getting-started/testdata/project/README.md",
    "chars": 3780,
    "preview": "# project\n// TODO(user): Add simple overview of use/purpose\n\n## Description\n// TODO(user): An in-depth paragraph about y"
  }
]

// ... and 1114 more files (download for full content)

About this extraction

This page contains the full source code of the kubernetes-sigs/kubebuilder GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 1314 files (7.0 MB), approximately 1.9M tokens, and a symbol index with 2817 extracted functions, classes, methods, constants, and types. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.

Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.

Copied to clipboard!