k8s

package
v0.0.16 Latest Latest
Warning

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

Go to latest
Published: Jun 5, 2025 License: MIT Imports: 15 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateServiceObject

func CreateServiceObject(params ServiceParams) (*v1.Service, error)

CreateServiceObject creates a new v1.Service object with the provided parameters

Types

type K8SClient

type K8SClient struct {
	// contains filtered or unexported fields
}

func (*K8SClient) DeployImage

func (self *K8SClient) DeployImage(ctx context.Context, crdName, image string, additionalEnv map[string]string, securityContext *corev1.SecurityContext, healthCheck *v1.HealthCheckSpec, variableMounts []v1.VariableMountSpec) (*unstructured.Unstructured, *v1.Service, error)

DeployImage creates (or replaces) the service resource in the target namespace for deployment after a successful build job.

type ServiceParams

type ServiceParams struct {
	// Basic service information
	Name        string
	DisplayName string
	Description string
	Namespace   string

	// Service type configuration
	Type             schema.ServiceType
	Builder          schema.ServiceBuilder
	Provider         string
	Framework        string
	DeploymentRef    string
	ServiceRef       string
	TeamRef          string
	ProjectRef       string
	EnvironmentRef   string
	KubernetesSecret string
	EnvVars          []corev1.EnvVar

	// Git configuration
	GitRepoURL           string
	GitRef               string
	GithubInstallationID *int64

	// Deployment configuration
	Image            string
	Hosts            []v1.HostSpec
	Ports            []v1.PortSpec
	Public           *bool
	Replicas         *int32
	ImagePullSecrets []string
	RunCommand       string

	// Volume
	Volumes []v1.VolumeSpec

	// Database
	DatabaseType          string
	DatabaseUSDVersionRef string
	DatabaseConfig        *v1.DatabaseConfigSpec
	BackupConfig          *v1.S3ConfigSpec

	// Security
	SecurityContext *corev1.SecurityContext

	// Health check
	HealthCheck *v1.HealthCheckSpec

	// Variable mounts
	VariableMounts []v1.VariableMountSpec

	// Init containers
	InitContainers []v1.InitContainerSpec

	// Resources
	Resources *v1.ResourceSpec
}

ServiceParams contains all parameters needed to create a v1.Service object

Jump to

Keyboard shortcuts

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