Documentation
¶
Index ¶
Constants ¶
const ControlTemplate = `` /* 583-byte string literal not displayed */
Variables ¶
var ( ExtensionMap = map[string]string{ "bionic": "deb", "bookworm": "deb", "bullseye": "deb", "buster": "deb", "focal": "deb", "jammy": "deb", "noble": "deb", "rhel9": "rpm", "rhel8": "rpm", "mariner2": "rpm", "windows": "zip", } OSMap = map[string]string{ "bookworm": "debian", "bullseye": "debian", "buster": "debian", "bionic": "ubuntu", "focal": "ubuntu", "jammy": "ubuntu", "noble": "ubuntu", "rhel9": "el9", "rhel8": "el8", "mariner2": "cm2", "windows": "windows", } VersionMap = map[string]string{ "bookworm": "12", "bullseye": "11", "buster": "10", "bionic": "18.04", "focal": "20.04", "jammy": "22.04", "noble": "24.04", "rhel9": "el9", "rhel8": "el8", "mariner2": "cm2", } )
var (
DebDistroMap = map[string]string{
"xenial": "ubuntu16.04",
"yakkety": "ubuntu16.10",
"zesty": "ubuntu17.04",
"artful": "ubuntu17.10",
"bionic": "ubuntu18.04",
"cosmic": "ubuntu18.10",
"disco": "ubuntu19.04",
"eoan": "ubuntu19.10",
"focal": "ubuntu20.04",
"groovy": "ubuntu20.10",
"hirsute": "ubuntu21.04",
"impish": "ubuntu21.10",
"jammy": "ubuntu22.04",
"kinetic": "ubuntu22.10",
"noble": "ubuntu24.04",
"lunar": "ubuntu23.04",
"buster": "debian10",
"bullseye": "debian11",
"bookworm": "debian12",
"trixie": "debian13",
"forky": "debian14",
}
)
Functions ¶
This section is empty.
Types ¶
type Archive ¶
type Archive struct {
Name string
Distro string
Webpage string
Files []File
Systemd []Systemd
// list of filenames
Postinst []string
// required for debian dependency resolution
Binaries []string
WinBinaries []string
Recommends []string
Suggests []string
Conflicts []string
Replaces []string
Provides []string
BuildDeps []string
RuntimeDeps []string
InstallScripts []InstallScript
Description string
}
type DebPackager ¶
type DebPackager struct {
// contains filtered or unexported fields
}
func NewDebPackager ¶
func NewDebPackager(a *Archive, mp string) *DebPackager
type InstallScript ¶
type PkgInstallMap ¶
type PkgInstallMap map[PkgKind][]InstallScript
type PkgKindMap ¶
type RpmPackager ¶
type RpmPackager struct {
// contains filtered or unexported fields
}
func NewRPMPackager ¶
func NewRPMPackager(a *Archive, mp string) *RpmPackager
type Spec ¶
type Spec struct {
Pkg string `json:"package"`
Distro string `json:"distro"`
Arch string `json:"arch"`
Repo string `json:"repo"`
Commit string `json:"commit"`
Tag string `json:"tag"`
Revision string `json:"revision"`
}
func (*Spec) Basename ¶
There are semantic rules on the naming of packages for both debian- and rpm- based repositories. This method will generate the basename of the package name, according to those semantic rules, based on the information in the build spec.
func (*Spec) Dir ¶
Our pipelines have historically used opinionated filesystem layouts to place artifacts in a consistent location. This method will determine the directory structure for all path components except the basename of the artifact produced by this build spec definition. Because the base directory can be different depending on the situation, it is supplied as an argument. Use "." as the rootDir in order to use a relative path.
func (*Spec) FullPath ¶
This method is provided for convenience, simply combinging `.Dir()` and `.Basename()`. See the documentation for those methods for more information.
func (*Spec) NameTagRevision ¶
This logic is arbitrary, but the output must be reproducible. This is used to generate filenames for artifacts.
func (*Spec) StoragePath ¶
This function calculates the storage path for a package in the prod storage container.
type WinPackager ¶
type WinPackager struct {
// contains filtered or unexported fields
}
func NewWinPackager ¶
func NewWinPackager(a *Archive, mp string) *WinPackager