Documentation ¶
Index ¶
- func BasicAuthToken(user, password string) string
- func CancelTask(id uuid.UUID) error
- func DeleteArchive(id uuid.UUID) error
- func DeleteJob(id uuid.UUID) error
- func DeleteRetentionPolicy(id uuid.UUID) error
- func DeleteSchedule(id uuid.UUID) error
- func DeleteStore(id uuid.UUID) error
- func DeleteTarget(id uuid.UUID) error
- func IsPausedJob(id uuid.UUID) (bool, error)
- func LoadConfig(p string) error
- func PauseJob(id uuid.UUID) error
- func RestoreArchive(id uuid.UUID, targetJSON string) error
- func RunJob(id uuid.UUID, ownerJSON string) error
- func UnpauseJob(id uuid.UUID) error
- type Archive
- type ArchiveFilter
- type Config
- func (cfg *Config) AddBackend(be string, alias string) error
- func (cfg *Config) BackendToken() string
- func (cfg *Config) BackendURI() string
- func (cfg *Config) ResolveAlias(be string) string
- func (cfg *Config) Save() error
- func (cfg *Config) UpdateBackend(be string, token string) error
- func (cfg *Config) UpdateCurrentBackend(token string) error
- func (cfg *Config) UseBackend(be string) error
- type Job
- type JobFilter
- type RetentionPolicy
- func CreateRetentionPolicy(contentJSON string) (RetentionPolicy, error)
- func GetRetentionPolicies(filter RetentionPolicyFilter) ([]RetentionPolicy, error)
- func GetRetentionPolicy(id uuid.UUID) (RetentionPolicy, error)
- func UpdateRetentionPolicy(id uuid.UUID, contentJSON string) (RetentionPolicy, error)
- type RetentionPolicyFilter
- type Schedule
- type ScheduleFilter
- type Status
- type Store
- type StoreFilter
- type Target
- type TargetFilter
- type Task
- type TaskFilter
- type URL
- func (u *URL) AddParameter(key string, value interface{}) error
- func (u *URL) Delete(out interface{}) error
- func (u *URL) Get(out interface{}) error
- func (u *URL) MaybeAddParameter(key string, value interface{}) error
- func (u *URL) Post(out interface{}, data string) error
- func (u *URL) Put(out interface{}, data string) error
- func (u *URL) Request(out interface{}, req *http.Request) error
- func (u *URL) String() string
- type YesNo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BasicAuthToken ¶ added in v0.6.4
func CancelTask ¶
func DeleteArchive ¶
func DeleteRetentionPolicy ¶
func DeleteSchedule ¶
func DeleteStore ¶
func DeleteTarget ¶
func LoadConfig ¶ added in v0.6.4
func UnpauseJob ¶
Types ¶
type Archive ¶
type Archive struct { UUID string `json:"uuid"` StoreKey string `json:"key"` TakenAt Timestamp `json:"taken_at"` ExpiresAt Timestamp `json:"expires_at"` Status string `json:"status"` Notes string `json:"notes"` TargetUUID string `json:"target_uuid"` TargetPlugin string `json:"target_plugin"` TargetEndpoint string `json:"target_endpoint"` StoreUUID string `json:"store_uuid"` StorePlugin string `json:"store_plugin"` StoreEndpoint string `json:"store_endpoint"` }
func GetArchives ¶
func GetArchives(filter ArchiveFilter) ([]Archive, error)
type ArchiveFilter ¶
type Config ¶ added in v0.6.4
type Config struct { Backend string `yaml:"backend"` Backends map[string]string `yaml:"backends"` Aliases map[string]string `yaml:"aliases"` Path string `yaml:"-"` // omit this little guy }
var Cfg *Config
func (*Config) AddBackend ¶ added in v0.6.4
func (*Config) BackendToken ¶ added in v0.6.4
func (*Config) BackendURI ¶ added in v0.6.4
func (*Config) ResolveAlias ¶ added in v0.6.4
func (*Config) UpdateBackend ¶ added in v0.6.4
func (*Config) UpdateCurrentBackend ¶ added in v0.6.4
func (*Config) UseBackend ¶ added in v0.6.4
type Job ¶
type Job struct { UUID string `json:"uuid"` Name string `json:"name"` Summary string `json:"summary"` RetentionName string `json:"retention_name"` RetentionUUID string `json:"retention_uuid"` Expiry int `json:"expiry"` ScheduleName string `json:"schedule_name"` ScheduleUUID string `json:"schedule_uuid"` ScheduleWhen string `json:"schedule_when"` Paused bool `json:"paused"` StoreUUID string `json:"store_uuid"` StoreName string `json:"store_name"` StorePlugin string `json:"store_plugin"` StoreEndpoint string `json:"store_endpoint"` TargetUUID string `json:"target_uuid"` TargetName string `json:"target_name"` TargetPlugin string `json:"target_plugin"` TargetEndpoint string `json:"target_endpoint"` Agent string `json:"agent"` }
type RetentionPolicy ¶
type RetentionPolicy struct { UUID string `json:"uuid"` Name string `json:"name"` Summary string `json:"summary"` Expires uint `json:"expires"` }
func CreateRetentionPolicy ¶
func CreateRetentionPolicy(contentJSON string) (RetentionPolicy, error)
func GetRetentionPolicies ¶
func GetRetentionPolicies(filter RetentionPolicyFilter) ([]RetentionPolicy, error)
func GetRetentionPolicy ¶
func GetRetentionPolicy(id uuid.UUID) (RetentionPolicy, error)
func UpdateRetentionPolicy ¶
func UpdateRetentionPolicy(id uuid.UUID, contentJSON string) (RetentionPolicy, error)
type RetentionPolicyFilter ¶ added in v0.4.1
type Schedule ¶
type Schedule struct { UUID string `json:"uuid"` Name string `json:"name"` Summary string `json:"summary"` When string `json:"when"` }
func CreateSchedule ¶
func GetSchedules ¶
func GetSchedules(filter ScheduleFilter) ([]Schedule, error)
type ScheduleFilter ¶
type Store ¶
type Store struct { UUID string `json:"uuid"` Name string `json:"name"` Summary string `json:"summary"` Plugin string `json:"plugin"` Endpoint string `json:"endpoint"` }
func CreateStore ¶
func GetStores ¶
func GetStores(filter StoreFilter) ([]Store, error)
type StoreFilter ¶
type Target ¶
type Target struct { UUID string `json:"uuid"` Name string `json:"name"` Summary string `json:"summary"` Plugin string `json:"plugin"` Endpoint string `json:"endpoint"` Agent string `json:"agent"` }
func CreateTarget ¶
func GetTargets ¶
func GetTargets(filter TargetFilter) ([]Target, error)
type TargetFilter ¶
type Task ¶
type Task struct { UUID string `json:"uuid"` Owner string `json:"owner"` Op string `json:"type"` JobUUID string `json:"job_uuid"` ArchiveUUID string `json:"archive_uuid"` Status string `json:"status"` StartedAt Timestamp `json:"started_at"` StoppedAt Timestamp `json:"stopped_at"` TimeoutAt Timestamp `json:"timeout_at"` Log string `json:"log"` }
func GetTasks ¶
func GetTasks(filter TaskFilter) ([]Task, error)
type TaskFilter ¶
type URL ¶
type URL struct {
// contains filtered or unexported fields
}
func (*URL) AddParameter ¶
func (*URL) MaybeAddParameter ¶
Click to show internal directories.
Click to hide internal directories.