Skip to content

Commit 8e75629

Browse files
committed
Ignore k8s secret not found when ESS enabled
Signed-off-by: ezgidemirel <[email protected]>
1 parent 8e87b2c commit 8e75629

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pkg/connection/store/kubernetes/store.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ func buildClient(ctx context.Context, local client.Client, cfg v1.SecretStoreCon
9393
// ReadKeyValues reads and returns key value pairs for a given Kubernetes Secret.
9494
func (ss *SecretStore) ReadKeyValues(ctx context.Context, n store.ScopedName, s *store.Secret) error {
9595
ks := &corev1.Secret{}
96-
if err := ss.client.Get(ctx, types.NamespacedName{Name: n.Name, Namespace: ss.namespaceForSecret(n)}, ks); err != nil {
96+
if err := ss.client.Get(ctx, types.NamespacedName{Name: n.Name, Namespace: ss.namespaceForSecret(n)}, ks); resource.IgnoreNotFound(err) != nil {
9797
return errors.Wrap(err, errGetSecret)
9898
}
9999
s.Data = ks.Data

0 commit comments

Comments
 (0)