From ac0ac7fd54a69c5495c4a725d0a523747d64e962 Mon Sep 17 00:00:00 2001 From: derailed Date: Mon, 12 Aug 2019 14:01:56 -0600 Subject: [PATCH] update release notes --- Dockerfile | 2 +- change_logs/release_v0.4.3.md | 26 ++++++++++++++++++++++++++ internal/sanitize/sa.go | 6 +++++- 3 files changed, 32 insertions(+), 2 deletions(-) create mode 100644 change_logs/release_v0.4.3.md diff --git a/Dockerfile b/Dockerfile index d6936230..de7cf977 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,7 +2,7 @@ # Build... FROM golang:1.12.3-alpine AS build -ENV VERSION=v0.4.2 GO111MODULE=on PACKAGE=github.com/derailed/popeye +ENV VERSION=v0.4.3 GO111MODULE=on PACKAGE=github.com/derailed/popeye WORKDIR /go/src/$PACKAGE diff --git a/change_logs/release_v0.4.3.md b/change_logs/release_v0.4.3.md new file mode 100644 index 00000000..64f5eb16 --- /dev/null +++ b/change_logs/release_v0.4.3.md @@ -0,0 +1,26 @@ + + +# Release v0.4.3 + +## Notes + +Thank you so much for your support and suggestions to make Popeye better!! + +If you dig this tool, please make some noise on social! [@kitesurfer](https://twitter.com/kitesurfer) + +--- + +## Change Logs + +Maintenance release bugs and cleanup. + +--- + +## Resolved Bugs + +* Wrong Popeye version in Docker builds [Issue #48](https://github.com/derailed/popeye/issues/48) +* Incorrect ServiceAccount reporting [Issue #49](https://github.com/derailed/popeye/issues/49) + +--- + +  © 2019 Imhotep Software LLC. All materials licensed under [Apache v2.0](http://www.apache.org/licenses/LICENSE-2.0) diff --git a/internal/sanitize/sa.go b/internal/sanitize/sa.go index 84a9d0bc..6b77314a 100644 --- a/internal/sanitize/sa.go +++ b/internal/sanitize/sa.go @@ -84,8 +84,12 @@ func (s *ServiceAccount) Sanitize(ctx context.Context) error { } func (s *ServiceAccount) checkSecretRefs(fqn string, refs []v1.ObjectReference) { + ns, _ := namespaced(fqn) for _, ref := range refs { - sfqn := cache.FQN(ref.Namespace, ref.Name) + if ref.Namespace != "" { + ns = ref.Namespace + } + sfqn := cache.FQN(ns, ref.Name) if _, ok := s.ListSecrets()[sfqn]; !ok { s.AddCode(304, fqn, sfqn) }