package
0.55.1
Repository: https://github.com/ovh/cds.git
Documentation: pkg.go.dev

# Functions

BookForRegister books a worker model for register, used by hatcheries.
ComputeRegistrationNeeds checks if worker models need to be register if requirements contains "binary" type: all workers model need to be registered again by setting flag need_registration to true in DB.
CopyModelTypeData try to set missing type info for given model data.
Create returns a new worker model for given data.
DeleteByID a worker model from database and all its capabilities.
DeleteCapabilitiesByModelID removes all capabilities from database for given worker model id.
DeletePatternByID removes from database the worker model pattern.
DeleteSecretForModelID remove registry secret from database for given model.
Export convert sdk.Model to an exportentities.WorkerModel, format and write into a io.Writer.
Initialize worker model package.
Insert a new worker model in database.
InsertCapabilityForModelID inserts given capability in database.
InsertPattern in database.
InsertSecret in database.
KeyBookWorkerModel returns cache key for given model id.
LoadAll retrieves worker models from database.
LoadAllActiveAndNotDeprecatedForGroupIDs retrieves models for given group ids.
LoadAllByGroupIDs returns worker models list for given group ids.
LoadAllByNameAndGroupIDs retrieves all worker model with given name for group ids in database.
LoadAllUsableByGroupIDs returns usable worker models for given group ids.
LoadByID retrieves a specific worker model in database.
LoadByNameAndGroupID retrieves a specific worker model in database by name and group id.
LoadCapabilitiesByModelID retrieves capabilities of given worker model.
LoadPatternByNameAndType retrieves model patterns from database given its name and type.
LoadPatterns retrieves model patterns from database.
LoadSecretByModelIDAndName retrieves a worker model secret for given model id and secret name.
LoadSecretsByModelID retrieves all worker model secrets for given model id.
Status returns info about worker Model Status.
UnbookForRegister release the book.
Update from given data.
UpdateCapabilities .
UpdateDB a worker model if the worker model have SpawnErr -> clear them.
UpdateOSAndArch updates os and arch for a worker model.
UpdatePattern in database.
UpdateRegistration updates need_registration to false and last_registration time, reset err registration.
UpdateSecret in database.
UpdateSpawnErrorWorkerModel updates worker model error registration.

# Constants

List of const for state filter.
List of const for state filter.
List of const for state filter.
List of const for state filter.
List of const for state filter.
List of const for state filter.

# Variables

LoadOptions provides all options to load worker models.

# Structs

LoadFilter struct for worker model query.

# Type aliases

LoadOptionFunc for worker model.
StateFilter for worker model.