Documentation ¶
Index ¶
- func CopyFileToPod(config *rest.Config, clientset *kubernetes.Clientset, podName string, ...) error
- func ExecInPod(config *rest.Config, clientset *kubernetes.Clientset, podName string, ...) error
- func WriteHostsFileAndRestartPihole(config *rest.Config, clientset *kubernetes.Clientset, podName string, ...) error
- type DaemonBetaIngressMonitor
- func (d *DaemonBetaIngressMonitor) GetResourceHostsEntry(obj interface{}) hostsfile.HostsEntry
- func (d *DaemonBetaIngressMonitor) Informer(sif informers.SharedInformerFactory) cache.SharedInformer
- func (d *DaemonBetaIngressMonitor) Name() string
- func (d *DaemonBetaIngressMonitor) ValidateResource(obj interface{}) (string, error)
- type DaemonConfig
- type DaemonIngressMonitor
- func (d *DaemonIngressMonitor) GetResourceHostsEntry(obj interface{}) hostsfile.HostsEntry
- func (d *DaemonIngressMonitor) Informer(sif informers.SharedInformerFactory) cache.SharedInformer
- func (d *DaemonIngressMonitor) Name() string
- func (d *DaemonIngressMonitor) ValidateResource(obj interface{}) (string, error)
- type DaemonResourceMonitor
- type DaemonServiceMonitor
- func (d *DaemonServiceMonitor) GetResourceHostsEntry(obj interface{}) hostsfile.HostsEntry
- func (d *DaemonServiceMonitor) Informer(sif informers.SharedInformerFactory) cache.SharedInformer
- func (d *DaemonServiceMonitor) Name() string
- func (d *DaemonServiceMonitor) ValidateResource(obj interface{}) (string, error)
- type HostsFileDaemon
- func (hfd *HostsFileDaemon) InformerAddFunc(drm DaemonResourceMonitor) func(obj interface{})
- func (hfd *HostsFileDaemon) InformerDeleteFunc(drm DaemonResourceMonitor) func(obj interface{})
- func (hfd *HostsFileDaemon) InformerUpdateFunc(drm DaemonResourceMonitor) func(oldObj, newObj interface{})
- func (hfd *HostsFileDaemon) Monitor(drm DaemonResourceMonitor)
- func (hfd *HostsFileDaemon) Run()
- type IHostsFileDaemon
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CopyFileToPod ¶
Types ¶
type DaemonBetaIngressMonitor ¶ added in v0.3.0
type DaemonBetaIngressMonitor struct {
// contains filtered or unexported fields
}
func (*DaemonBetaIngressMonitor) GetResourceHostsEntry ¶ added in v0.3.0
func (d *DaemonBetaIngressMonitor) GetResourceHostsEntry(obj interface{}) hostsfile.HostsEntry
func (*DaemonBetaIngressMonitor) Informer ¶ added in v0.3.0
func (d *DaemonBetaIngressMonitor) Informer(sif informers.SharedInformerFactory) cache.SharedInformer
func (*DaemonBetaIngressMonitor) Name ¶ added in v0.3.0
func (d *DaemonBetaIngressMonitor) Name() string
func (*DaemonBetaIngressMonitor) ValidateResource ¶ added in v0.3.0
func (d *DaemonBetaIngressMonitor) ValidateResource(obj interface{}) (string, error)
type DaemonConfig ¶
type DaemonConfig struct { RestConfig *rest.Config KubernetesClientSet *kubernetes.Clientset PiholePodName string IngressIp string SearchDomain string }
Everything needed to control what the daemon executes against.
func NewDaemonConfig ¶
func NewDaemonConfig(ingressIp, searchDomain, clusterIp, bearerToken, piholePodName string) (*DaemonConfig, error)
func NewDaemonConfigInCluster ¶
func NewDaemonConfigInCluster(ingressIp string, searchDomain string) (*DaemonConfig, error)
Assumes that this is running in the same pod as the pihole. Uses the pod's own hostname to find the pod's name.
type DaemonIngressMonitor ¶
type DaemonIngressMonitor struct {
// contains filtered or unexported fields
}
func (*DaemonIngressMonitor) GetResourceHostsEntry ¶
func (d *DaemonIngressMonitor) GetResourceHostsEntry(obj interface{}) hostsfile.HostsEntry
func (*DaemonIngressMonitor) Informer ¶
func (d *DaemonIngressMonitor) Informer(sif informers.SharedInformerFactory) cache.SharedInformer
func (*DaemonIngressMonitor) Name ¶
func (d *DaemonIngressMonitor) Name() string
func (*DaemonIngressMonitor) ValidateResource ¶
func (d *DaemonIngressMonitor) ValidateResource(obj interface{}) (string, error)
type DaemonResourceMonitor ¶
type DaemonResourceMonitor interface { Name() string Informer(sif informers.SharedInformerFactory) cache.SharedInformer ValidateResource(obj interface{}) (string, error) GetResourceHostsEntry(obj interface{}) hostsfile.HostsEntry }
type DaemonServiceMonitor ¶
type DaemonServiceMonitor struct {
// contains filtered or unexported fields
}
func (*DaemonServiceMonitor) GetResourceHostsEntry ¶
func (d *DaemonServiceMonitor) GetResourceHostsEntry(obj interface{}) hostsfile.HostsEntry
func (*DaemonServiceMonitor) Informer ¶
func (d *DaemonServiceMonitor) Informer(sif informers.SharedInformerFactory) cache.SharedInformer
func (*DaemonServiceMonitor) Name ¶
func (d *DaemonServiceMonitor) Name() string
func (*DaemonServiceMonitor) ValidateResource ¶
func (d *DaemonServiceMonitor) ValidateResource(obj interface{}) (string, error)
type HostsFileDaemon ¶
type HostsFileDaemon struct {
// contains filtered or unexported fields
}
func NewHostsFileDaemon ¶
func NewHostsFileDaemon(config DaemonConfig) *HostsFileDaemon
func (*HostsFileDaemon) InformerAddFunc ¶
func (hfd *HostsFileDaemon) InformerAddFunc(drm DaemonResourceMonitor) func(obj interface{})
func (*HostsFileDaemon) InformerDeleteFunc ¶
func (hfd *HostsFileDaemon) InformerDeleteFunc(drm DaemonResourceMonitor) func(obj interface{})
func (*HostsFileDaemon) InformerUpdateFunc ¶
func (hfd *HostsFileDaemon) InformerUpdateFunc(drm DaemonResourceMonitor) func(oldObj, newObj interface{})
func (*HostsFileDaemon) Monitor ¶
func (hfd *HostsFileDaemon) Monitor(drm DaemonResourceMonitor)
func (*HostsFileDaemon) Run ¶
func (hfd *HostsFileDaemon) Run()
type IHostsFileDaemon ¶
type IHostsFileDaemon interface { Run() Monitor(drm DaemonResourceMonitor) InformerAddFunc(drm DaemonResourceMonitor) func(obj interface{}) InformerDeleteFunc(drm DaemonResourceMonitor) func(obj interface{}) InformerUpdateFunc(drm DaemonResourceMonitor) func(oldObj, newObj interface{}) }
Click to show internal directories.
Click to hide internal directories.