Skip to main content

Class: Builder

Defined in: builder.d.ts:9

Constructors

Constructor

new Builder(options): Builder;

Defined in: builder.d.ts:10

Parameters

ParameterType
optionsBuilderOptions

Returns

Builder

Constructor

new Builder(
version,
distribution,
environmentType): Builder;

Defined in: builder.d.ts:11

Parameters

ParameterType
versionstring | Version
distributionKubernetesDistribution
environmentTypeEnvironmentType

Returns

Builder

Properties

PropertyTypeDescriptionDefined in
componentsreadonly Component[]All components that will be run by this builder. Don't modify this array directly, use Builder.addComponent or Builder.removeComponent instead.builder.d.ts:17
optionsBuilderOptionsCommon options that are used by the builder components.builder.d.ts:20

Methods

addAdditionalFile()

Call Signature

addAdditionalFile(additionalFile): void;

Defined in: builder.d.ts:86

Adds the given additional file to a DocumentGroup named "" during the steps.generateResources step.

Checks for an existing DocumentGroup with the name "" and adds the document to it if it exists. Creates a new DocumentGroup if it doesn't exist.

Parameters
ParameterType
additionalFileAdditionalFile
Returns

void

Call Signature

addAdditionalFile(documentGroupName, additionalFile): void;

Defined in: builder.d.ts:94

Adds the given additional file to a DocumentGroup with the given name during the steps.generateResources step.

Checks for an existing DocumentGroup with the same name and adds the document to it if it exists. Creates a new DocumentGroup if it doesn't exist.

Parameters
ParameterType
documentGroupNamestring
additionalFileAdditionalFile
Returns

void


addComponent()

addComponent(component): void;

Defined in: builder.d.ts:23

Adds given component to the list of components.

Parameters

ParameterType
componentComponent

Returns

void


addDocument()

Call Signature

addDocument(document): void;

Defined in: builder.d.ts:34

Adds the given document to a DocumentGroup named "" during the steps.generateResources step.

Checks for an existing DocumentGroup with the name "" and adds the document to it if it exists. Creates a new DocumentGroup if it doesn't exist.

Parameters
ParameterType
documentDocument
Returns

void

Call Signature

addDocument(documentGroupName, document): void;

Defined in: builder.d.ts:42

Adds the given document to a DocumentGroup with the given name during the steps.generateResources step.

Checks for an existing DocumentGroup with the same name and adds the document to it if it exists. Creates a new DocumentGroup if it doesn't exist.

Parameters
ParameterType
documentGroupNamestring
documentDocument
Returns

void

Call Signature

addDocument(path, yamlContent): void;

Defined in: builder.d.ts:51

Adds a new document to a DocumentGroup named "" during the steps.generateResources step by parsing given YAML string as a Document.

Checks for an existing DocumentGroup with the name "" and adds the document to it if it exists. Creates a new DocumentGroup if it doesn't exist.

Parameters
ParameterType
pathstring
yamlContentstring
Returns

void

Call Signature

addDocument(
documentGroupName,
path,
yamlContent): void;

Defined in: builder.d.ts:60

Adds a new document to a DocumentGroup with the given name during the steps.generateResources step by parsing given YAML string as a Document.

Checks for an existing DocumentGroup with the same name and adds the document to it if it exists. Creates a new DocumentGroup if it doesn't exist.

Parameters
ParameterType
documentGroupNamestring
pathstring
yamlContentstring
Returns

void

Call Signature

addDocument(path, root): void;

Defined in: builder.d.ts:69

Adds a new document to a DocumentGroup named "" during the steps.generateResources step by converting given object to a Document.

Checks for an existing DocumentGroup with the name "" and adds the document to it if it exists. Creates a new DocumentGroup if it doesn't exist.

Parameters
ParameterType
pathstring
rootobject | Mapping
Returns

void

Call Signature

addDocument(
documentGroupName,
path,
root): void;

Defined in: builder.d.ts:78

Adds a new document to a DocumentGroup with the given name during the steps.generateResources step by converting given object to a Document.

Checks for an existing DocumentGroup with the same name and adds the document to it if it exists. Creates a new DocumentGroup if it doesn't exist.

Parameters
ParameterType
documentGroupNamestring
pathstring
rootobject | Mapping
Returns

void


addHelmChart()

addHelmChart(
chartIdentifier,
releaseName,
values?): void;

Defined in: helm.d.ts:11

Creates a document group from the Helm chart using the given values on steps.generateResources step. Chart identifier can be a local path or a URL.

Parameters

ParameterType
chartIdentifierstring
releaseNamestring
values?string

Returns

void


apply()

apply(options?): Component;

Defined in: apply.d.ts:12

Applies the generated manifests to the Kubernetes cluster at the steps.apply step.

Parameters

ParameterTypeDescription
options?OptionsOptions for applying manifests.

Returns

Component


build()

build(): void;

Defined in: builder.d.ts:118

Runs all the components that were added to the builder.

Returns

void


collectCRDs()

collectCRDs(options?): Component;

Defined in: collectCRDs.d.ts:11

Adds a Component that collects Custom Resource Definitions (CRDs) from all the document groups and moves them into a new document group after the steps.modify step.

Parameters

ParameterTypeDescription
options?OptionsOptions for collecting CRDs.

Returns

Component


collectNamespaces()

collectNamespaces(options?): Component;

Defined in: collectNamespaces.d.ts:11

Adds a Component that collects namespace definitions from all the document groups and moves them into a new document group after the steps.modify step.

Parameters

ParameterTypeDescription
options?OptionsOptions for collecting namespaces.

Returns

Component


deleteOutputDirectory()

deleteOutputDirectory(options?): Component;

Defined in: deleteOutputDirectory.d.ts:12

Adds a Component that deletes the output directory. This component is used to clean up the output directory before generating new content. It is executed before the steps.output step.

Parameters

ParameterTypeDescription
options?OptionsOptions for deleting the output directory.

Returns

Component


onGenerateResources()

onGenerateResources(callback): Component;

Defined in: builder.d.ts:109

Creates a new component with the given action that will be run during steps.generateResources and adds it to the list of components.

Parameters

ParameterType
callback(context) => void

Returns

Component


onModify()

onModify(callback): Component;

Defined in: builder.d.ts:115

Creates a new component with the given action that will be run during steps.modify and adds it to the list of components.

Parameters

ParameterType
callback(context) => void

Returns

Component


onSanitize()

onSanitize(callback): Component;

Defined in: builder.d.ts:103

Creates a new component with the given action that will be run during steps.sanitize and adds it to the list of components.

Parameters

ParameterType
callback(context) => void

Returns

Component


onStep()

onStep(step, callback): Component;

Defined in: builder.d.ts:97

Creates a new component with the given action and adds it to the list of components.

Parameters

ParameterType
stepStep
callback(context) => void

Returns

Component


removeComponent()

removeComponent(component): void;

Defined in: builder.d.ts:26

Removes given component from the list of components.

Parameters

ParameterType
componentComponent

Returns

void


writeDocuments()

writeDocuments(options?): Component;

Defined in: writeDocuments.d.ts:11

Adds a Component that writes the documents from all document groups to the output directory as YAML files during the steps.output step.

Parameters

ParameterTypeDescription
options?OptionsOptions for writing documents.

Returns

Component