Documentation
¶
Overview ¶
Package profile implements handling of Talos profiles.
Index ¶
- func Clean(p *profile.Profile)
- func EnhanceFromSchematic(ctx context.Context, prof profile.Profile, schematic *schematicpkg.Schematic, ...) (profile.Profile, error)
- func Hash(p profile.Profile) (string, error)
- func InstallerProfile(secureboot bool, arch artifacts.Arch) profile.Profile
- func ParseFromPath(path, version string) (profile.Profile, error)
- type ArtifactProducer
- type InvalidErrorTag
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Clean ¶
Clean removes non-deterministic fields from the profile.
This code is not in Talos, as the cleaning process is specific to the Image Factory.
func EnhanceFromSchematic ¶
func EnhanceFromSchematic( ctx context.Context, prof profile.Profile, schematic *schematicpkg.Schematic, artifactProducer ArtifactProducer, secureBootService *secureboot.Service, versionTag string, ) (profile.Profile, error)
EnhanceFromSchematic enhances the profile with the schematic.
func Hash ¶
Hash generates a hash describing Talos imager Profile.
Hash is used to determine if the profile has changed and the asset needs to be rebuilt.
Hashing is performed by checksumming YAML representation of the profile, but with some fields specifically trimmed/ignored to remove changes e.g. to the temporary directory.
func InstallerProfile ¶
InstallerProfile returns a profile to be used for installer image.
Types ¶
type ArtifactProducer ¶
type ArtifactProducer interface { GetSchematicExtension(context.Context, string, *schematicpkg.Schematic) (string, error) GetOfficialExtensions(context.Context, string) ([]artifacts.ExtensionRef, error) GetOfficialOverlays(context.Context, string) ([]artifacts.OverlayRef, error) GetExtensionImage(context.Context, artifacts.Arch, artifacts.ExtensionRef) (string, error) GetOverlayImage(context.Context, artifacts.Arch, artifacts.OverlayRef) (string, error) GetInstallerImage(context.Context, artifacts.Arch, string) (string, error) }
ArtifactProducer is a type which produces a set of extensions/meta information, installer images, etc..
type InvalidErrorTag ¶
type InvalidErrorTag struct{}
InvalidErrorTag tags errors related to invalid profiles.