file

package
v1.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 16, 2026 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// AuthDirectory default directory used to store files
	// to authenticate request
	AuthDirectory = "/etc/ingress-controller/auth"

	// DefaultSSLDirectory defines the location where the SSL certificates will be generated
	// This directory contains all the SSL certificates that are specified in Ingress rules.
	// The name of each file is <namespace>-<secret name>.pem. The content is the concatenated
	// certificate and key.
	DefaultSSLDirectory = "/etc/ingress-controller/ssl"
)
View Source
const ReadWriteByUser = 0o700

ReadWriteByUser defines linux permission to read and write files for the owner user

Variables

This section is empty.

Functions

func CreateRequiredDirectories

func CreateRequiredDirectories() error

CreateRequiredDirectories verifies if the required directories to start the ingress controller exist and creates the missing ones.

func SHA1

func SHA1(filename string) string

SHA1 returns the SHA1 of a file.

Types

type OSFileWatcher

type OSFileWatcher struct {
	// contains filtered or unexported fields
}

OSFileWatcher defines a watch over a file

func (OSFileWatcher) Close

func (f OSFileWatcher) Close() error

Close ends the watch

type Watcher

type Watcher interface {
	Close() error
}

Watcher is an interface we use to watch changes in files

func NewFileWatcher

func NewFileWatcher(file string, onEvent func()) (Watcher, error)

NewFileWatcher creates a new FileWatcher

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL