terragrunt
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 gitlab.com/abes140377/daggerverse/terragrunt@a7054249129f402701761b0edbfd2375d5471fc6Entrypoint
Return Type
Terragrunt Example
dagger -m gitlab.com/abes140377/daggerverse/terragrunt@a7054249129f402701761b0edbfd2375d5471fc6 call \
func (m *MyModule) Example() *dagger.Terragrunt {
return dag.
Terragrunt()
}@function
def example() -> dagger.Terragrunt:
return (
dag.terragrunt()
)@func()
example(): Terragrunt {
return dag
.terragrunt()
}Types
Terragrunt 🔗
stackApply() 🔗
Runs ‘terragrunt stack run apply – –auto-approve’ in the given stack directory.
Return Type
String !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| source | Directory ! | - | - The repository root directory to mount into the container |
| stackDir | String ! | - | - Relative path to the stack directory (e.g. "staging/proxmox-k3s-vms") |
| sshSocket | Socket ! | - | - SSH agent socket for git authentication (e.g. unix:///run/user/1000/ssh-agent.socket) |
| envVars | [String ! ] ! | - | - Environment variables as KEY=VALUE strings (e.g. "AWS_ACCESS_KEY_ID=abc") |
Example
echo 'Custom types are not supported in shell examples'func (m *MyModule) Example(ctx context.Context, source *dagger.Directory, stackDir string, sshSocket *dagger.Socket, envVars []string) string {
return dag.
Terragrunt().
StackApply(ctx, source, stackDir, sshSocket, envVars)
}@function
async def example(source: dagger.Directory, stack_dir: str, ssh_socket: dagger.Socket, env_vars: List[str]) -> str:
return await (
dag.terragrunt()
.stack_apply(source, stack_dir, ssh_socket, env_vars)
)@func()
async example(source: Directory, stackDir: string, sshSocket: Socket, envVars: string[]): Promise<string> {
return dag
.terragrunt()
.stackApply(source, stackDir, sshSocket, envVars)
}stackPlan() 🔗
Runs ‘terragrunt stack run plan’ in the given stack directory.
Return Type
String !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| source | Directory ! | - | - The repository root directory to mount into the container |
| stackDir | String ! | - | - Relative path to the stack directory (e.g. "staging/proxmox-k3s-vms") |
| sshSocket | Socket ! | - | - SSH agent socket for git authentication (e.g. unix:///run/user/1000/ssh-agent.socket) |
| envVars | [String ! ] ! | - | - Environment variables as KEY=VALUE strings (e.g. "AWS_ACCESS_KEY_ID=abc") |
Example
echo 'Custom types are not supported in shell examples'func (m *MyModule) Example(ctx context.Context, source *dagger.Directory, stackDir string, sshSocket *dagger.Socket, envVars []string) string {
return dag.
Terragrunt().
StackPlan(ctx, source, stackDir, sshSocket, envVars)
}@function
async def example(source: dagger.Directory, stack_dir: str, ssh_socket: dagger.Socket, env_vars: List[str]) -> str:
return await (
dag.terragrunt()
.stack_plan(source, stack_dir, ssh_socket, env_vars)
)@func()
async example(source: Directory, stackDir: string, sshSocket: Socket, envVars: string[]): Promise<string> {
return dag
.terragrunt()
.stackPlan(source, stackDir, sshSocket, envVars)
}stackDestroy() 🔗
Runs ‘terragrunt stack run destroy –non-interactive’ in the given stack directory.
Return Type
String !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| source | Directory ! | - | - The repository root directory to mount into the container |
| stackDir | String ! | - | - Relative path to the stack directory (e.g. "staging/proxmox-k3s-vms") |
| sshSocket | Socket ! | - | - SSH agent socket for git authentication (e.g. unix:///run/user/1000/ssh-agent.socket) |
| envVars | [String ! ] ! | - | - Environment variables as KEY=VALUE strings (e.g. "AWS_ACCESS_KEY_ID=abc") |
Example
echo 'Custom types are not supported in shell examples'func (m *MyModule) Example(ctx context.Context, source *dagger.Directory, stackDir string, sshSocket *dagger.Socket, envVars []string) string {
return dag.
Terragrunt().
StackDestroy(ctx, source, stackDir, sshSocket, envVars)
}@function
async def example(source: dagger.Directory, stack_dir: str, ssh_socket: dagger.Socket, env_vars: List[str]) -> str:
return await (
dag.terragrunt()
.stack_destroy(source, stack_dir, ssh_socket, env_vars)
)@func()
async example(source: Directory, stackDir: string, sshSocket: Socket, envVars: string[]): Promise<string> {
return dag
.terragrunt()
.stackDestroy(source, stackDir, sshSocket, envVars)
}stackGenerate() 🔗
Runs ‘terragrunt stack generate’ in the given stack directory.
Return Type
String !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| source | Directory ! | - | - The repository root directory to mount into the container |
| stackDir | String ! | - | - Relative path to the stack directory (e.g. "staging/proxmox-k3s-vms") |
| sshSocket | Socket ! | - | - SSH agent socket for git authentication (e.g. unix:///run/user/1000/ssh-agent.socket) |
| envVars | [String ! ] ! | - | - Environment variables as KEY=VALUE strings (e.g. "AWS_ACCESS_KEY_ID=abc") |
Example
echo 'Custom types are not supported in shell examples'func (m *MyModule) Example(ctx context.Context, source *dagger.Directory, stackDir string, sshSocket *dagger.Socket, envVars []string) string {
return dag.
Terragrunt().
StackGenerate(ctx, source, stackDir, sshSocket, envVars)
}@function
async def example(source: dagger.Directory, stack_dir: str, ssh_socket: dagger.Socket, env_vars: List[str]) -> str:
return await (
dag.terragrunt()
.stack_generate(source, stack_dir, ssh_socket, env_vars)
)@func()
async example(source: Directory, stackDir: string, sshSocket: Socket, envVars: string[]): Promise<string> {
return dag
.terragrunt()
.stackGenerate(source, stackDir, sshSocket, envVars)
}stackOutput() 🔗
Runs ‘terragrunt stack output’ in the given stack directory.
Return Type
String !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| source | Directory ! | - | - The repository root directory to mount into the container |
| stackDir | String ! | - | - Relative path to the stack directory (e.g. "staging/proxmox-k3s-vms") |
| sshSocket | Socket ! | - | - SSH agent socket for git authentication (e.g. unix:///run/user/1000/ssh-agent.socket) |
| envVars | [String ! ] ! | - | - Environment variables as KEY=VALUE strings (e.g. "AWS_ACCESS_KEY_ID=abc") |
Example
echo 'Custom types are not supported in shell examples'func (m *MyModule) Example(ctx context.Context, source *dagger.Directory, stackDir string, sshSocket *dagger.Socket, envVars []string) string {
return dag.
Terragrunt().
StackOutput(ctx, source, stackDir, sshSocket, envVars)
}@function
async def example(source: dagger.Directory, stack_dir: str, ssh_socket: dagger.Socket, env_vars: List[str]) -> str:
return await (
dag.terragrunt()
.stack_output(source, stack_dir, ssh_socket, env_vars)
)@func()
async example(source: Directory, stackDir: string, sshSocket: Socket, envVars: string[]): Promise<string> {
return dag
.terragrunt()
.stackOutput(source, stackDir, sshSocket, envVars)
}