Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FileWatcher ¶
type FileWatcher struct {
// contains filtered or unexported fields
}
FileWatcher watches files for changes. When the file changes, it runs the specified handler function.
func New ¶
func New(fp string, callback Handler) (*FileWatcher, error)
New returns a new FileWatcher watching the given file path.
func (*FileWatcher) Start ¶
func (cw *FileWatcher) Start(ctx context.Context) error
Start starts the watch on the certificate and key files.
func (*FileWatcher) Watch ¶
func (cw *FileWatcher) Watch()
Watch reads events from the watcher's channel and reacts to changes.
Click to show internal directories.
Click to hide internal directories.