Documentation ¶
Index ¶
Constants ¶
View Source
const TIMEOUT = 120
Variables ¶
This section is empty.
Functions ¶
func ClearWorker ¶ added in v0.1.0
func ClearWorker(id int, client client.IArgoCDClient, context context.Context, projects <-chan *v1alpha1.AppProject, results chan<- WorkerResult)
func SetWorker ¶ added in v0.1.0
func SetWorker(id int, client client.IArgoCDClient, context context.Context, syncWindowsToSet []v1alpha1.SyncWindow, projects <-chan *v1alpha1.AppProject, results chan<- WorkerResult)
Types ¶
type Argonap ¶
type Argonap struct { *Config // Client ArgoCDClient client.IArgoCDClient ArgoCDClientConnected bool // Allow swapping out stdout/stderr for testing. Out io.Writer Err io.Writer }
Argonap is the logic/orchestrator.
func NewWithConfig ¶
func (*Argonap) ClearSyncWindows ¶
func (a *Argonap) ClearSyncWindows()
func (*Argonap) Error ¶
func (a *Argonap) Error(msg interface{})
Error pritns an error to stderr and exits with error code 1.
func (*Argonap) Output ¶
func (a *Argonap) Output(msg interface{})
Output prints a normal message to stdout.
func (*Argonap) OutputHeading ¶
func (a *Argonap) OutputHeading(msg interface{})
OutputHeading prints a header to stdout.
func (*Argonap) OutputResult ¶ added in v0.1.0
func (a *Argonap) OutputResult(result WorkerResult)
OutputResult prints results to stdout.
func (*Argonap) SetSyncWindows ¶
func (a *Argonap) SetSyncWindows()
type StatusType ¶ added in v0.1.0
type StatusType string
const ( StatusSuccess StatusType = "Success" StatusFailure StatusType = "Failure" StatusIncomplete StatusType = "Incomplete" )
type WorkerResult ¶ added in v0.1.0
type WorkerResult struct { Status StatusType SyncWindows int ProjectName string Err *error }
Click to show internal directories.
Click to hide internal directories.