descriptor

package
v0.17.1 Latest Latest
Warning

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

Go to latest
Published: Jan 23, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package conversion provides types and functions to convert older API versions of dependency descriptors (v1alpha1, v1alpha3) to the current v1 format.

Index

Constants

View Source
const APIVersionV1 = "kp.kpack.io/v1"
View Source
const APIVersionV1Alpha1 = "kp.kpack.io/v1alpha1"
View Source
const APIVersionV1Alpha3 = "kp.kpack.io/v1alpha3"

APIVersionV1Alpha3 is the API version string for v1alpha3 descriptors

Variables

This section is empty.

Functions

This section is empty.

Types

type ClusterBuilder

type ClusterBuilder struct {
	Name         string                       `yaml:"name" json:"name"`
	ClusterStack string                       `yaml:"clusterStack" json:"clusterStack"`
	ClusterStore string                       `yaml:"clusterStore" json:"clusterStore"`
	Order        []v1alpha2.BuilderOrderEntry `yaml:"order" json:"order"`
}

ClusterBuilder represents a ClusterBuilder in the descriptor (v1alpha3+)

type ClusterBuilderV1Alpha1

type ClusterBuilderV1Alpha1 struct {
	Name  string                    `yaml:"name"`
	Stack string                    `yaml:"stack"`
	Store string                    `yaml:"store"`
	Order []corev1alpha1.OrderEntry `yaml:"order"`
}

type ClusterBuildpack

type ClusterBuildpack struct {
	Name  string `yaml:"name" json:"name"`
	Image string `yaml:"image" json:"image"`
}

ClusterBuildpack represents a ClusterBuildpack in the v1 descriptor

type ClusterLifecycle

type ClusterLifecycle struct {
	Name  string `yaml:"name" json:"name"`
	Image string `yaml:"image" json:"image"`
}

ClusterLifecycle represents a ClusterLifecycle in the v1 descriptor

type ClusterStack

type ClusterStack struct {
	Name       string `yaml:"name" json:"name"`
	BuildImage Source `yaml:"buildImage" json:"buildImage"`
	RunImage   Source `yaml:"runImage" json:"runImage"`
}

ClusterStack represents a ClusterStack in the descriptor

type ClusterStore

type ClusterStore struct {
	Name    string   `yaml:"name" json:"name"`
	Sources []Source `yaml:"sources" json:"sources"`
}

ClusterStore represents a ClusterStore in the descriptor

type DependencyDescriptor

type DependencyDescriptor struct {
	APIVersion              string             `yaml:"apiVersion" json:"apiVersion"`
	Kind                    string             `yaml:"kind" json:"kind"`
	DefaultClusterLifecycle string             `yaml:"defaultClusterLifecycle,omitempty" json:"defaultClusterLifecycle,omitempty"`
	DefaultClusterBuildpack string             `yaml:"defaultClusterBuildpack,omitempty" json:"defaultClusterBuildpack,omitempty"`
	DefaultClusterStack     string             `yaml:"defaultClusterStack,omitempty" json:"defaultClusterStack,omitempty"`
	DefaultClusterBuilder   string             `yaml:"defaultClusterBuilder,omitempty" json:"defaultClusterBuilder,omitempty"`
	ClusterLifecycles       []ClusterLifecycle `yaml:"clusterLifecycles,omitempty" json:"clusterLifecycles,omitempty"`
	ClusterBuildpacks       []ClusterBuildpack `yaml:"clusterBuildpacks,omitempty" json:"clusterBuildpacks,omitempty"`
	ClusterStores           []ClusterStore     `yaml:"clusterStores,omitempty" json:"clusterStores,omitempty"`
	ClusterStacks           []ClusterStack     `yaml:"clusterStacks,omitempty" json:"clusterStacks,omitempty"`
	ClusterBuilders         []ClusterBuilder   `yaml:"clusterBuilders,omitempty" json:"clusterBuilders,omitempty"`
}

DependencyDescriptor represents the target v1 format that all conversions produce

type DependencyDescriptorV1Alpha1

type DependencyDescriptorV1Alpha1 struct {
	APIVersion            string                   `yaml:"apiVersion"`
	Kind                  string                   `yaml:"kind"`
	DefaultStack          string                   `yaml:"defaultStack"`
	DefaultClusterBuilder string                   `yaml:"defaultClusterBuilder"`
	Stores                []ClusterStore           `yaml:"stores"`
	Stacks                []ClusterStack           `yaml:"stacks"`
	ClusterBuilders       []ClusterBuilderV1Alpha1 `yaml:"clusterBuilders"`
}

DependencyDescriptorV1Alpha1 represents the v1alpha1 format of the dependency descriptor

func (DependencyDescriptorV1Alpha1) ToV1

ToV1 converts a v1alpha1 descriptor to the v1 format

type DependencyDescriptorV1Alpha3

type DependencyDescriptorV1Alpha3 struct {
	APIVersion            string           `yaml:"apiVersion"`
	Kind                  string           `yaml:"kind"`
	DefaultClusterStack   string           `yaml:"defaultClusterStack"`
	DefaultClusterBuilder string           `yaml:"defaultClusterBuilder"`
	Lifecycle             Lifecycle        `yaml:"lifecycle"`
	ClusterStores         []ClusterStore   `yaml:"clusterStores"`
	ClusterStacks         []ClusterStack   `yaml:"clusterStacks"`
	ClusterBuilders       []ClusterBuilder `yaml:"clusterBuilders"`
}

DependencyDescriptorV1Alpha3 represents the v1alpha3 format of the dependency descriptor

func (DependencyDescriptorV1Alpha3) ToV1

ToV1 converts a v1alpha3 descriptor to the v1 format

type Lifecycle

type Lifecycle struct {
	Image string `yaml:"image" json:"image"`
}

Lifecycle represents a single lifecycle image in v1alpha3 format

type Source

type Source struct {
	Image string `yaml:"image"`
}

Source represents an image source

Jump to

Keyboard shortcuts

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