hashicorp / terraform-k8s

Terraform Cloud Operator for Kubernetes
https://learn.hashicorp.com/tutorials/terraform/kubernetes-operator?in=terraform/kubernetes
Mozilla Public License 2.0
455 stars 71 forks source link

Adding support for output annotations #134

Open jtyr opened 2 years ago

jtyr commented 2 years ago

Community Note


This PR is adding the ability to define Annotations on the output Secret generated by the operator. This allows to consume the secret by other tools like kubernetes-reflector. This PR needs to be rebased once the PR #129 is merged to remove most of the changes in the CRD.

The Workspace can contain spec.outputAnnotations:

...
spec:
  outputAnnotations:
    foo: bar
...

Such Annotations are then inserted into the final output Secret:

$ kubectl get secret test-outputs
...
metadata:
  annotations:
    foo: bar
...

Release note for CHANGELOG:

Added ability to specify annotations for the output secret
jtyr commented 2 years ago

This PR is rebased now.