operator-sdk
This module has been generated via dagger init and serves as a reference tobasic module structure as you get started with Dagger.
Two functions have been pre-created. You can modify, delete, or add to them,
as needed. They demonstrate usage of arguments and return types using simple
echo and grep commands. The functions can be called from the dagger CLI or
from one of the SDKs.
The first line in this comment block is a short description line and the
rest is a long description with more detail on the module's purpose or usage,
if appropriate. All modules should have a short description.
Installation
dagger install github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef
Entrypoint
Return Type
OperatorSdk !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
src | Directory ! | - | The source directory |
container | Container | - | Extra golang container |
sdkVersion | String | - | The operator-sdk cli version to use |
opmVersion | String | - | The opm cli version to use |
controllerGenVersion | String | - | The controller gen version to use |
cleanCrdVersion | String | - | The clean crd version to use |
kustomizeVersion | String | - | The kustomize version to use |
dockerVersion | String | - | The Docker version to use |
kubeVersion | String ! | - | The kube version to use when run tests |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string
func (m *myModule) example(src *Directory, kubeVersion string) *OperatorSdk {
return dag.
OperatorSdk(src, kubeVersion)
}
@function
def example(src: dagger.Directory, kube_version: str) -> dag.OperatorSdk:
return (
dag.operator_sdk(src, kube_version)
)
@func()
example(src: Directory, kubeVersion: string): OperatorSdk {
return dag
.operatorSdk(src, kubeVersion)
}
Types
OperatorSdk 🔗
version() 🔗
Version display the current version of operator-sdk cli
Return Type
String !
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string version
func (m *myModule) example(ctx context.Context, src *Directory, kubeVersion string) string {
return dag.
OperatorSdk(src, kubeVersion).
Version(ctx)
}
@function
async def example(src: dagger.Directory, kube_version: str) -> str:
return await (
dag.operator_sdk(src, kube_version)
.version()
)
@func()
async example(src: Directory, kubeVersion: string): Promise<string> {
return dag
.operatorSdk(src, kubeVersion)
.version()
}
run() 🔗
Return Type
Container !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
cmd | String ! | - | The cmd to run on container |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string run --cmd string
func (m *myModule) example(src *Directory, kubeVersion string, cmd string) *Container {
return dag.
OperatorSdk(src, kubeVersion).
Run(cmd)
}
@function
def example(src: dagger.Directory, kube_version: str, cmd: str) -> dagger.Container:
return (
dag.operator_sdk(src, kube_version)
.run(cmd)
)
@func()
example(src: Directory, kubeVersion: string, cmd: string): Container {
return dag
.operatorSdk(src, kubeVersion)
.run(cmd)
}
generateManifests() 🔗
Return Type
Directory !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
crdVersion | String | - | The CRD version to generate |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string generate-manifests
func (m *myModule) example(src *Directory, kubeVersion string) *Directory {
return dag.
OperatorSdk(src, kubeVersion).
GenerateManifests()
}
@function
def example(src: dagger.Directory, kube_version: str) -> dagger.Directory:
return (
dag.operator_sdk(src, kube_version)
.generate_manifests()
)
@func()
example(src: Directory, kubeVersion: string): Directory {
return dag
.operatorSdk(src, kubeVersion)
.generateManifests()
}
generateBundle() 🔗
Bundle generate the bundle
Return Type
Directory !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
imageName | String ! | - | The OCI image name without the version |
version | String ! | - | The current version |
channels | String | - | The channels |
previousVersion | String | - | The previous version |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string generate-bundle --image-name string --version string
func (m *myModule) example(src *Directory, kubeVersion string, imageName string, version string) *Directory {
return dag.
OperatorSdk(src, kubeVersion).
GenerateBundle(imageName, version)
}
@function
def example(src: dagger.Directory, kube_version: str, image_name: str, version: str) -> dagger.Directory:
return (
dag.operator_sdk(src, kube_version)
.generate_bundle(image_name, version)
)
@func()
example(src: Directory, kubeVersion: string, imageName: string, version: string): Directory {
return dag
.operatorSdk(src, kubeVersion)
.generateBundle(imageName, version)
}
installOlm() 🔗
InstallOlm permit to install the OLM
Return Type
String !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
kubeconfig | File ! | - | The kubeconfig file to access on cluster where to install OLM |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string install-olm --kubeconfig file:path
func (m *myModule) example(ctx context.Context, src *Directory, kubeVersion string, kubeconfig *File) string {
return dag.
OperatorSdk(src, kubeVersion).
InstallOlm(ctx, kubeconfig)
}
@function
async def example(src: dagger.Directory, kube_version: str, kubeconfig: dagger.File) -> str:
return await (
dag.operator_sdk(src, kube_version)
.install_olm(kubeconfig)
)
@func()
async example(src: Directory, kubeVersion: string, kubeconfig: File): Promise<string> {
return dag
.operatorSdk(src, kubeVersion)
.installOlm(kubeconfig)
}
withSource() 🔗
WithSource permit to update source on all sub containers
Return Type
OperatorSdk !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
src | Directory ! | - | No description provided |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string with-source --src DIR_PATH
func (m *myModule) example(src *Directory, kubeVersion string, src1 *Directory) *OperatorSdk {
return dag.
OperatorSdk(src, kubeVersion).
WithSource(src1)
}
@function
def example(src: dagger.Directory, kube_version: str, src1: dagger.Directory) -> dag.OperatorSdk:
return (
dag.operator_sdk(src, kube_version)
.with_source(src1)
)
@func()
example(src: Directory, kubeVersion: string, src1: Directory): OperatorSdk {
return dag
.operatorSdk(src, kubeVersion)
.withSource(src1)
}
installOlmOperator() 🔗
Return Type
Service !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
catalogImage | String ! | - | The catalog image to install |
name | String ! | - | The operator name |
channel | String | "stable" | The channel of the operator to install |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string install-olm-operator --catalog-image string --name string
func (m *myModule) example(src *Directory, kubeVersion string, catalogImage string, name string) *Service {
return dag.
OperatorSdk(src, kubeVersion).
InstallOlmOperator(catalogImage, name)
}
@function
def example(src: dagger.Directory, kube_version: str, catalog_image: str, name: str) -> dagger.Service:
return (
dag.operator_sdk(src, kube_version)
.install_olm_operator(catalog_image, name)
)
@func()
example(src: Directory, kubeVersion: string, catalogImage: string, name: string): Service {
return dag
.operatorSdk(src, kubeVersion)
.installOlmOperator(catalogImage, name)
}
kubectl() 🔗
Return Type
Container !
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string kubectl
func (m *myModule) example(src *Directory, kubeVersion string) *Container {
return dag.
OperatorSdk(src, kubeVersion).
Kubectl()
}
@function
def example(src: dagger.Directory, kube_version: str) -> dagger.Container:
return (
dag.operator_sdk(src, kube_version)
.kubectl()
)
@func()
example(src: Directory, kubeVersion: string): Container {
return dag
.operatorSdk(src, kubeVersion)
.kubectl()
}
kubeconfig() 🔗
Return Type
File !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
local | Boolean | - | set true if expose the k3s on host |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string kubeconfig
func (m *myModule) example(src *Directory, kubeVersion string) *File {
return dag.
OperatorSdk(src, kubeVersion).
Kubeconfig()
}
@function
def example(src: dagger.Directory, kube_version: str) -> dagger.File:
return (
dag.operator_sdk(src, kube_version)
.kubeconfig()
)
@func()
example(src: Directory, kubeVersion: string): File {
return dag
.operatorSdk(src, kubeVersion)
.kubeconfig()
}
kubeCluster() 🔗
Return Type
Service !
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string kube-cluster
func (m *myModule) example(src *Directory, kubeVersion string) *Service {
return dag.
OperatorSdk(src, kubeVersion).
KubeCluster()
}
@function
def example(src: dagger.Directory, kube_version: str) -> dagger.Service:
return (
dag.operator_sdk(src, kube_version)
.kube_cluster()
)
@func()
example(src: Directory, kubeVersion: string): Service {
return dag
.operatorSdk(src, kubeVersion)
.kubeCluster()
}
kubeContainer() 🔗
Return Type
Container !
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string kube-container
func (m *myModule) example(src *Directory, kubeVersion string) *Container {
return dag.
OperatorSdk(src, kubeVersion).
KubeContainer()
}
@function
def example(src: dagger.Directory, kube_version: str) -> dagger.Container:
return (
dag.operator_sdk(src, kube_version)
.kube_container()
)
@func()
example(src: Directory, kubeVersion: string): Container {
return dag
.operatorSdk(src, kubeVersion)
.kubeContainer()
}
test() 🔗
Test permit to run golang tests
Return Type
File !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
short | Boolean | - | if only short running tests should be executed |
shuffle | Boolean | - | if the tests should be executed out of order |
run | String | - | run select tests only, defined using a regex |
skip | String | - | skip select tests, defined using a regex |
withGotestsum | Boolean | - | Run test with gotestsum |
path | String | - | Path to test |
withKubeversion | String | "latest" | The Kubeversion version to use |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string test
func (m *myModule) example(src *Directory, kubeVersion string) *File {
return dag.
OperatorSdk(src, kubeVersion).
Test()
}
@function
def example(src: dagger.Directory, kube_version: str) -> dagger.File:
return (
dag.operator_sdk(src, kube_version)
.test()
)
@func()
example(src: Directory, kubeVersion: string): File {
return dag
.operatorSdk(src, kubeVersion)
.test()
}
withRepositoryCredentials() 🔗
Return Type
OperatorSdkOci !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
url | String ! | - | The repository URL |
username | String ! | - | The username |
password | Secret ! | - | The password |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string with-repository-credentials --url string --username string --password env:MYSECRET
func (m *myModule) example(src *Directory, kubeVersion string, url string, username string, password *Secret) *OperatorSdkOci {
return dag.
OperatorSdk(src, kubeVersion).
WithRepositoryCredentials(url, username, password)
}
@function
def example(src: dagger.Directory, kube_version: str, url: str, username: str, password: dagger.Secret) -> dag.OperatorSdkOci:
return (
dag.operator_sdk(src, kube_version)
.with_repository_credentials(url, username, password)
)
@func()
example(src: Directory, kubeVersion: string, url: string, username: string, password: Secret): OperatorSdkOci {
return dag
.operatorSdk(src, kubeVersion)
.withRepositoryCredentials(url, username, password)
}
buildManager() 🔗
BuildManager permit to build manager image
Return Type
OperatorSdkOci !
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string build-manager
func (m *myModule) example(src *Directory, kubeVersion string) *OperatorSdkOci {
return dag.
OperatorSdk(src, kubeVersion).
BuildManager()
}
@function
def example(src: dagger.Directory, kube_version: str) -> dag.OperatorSdkOci:
return (
dag.operator_sdk(src, kube_version)
.build_manager()
)
@func()
example(src: Directory, kubeVersion: string): OperatorSdkOci {
return dag
.operatorSdk(src, kubeVersion)
.buildManager()
}
publishManager() 🔗
PublishManager permit to push OCI image on registry
Return Type
String !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
name | String ! | - | The image name to push |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string publish-manager --name string
func (m *myModule) example(ctx context.Context, src *Directory, kubeVersion string, name string) string {
return dag.
OperatorSdk(src, kubeVersion).
PublishManager(ctx, name)
}
@function
async def example(src: dagger.Directory, kube_version: str, name: str) -> str:
return await (
dag.operator_sdk(src, kube_version)
.publish_manager(name)
)
@func()
async example(src: Directory, kubeVersion: string, name: string): Promise<string> {
return dag
.operatorSdk(src, kubeVersion)
.publishManager(name)
}
buildBundle() 🔗
BuildCatalog permit to build catalog image
Return Type
OperatorSdkOci !
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string build-bundle
func (m *myModule) example(src *Directory, kubeVersion string) *OperatorSdkOci {
return dag.
OperatorSdk(src, kubeVersion).
BuildBundle()
}
@function
def example(src: dagger.Directory, kube_version: str) -> dag.OperatorSdkOci:
return (
dag.operator_sdk(src, kube_version)
.build_bundle()
)
@func()
example(src: Directory, kubeVersion: string): OperatorSdkOci {
return dag
.operatorSdk(src, kubeVersion)
.buildBundle()
}
publishBundle() 🔗
PublishBundle permit to push OCI image on registry
Return Type
String !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
name | String ! | - | The image name to push |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string publish-bundle --name string
func (m *myModule) example(ctx context.Context, src *Directory, kubeVersion string, name string) string {
return dag.
OperatorSdk(src, kubeVersion).
PublishBundle(ctx, name)
}
@function
async def example(src: dagger.Directory, kube_version: str, name: str) -> str:
return await (
dag.operator_sdk(src, kube_version)
.publish_bundle(name)
)
@func()
async example(src: Directory, kubeVersion: string, name: string): Promise<string> {
return dag
.operatorSdk(src, kubeVersion)
.publishBundle(name)
}
buildCatalog() 🔗
Return Type
OperatorSdkOci !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
catalogImage | String ! | - | The catalog image name |
previousCatalogImage | String | - | The previuous catalog image name If update 'true' and 'previousCatalogImage' not provided, it use the 'catalogImage' |
bundleImage | String ! | - | The bundle image name |
update | Boolean | - | Set to true to update existing catalog |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string build-catalog --catalog-image string --bundle-image string
func (m *myModule) example(src *Directory, kubeVersion string, catalogImage string, bundleImage string) *OperatorSdkOci {
return dag.
OperatorSdk(src, kubeVersion).
BuildCatalog(catalogImage, bundleImage)
}
@function
def example(src: dagger.Directory, kube_version: str, catalog_image: str, bundle_image: str) -> dag.OperatorSdkOci:
return (
dag.operator_sdk(src, kube_version)
.build_catalog(catalog_image, bundle_image)
)
@func()
example(src: Directory, kubeVersion: string, catalogImage: string, bundleImage: string): OperatorSdkOci {
return dag
.operatorSdk(src, kubeVersion)
.buildCatalog(catalogImage, bundleImage)
}
publishCatalog() 🔗
PublishCatalog permit to publish the catalog image
Return Type
String !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
name | String ! | - | The image name to push |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
--src DIR_PATH --kube-version string publish-catalog --name string
func (m *myModule) example(ctx context.Context, src *Directory, kubeVersion string, name string) string {
return dag.
OperatorSdk(src, kubeVersion).
PublishCatalog(ctx, name)
}
@function
async def example(src: dagger.Directory, kube_version: str, name: str) -> str:
return await (
dag.operator_sdk(src, kube_version)
.publish_catalog(name)
)
@func()
async example(src: Directory, kubeVersion: string, name: string): Promise<string> {
return dag
.operatorSdk(src, kubeVersion)
.publishCatalog(name)
}
OperatorSdkOci 🔗
golangContainer() 🔗
The Golang container
Return Type
Container !
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
build-catalog --catalog-image string --bundle-image string \
golang-container
func (m *myModule) example(catalogImage string, bundleImage string) *Container {
return dag.
OperatorSdk().
BuildCatalog(catalogImage, bundleImage).
GolangContainer()
}
@function
def example(catalog_image: str, bundle_image: str) -> dagger.Container:
return (
dag.operator_sdk()
.build_catalog(catalog_image, bundle_image)
.golang_container()
)
@func()
example(catalogImage: string, bundleImage: string): Container {
return dag
.operatorSdk()
.buildCatalog(catalogImage, bundleImage)
.golangContainer()
}
dockerContainer() 🔗
The Docker container
Return Type
Container !
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
build-catalog --catalog-image string --bundle-image string \
docker-container
func (m *myModule) example(catalogImage string, bundleImage string) *Container {
return dag.
OperatorSdk().
BuildCatalog(catalogImage, bundleImage).
DockerContainer()
}
@function
def example(catalog_image: str, bundle_image: str) -> dagger.Container:
return (
dag.operator_sdk()
.build_catalog(catalog_image, bundle_image)
.docker_container()
)
@func()
example(catalogImage: string, bundleImage: string): Container {
return dag
.operatorSdk()
.buildCatalog(catalogImage, bundleImage)
.dockerContainer()
}
manager() 🔗
The manager image
Return Type
Container !
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
build-catalog --catalog-image string --bundle-image string \
manager
func (m *myModule) example(catalogImage string, bundleImage string) *Container {
return dag.
OperatorSdk().
BuildCatalog(catalogImage, bundleImage).
Manager()
}
@function
def example(catalog_image: str, bundle_image: str) -> dagger.Container:
return (
dag.operator_sdk()
.build_catalog(catalog_image, bundle_image)
.manager()
)
@func()
example(catalogImage: string, bundleImage: string): Container {
return dag
.operatorSdk()
.buildCatalog(catalogImage, bundleImage)
.manager()
}
bundle() 🔗
The bundle image
Return Type
Container !
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
build-catalog --catalog-image string --bundle-image string \
bundle
func (m *myModule) example(catalogImage string, bundleImage string) *Container {
return dag.
OperatorSdk().
BuildCatalog(catalogImage, bundleImage).
Bundle()
}
@function
def example(catalog_image: str, bundle_image: str) -> dagger.Container:
return (
dag.operator_sdk()
.build_catalog(catalog_image, bundle_image)
.bundle()
)
@func()
example(catalogImage: string, bundleImage: string): Container {
return dag
.operatorSdk()
.buildCatalog(catalogImage, bundleImage)
.bundle()
}
catalog() 🔗
The catalog image
Return Type
Container !
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
build-catalog --catalog-image string --bundle-image string \
catalog
func (m *myModule) example(catalogImage string, bundleImage string) *Container {
return dag.
OperatorSdk().
BuildCatalog(catalogImage, bundleImage).
Catalog()
}
@function
def example(catalog_image: str, bundle_image: str) -> dagger.Container:
return (
dag.operator_sdk()
.build_catalog(catalog_image, bundle_image)
.catalog()
)
@func()
example(catalogImage: string, bundleImage: string): Container {
return dag
.operatorSdk()
.buildCatalog(catalogImage, bundleImage)
.catalog()
}
withRepositoryCredentials() 🔗
Return Type
OperatorSdkOci !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
url | String ! | - | The repository URL |
username | String ! | - | The username |
password | Secret ! | - | The password |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
build-catalog --catalog-image string --bundle-image string \
with-repository-credentials --url string --username string --password env:MYSECRET
func (m *myModule) example(catalogImage string, bundleImage string, url string, username string, password *Secret) *OperatorSdkOci {
return dag.
OperatorSdk().
BuildCatalog(catalogImage, bundleImage).
WithRepositoryCredentials(url, username, password)
}
@function
def example(catalog_image: str, bundle_image: str, url: str, username: str, password: dagger.Secret) -> dag.OperatorSdkOci:
return (
dag.operator_sdk()
.build_catalog(catalog_image, bundle_image)
.with_repository_credentials(url, username, password)
)
@func()
example(catalogImage: string, bundleImage: string, url: string, username: string, password: Secret): OperatorSdkOci {
return dag
.operatorSdk()
.buildCatalog(catalogImage, bundleImage)
.withRepositoryCredentials(url, username, password)
}
buildManager() 🔗
BuildManager permit to build manager image
Return Type
OperatorSdkOci !
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
build-catalog --catalog-image string --bundle-image string \
build-manager
func (m *myModule) example(catalogImage string, bundleImage string) *OperatorSdkOci {
return dag.
OperatorSdk().
BuildCatalog(catalogImage, bundleImage).
BuildManager()
}
@function
def example(catalog_image: str, bundle_image: str) -> dag.OperatorSdkOci:
return (
dag.operator_sdk()
.build_catalog(catalog_image, bundle_image)
.build_manager()
)
@func()
example(catalogImage: string, bundleImage: string): OperatorSdkOci {
return dag
.operatorSdk()
.buildCatalog(catalogImage, bundleImage)
.buildManager()
}
publishManager() 🔗
PublishManager permit to push OCI image on registry
Return Type
String !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
name | String ! | - | The image name to push |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
build-catalog --catalog-image string --bundle-image string \
publish-manager --name string
func (m *myModule) example(ctx context.Context, catalogImage string, bundleImage string, name string) string {
return dag.
OperatorSdk().
BuildCatalog(catalogImage, bundleImage).
PublishManager(ctx, name)
}
@function
async def example(catalog_image: str, bundle_image: str, name: str) -> str:
return await (
dag.operator_sdk()
.build_catalog(catalog_image, bundle_image)
.publish_manager(name)
)
@func()
async example(catalogImage: string, bundleImage: string, name: string): Promise<string> {
return dag
.operatorSdk()
.buildCatalog(catalogImage, bundleImage)
.publishManager(name)
}
buildBundle() 🔗
BuildCatalog permit to build catalog image
Return Type
OperatorSdkOci !
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
build-catalog --catalog-image string --bundle-image string \
build-bundle
func (m *myModule) example(catalogImage string, bundleImage string) *OperatorSdkOci {
return dag.
OperatorSdk().
BuildCatalog(catalogImage, bundleImage).
BuildBundle()
}
@function
def example(catalog_image: str, bundle_image: str) -> dag.OperatorSdkOci:
return (
dag.operator_sdk()
.build_catalog(catalog_image, bundle_image)
.build_bundle()
)
@func()
example(catalogImage: string, bundleImage: string): OperatorSdkOci {
return dag
.operatorSdk()
.buildCatalog(catalogImage, bundleImage)
.buildBundle()
}
publishBundle() 🔗
PublishBundle permit to push OCI image on registry
Return Type
String !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
name | String ! | - | The image name to push |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
build-catalog --catalog-image string --bundle-image string \
publish-bundle --name string
func (m *myModule) example(ctx context.Context, catalogImage string, bundleImage string, name string) string {
return dag.
OperatorSdk().
BuildCatalog(catalogImage, bundleImage).
PublishBundle(ctx, name)
}
@function
async def example(catalog_image: str, bundle_image: str, name: str) -> str:
return await (
dag.operator_sdk()
.build_catalog(catalog_image, bundle_image)
.publish_bundle(name)
)
@func()
async example(catalogImage: string, bundleImage: string, name: string): Promise<string> {
return dag
.operatorSdk()
.buildCatalog(catalogImage, bundleImage)
.publishBundle(name)
}
buildCatalog() 🔗
Return Type
OperatorSdkOci !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
catalogImage | String ! | - | The catalog image name |
previousCatalogImage | String | - | The previuous catalog image name If update 'true' and 'previousCatalogImage' not provided, it use the 'catalogImage' |
bundleImage | String ! | - | The bundle image name |
update | Boolean | - | Set to true to update existing catalog |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
build-catalog --catalog-image string --bundle-image string \
build-catalog --catalog-image string --bundle-image string
func (m *myModule) example(catalogImage string, bundleImage string, catalogImage1 string, bundleImage1 string) *OperatorSdkOci {
return dag.
OperatorSdk().
BuildCatalog(catalogImage, bundleImage).
BuildCatalog(catalogImage1, bundleImage1)
}
@function
def example(catalog_image: str, bundle_image: str, catalog_image1: str, bundle_image1: str) -> dag.OperatorSdkOci:
return (
dag.operator_sdk()
.build_catalog(catalog_image, bundle_image)
.build_catalog(catalog_image1, bundle_image1)
)
@func()
example(catalogImage: string, bundleImage: string, catalogImage1: string, bundleImage1: string): OperatorSdkOci {
return dag
.operatorSdk()
.buildCatalog(catalogImage, bundleImage)
.buildCatalog(catalogImage1, bundleImage1)
}
publishCatalog() 🔗
PublishCatalog permit to publish the catalog image
Return Type
String !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
name | String ! | - | The image name to push |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
build-catalog --catalog-image string --bundle-image string \
publish-catalog --name string
func (m *myModule) example(ctx context.Context, catalogImage string, bundleImage string, name string) string {
return dag.
OperatorSdk().
BuildCatalog(catalogImage, bundleImage).
PublishCatalog(ctx, name)
}
@function
async def example(catalog_image: str, bundle_image: str, name: str) -> str:
return await (
dag.operator_sdk()
.build_catalog(catalog_image, bundle_image)
.publish_catalog(name)
)
@func()
async example(catalogImage: string, bundleImage: string, name: string): Promise<string> {
return dag
.operatorSdk()
.buildCatalog(catalogImage, bundleImage)
.publishCatalog(name)
}
withSource() 🔗
WithSource permit to update the current source
Return Type
OperatorSdkOci !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
src | Directory ! | - | The source directory |
Example
dagger -m github.com/disaster37/dagger-library-go/operator-sdk@dd3d93e151985c8a5da4f0a1da0bf46eee5b31ef call \
build-catalog --catalog-image string --bundle-image string \
with-source --src DIR_PATH
func (m *myModule) example(catalogImage string, bundleImage string, src *Directory) *OperatorSdkOci {
return dag.
OperatorSdk().
BuildCatalog(catalogImage, bundleImage).
WithSource(src)
}
@function
def example(catalog_image: str, bundle_image: str, src: dagger.Directory) -> dag.OperatorSdkOci:
return (
dag.operator_sdk()
.build_catalog(catalog_image, bundle_image)
.with_source(src)
)
@func()
example(catalogImage: string, bundleImage: string, src: Directory): OperatorSdkOci {
return dag
.operatorSdk()
.buildCatalog(catalogImage, bundleImage)
.withSource(src)
}