Skip to content

Commit

Permalink
Merge pull request #67 from sanecz/main
Browse files Browse the repository at this point in the history
fix: ignore .key_cache and .___atomic_write* files on minions pki dir
  • Loading branch information
kpetremann authored Jul 1, 2024
2 parents 4b2d643 + 3c812bb commit 3e614d1
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pkg/listener/pkiwatcher.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import (
"context"
"os"
"path"
"strings"
"sync"
"time"

Expand Down Expand Up @@ -96,6 +97,9 @@ func (w *PKIWatcher) StartWatching() {
return
case evt := <-w.watcher.Events:
minionName := path.Base(evt.Name)
if minionName == ".key_cache" || strings.HasPrefix(minionName, ".___atomic_write") {
continue
}
if evt.Op == fsnotify.Create {
w.eventChan <- event.WatchEvent{
MinionName: minionName,
Expand Down

0 comments on commit 3e614d1

Please sign in to comment.