Documentation ¶
Index ¶
- Constants
- Variables
- type CLI
- func (c *CLI) Apply(ctx context.Context, out io.Writer, manifests manifest.ManifestList) error
- func (c *CLI) Delete(ctx context.Context, out io.Writer, manifests manifest.ManifestList) error
- func (c *CLI) Kustomize(ctx context.Context, args []string) ([]byte, error)
- func (c *CLI) ReadManifests(ctx context.Context, manifests []string) (manifest.ManifestList, error)
- func (c *CLI) WaitForDeletions(ctx context.Context, out io.Writer, manifests manifest.ManifestList) error
- type Config
- type Deployer
- func (k *Deployer) Cleanup(ctx context.Context, out io.Writer) error
- func (k *Deployer) Dependencies() ([]string, error)
- func (k *Deployer) Deploy(ctx context.Context, out io.Writer, builds []graph.Artifact) ([]string, error)
- func (k *Deployer) Render(ctx context.Context, out io.Writer, builds []graph.Artifact, offline bool, ...) error
Constants ¶
View Source
const ( KubectlVersion112 = `{"clientVersion":{"major":"1","minor":"12"}}` KubectlVersion118 = `{"clientVersion":{"major":"1","minor":"18"}}` )
View Source
const DeploymentAppYAML = `apiVersion: v1
kind: Pod
metadata:
name: leeroy-app
spec:
containers:
- name: leeroy-app
image: leeroy-app`
View Source
const DeploymentAppYAMLv1 = `apiVersion: v1
kind: Pod
metadata:
name: leeroy-app
spec:
containers:
- image: leeroy-app:v1
name: leeroy-app`
View Source
const DeploymentAppYAMLv2 = `apiVersion: v1
kind: Pod
metadata:
name: leeroy-app
spec:
containers:
- image: leeroy-app:v2
name: leeroy-app`
View Source
const DeploymentWebYAML = `apiVersion: v1
kind: Pod
metadata:
name: leeroy-web
spec:
containers:
- name: leeroy-web
image: leeroy-web`
View Source
const DeploymentWebYAMLv1 = `apiVersion: v1
kind: Pod
metadata:
name: leeroy-web
spec:
containers:
- image: leeroy-web:v1
name: leeroy-web`
Variables ¶
View Source
var TestKubeConfig = "kubeconfig"
View Source
var TestKubeContext = "kubecontext"
View Source
var TestNamespace = "testNamespace"
View Source
var TestNamespace2 = "testNamespace2"
View Source
var TestNamespace2FromEnvTemplate = "test{{.MYENV}}ace2" // needs `MYENV=Namesp` environment variable
Functions ¶
This section is empty.
Types ¶
type CLI ¶
type CLI struct { *kubectl.CLI Flags latestV1.KubectlFlags // contains filtered or unexported fields }
CLI holds parameters to run kubectl.
func NewCLI ¶ added in v1.7.1
func NewCLI(cfg Config, flags latestV1.KubectlFlags, defaultNameSpace string) CLI
func (*CLI) ReadManifests ¶ added in v0.22.0
ReadManifests reads a list of manifests in yaml format.
func (*CLI) WaitForDeletions ¶ added in v1.7.1
func (c *CLI) WaitForDeletions(ctx context.Context, out io.Writer, manifests manifest.ManifestList) error
WaitForDeletions waits for resource marked for deletion to complete their deletion.
type Deployer ¶ added in v1.7.1
type Deployer struct { *latestV1.KubectlDeploy // contains filtered or unexported fields }
Deployer deploys workflows using kubectl CLI.
func NewDeployer ¶ added in v1.7.1
func NewDeployer(cfg Config, labels map[string]string, d *latestV1.KubectlDeploy) (*Deployer, error)
NewDeployer returns a new Deployer for a DeployConfig filled with the needed configuration for `kubectl apply`
func (*Deployer) Dependencies ¶ added in v1.7.1
Dependencies lists all the files that describe what needs to be deployed.
Click to show internal directories.
Click to hide internal directories.