syncer

package
v0.0.0-...-1a1f412 Latest Latest
Warning

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

Go to latest
Published: Jul 30, 2018 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (

	// ErrInvalidAPIInstance error indicates that no valid api instance was
	// provided to the syncer constructor.
	ErrInvalidAPIInstance = errors.New("invalid api instance")
)

Functions

This section is empty.

Types

type Config

type Config struct {
	Api          *api.API
	HostPackages bool
	PackagesPath string
	PackagesURL  string
}

Config represents the configuration used to create a new Syncer instance.

type Syncer

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

Syncer represents a process in charge of checking for updates in the different official CoreOS channels and updating the CoreOS application in CoreRoller as needed (creating new packages and updating channels to point to them). When hostPackages is enabled, packages payloads will be downloaded into packagesPath and package url/filename will be rewritten.

func New

func New(conf *Config) (*Syncer, error)

New creates a new Syncer instance.

func (*Syncer) Start

func (s *Syncer) Start()

Start makes the syncer start working. It will check for updates every checkFrequency until it's asked to stop.

func (*Syncer) Stop

func (s *Syncer) Stop()

Stop stops the polling for updates.

Jump to

Keyboard shortcuts

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