woodpecker/pipeline/backend/kubernetes
Andrew Melnick b52b021acb
Implement registries for Kubernetes backend (#4092)
According to [the documentation](https://woodpecker-ci.org/docs/administration/backends/kubernetes#images-from-private-registries), per-organization and per-pipeline registries are currently unsupported for the Kubernetes backend.

This patch implements this missing functionality by creating and deleting a matching secret for each pod with a matched registry, using the same name, labels, and annotations as the pod, and appending it to its `imagePullSecrets` list.

This patch adds tests for the new functionality, and has been manually end-to-end-tested in KinD by using a private image hosted in the matching gitea instance.

This will require updating the matching helm charts to add the create/delete permissions to the agent role, which **is already done**.

close  #2987
2024-09-30 01:03:05 +01:00
..
backend_options.go K8s secrets reference from step (#3655) 2024-06-23 18:20:21 +02:00
backend_options_test.go K8s secrets reference from step (#3655) 2024-06-23 18:20:21 +02:00
flags.go Removed Kubernetes default image pull secret name (#4005) 2024-08-06 18:47:31 +02:00
kubernetes.go Implement registries for Kubernetes backend (#4092) 2024-09-30 01:03:05 +01:00
kubernetes_test.go Secured kubernetes backend configuration (#3204) 2024-01-15 03:59:08 +01:00
pod.go Implement registries for Kubernetes backend (#4092) 2024-09-30 01:03:05 +01:00
pod_test.go Implement registries for Kubernetes backend (#4092) 2024-09-30 01:03:05 +01:00
secrets.go Implement registries for Kubernetes backend (#4092) 2024-09-30 01:03:05 +01:00
secrets_test.go Implement registries for Kubernetes backend (#4092) 2024-09-30 01:03:05 +01:00
service.go cspell lint go code (#3706) 2024-05-24 22:35:04 +02:00
service_test.go fix: can't run multiple services on k8s (#3395) 2024-02-17 12:30:06 +01:00
utils.go Fail on InvalidImageName (#4007) 2024-08-06 17:07:07 +02:00
utils_test.go Sanitize pod's step label (#3275) 2024-01-26 13:42:21 +01:00
volume.go cspell lint go code (#3706) 2024-05-24 22:35:04 +02:00
volume_test.go Secured kubernetes backend configuration (#3204) 2024-01-15 03:59:08 +01:00