controller-gen
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/cloudnative-pg/daggerverse/controller-gen@8479d45dc8e492f5a964dad04756a2434db9b704Entrypoint
Return Type
ControllerGen !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| controllerGenVersion | String | "0.22.0" | ControllerGen to use. renovate: datasource=github-tags depName=kubernetes-sigs/controller-tools versioning=semver |
| goImage | String | "golang:1.27.1-bookworm" | renovate image: datasource=docker depName=golang versioning=docker |
| ctr | Container | - | No description provided |
Example
dagger -m github.com/cloudnative-pg/daggerverse/controller-gen@8479d45dc8e492f5a964dad04756a2434db9b704 call \
func (m *MyModule) Example() *dagger.ControllerGen {
return dag.
Controllergen()
}@function
def example() -> dagger.ControllerGen:
return (
dag.controller_gen()
)@func()
example(): ControllerGen {
return dag
.controllerGen()
}Types
ControllerGen 🔗
controllerGen() 🔗
Return Type
Container !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| source | Directory ! | - | The directory of the repository. |
| args | [String ! ] | - | A list of arguments to pass to controller-gen. |
Example
dagger -m github.com/cloudnative-pg/daggerverse/controller-gen@8479d45dc8e492f5a964dad04756a2434db9b704 call \
controller-gen --source DIR_PATHfunc (m *MyModule) Example(source *dagger.Directory) *dagger.Container {
return dag.
Controllergen().
Controllergen(source)
}@function
def example(source: dagger.Directory) -> dagger.Container:
return (
dag.controller_gen()
.controllergen(source)
)@func()
example(source: Directory): Container {
return dag
.controllerGen()
.controllerGen(source)
}