Skip to content

Commit 49820c7

Browse files
authored
Revert "Add optional annotations (#66)"
This reverts commit e71c0d1.
1 parent e71c0d1 commit 49820c7

File tree

2 files changed

+3
-9
lines changed

2 files changed

+3
-9
lines changed

pkg/apis/db/v1alpha1/postgresuser_types.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,6 @@ type PostgresUserSpec struct {
1515
SecretName string `json:"secretName"`
1616
// +optional
1717
Privileges string `json:"privileges"`
18-
// +optional
19-
Annotations map[string]string `json:"annotations,omitempty"`
2018
}
2119

2220
// PostgresUserStatus defines the observed state of PostgresUser

pkg/controller/postgresuser/postgresuser_controller.go

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import (
44
"context"
55
goerr "errors"
66
"fmt"
7-
87
"github.com/movetokube/postgres-operator/pkg/config"
98

109
"github.com/go-logr/logr"
@@ -268,14 +267,11 @@ func (r *ReconcilePostgresUser) newSecretForCR(cr *dbv1alpha1.PostgresUser, role
268267
labels := map[string]string{
269268
"app": cr.Name,
270269
}
271-
annotations := cr.Spec.Annotations
272-
273270
return &corev1.Secret{
274271
ObjectMeta: metav1.ObjectMeta{
275-
Name: fmt.Sprintf("%s-%s", cr.Spec.SecretName, cr.Name),
276-
Namespace: cr.Namespace,
277-
Labels: labels,
278-
Annotations: annotations,
272+
Name: fmt.Sprintf("%s-%s", cr.Spec.SecretName, cr.Name),
273+
Namespace: cr.Namespace,
274+
Labels: labels,
279275
},
280276
Data: map[string][]byte{
281277
"POSTGRES_URL": []byte(pgUserUrl),

0 commit comments

Comments
 (0)