Documentation
¶
Overview ¶
Package platformimage is the deployment-config image catalog: the single source of truth for every container image the platform itself runs (database engines, backup tools, the gateway, internal helpers, the agent). Built-in defaults live in code; admins override them at runtime via the settings store (keys prefixed "image."), and an optional global registry mirror repoints all of them at a private registry.
Index ¶
Constants ¶
const ( KeyPostgres = "db.postgres" KeyMySQL = "db.mysql" KeyMariaDB = "db.mariadb" KeyRedis = "db.redis" KeyMongoDB = "db.mongodb" KeyLibSQL = "db.libsql" KeyBackupPostgres = "backup.postgres" KeyBackupMySQL = "backup.mysql" KeyBackupMongoDB = "backup.mongodb" KeyBackupLibSQL = "backup.libsql" KeyBackupVolume = "backup.volume" KeyGoma = "gateway.goma" KeyRelay = "util.relay" KeyHelper = "util.helper" KeyAgent = "agent" KeyRegistry = "util.registry" // KeyPack is the one-shot helper image that runs the `pack` CLI to build an // app from source with Cloud Native Buildpacks. KeyBuildpackBuilder is the // default builder image pack uses when an app does not override it. KeyPack = "build.pack" KeyBuildpackBuilder = "build.buildpack-builder" )
Image catalog keys.
Variables ¶
This section is empty.
Functions ¶
func MirrorSettingKey ¶
func MirrorSettingKey() string
MirrorSettingKey is the settings-store key for the registry mirror.
func RepoTag ¶
RepoTag splits an image ref into its repository and tag. A missing tag defaults to "latest". Handles a registry host:port (the colon before a port is not the tag separator).
func SettingKey ¶
SettingKey is the settings-store key for a catalog key's override.
Types ¶
type CatalogItem ¶
type CatalogItem struct {
Entry
Override string `json:"override"` // raw admin override ("" = none)
Effective string `json:"effective"` // what the platform will actually run
}
CatalogItem is a catalog entry resolved against the current settings, for the admin API.
type Entry ¶
type Entry struct {
Key string `json:"key"`
Label string `json:"label"`
Category string `json:"category"`
Default string `json:"default"`
Description string `json:"description"`
}
Entry describes a platform image: a stable key, a human label, a category, the built-in default ref, and what it's used for.
type Resolver ¶
type Resolver struct {
// contains filtered or unexported fields
}
Resolver resolves a catalog key to an effective image ref (admin override -> built-in default), applying the global registry mirror.
func New ¶
New builds a resolver. configDefaults overrides built-in defaults for specific keys (e.g. the gateway/relay images from env config), so env-based config keeps acting as the default with admin overrides layered on top.
func (*Resolver) Catalog ¶
func (r *Resolver) Catalog() []CatalogItem
Catalog returns every image with its default, override, and effective ref, ordered as defined.