com.pulumi.gitlab.kotlin.GroupEpicBoard.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-gitlab-kotlin Show documentation
Show all versions of pulumi-gitlab-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.gitlab.kotlin
import com.pulumi.core.Output
import com.pulumi.gitlab.kotlin.outputs.GroupEpicBoardList
import com.pulumi.gitlab.kotlin.outputs.GroupEpicBoardList.Companion.toKotlin
import com.pulumi.kotlin.KotlinCustomResource
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.ResourceMapper
import com.pulumi.kotlin.options.CustomResourceOptions
import com.pulumi.kotlin.options.CustomResourceOptionsBuilder
import com.pulumi.resources.Resource
import kotlin.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
/**
* Builder for [GroupEpicBoard].
*/
@PulumiTagMarker
public class GroupEpicBoardResourceBuilder internal constructor() {
public var name: String? = null
public var args: GroupEpicBoardArgs = GroupEpicBoardArgs()
public var opts: CustomResourceOptions = CustomResourceOptions()
/**
* @param name The _unique_ name of the resulting resource.
*/
public fun name(`value`: String) {
this.name = value
}
/**
* @param block The arguments to use to populate this resource's properties.
*/
public suspend fun args(block: suspend GroupEpicBoardArgsBuilder.() -> Unit) {
val builder = GroupEpicBoardArgsBuilder()
block(builder)
this.args = builder.build()
}
/**
* @param block A bag of options that control this resource's behavior.
*/
public suspend fun opts(block: suspend CustomResourceOptionsBuilder.() -> Unit) {
this.opts = com.pulumi.kotlin.options.CustomResourceOptions.opts(block)
}
internal fun build(): GroupEpicBoard {
val builtJavaResource = com.pulumi.gitlab.GroupEpicBoard(
this.name,
this.args.toJava(),
this.opts.toJava(),
)
return GroupEpicBoard(builtJavaResource)
}
}
/**
* The `gitlab.GroupEpicBoard` resource allows to manage the lifecycle of a epic board in a group.
* > Multiple epic boards on one group requires a GitLab Premium or above License.
* **Upstream API**: [GitLab REST API docs](https://docs.gitlab.com/ee/api/group_boards.html)
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as gitlab from "@pulumi/gitlab";
* const example = new gitlab.Group("example", {
* name: "test_group",
* path: "test_group",
* description: "An example group",
* });
* const label1 = new gitlab.GroupLabel("label_1", {
* group: example.id,
* color: "#FF0000",
* name: "red-label",
* });
* const label3 = new gitlab.GroupLabel("label_3", {
* group: example.id,
* name: "label-3",
* color: "#003000",
* });
* const epicBoard = new gitlab.GroupEpicBoard("epic_board", {
* name: "epic board 6",
* group: example.path,
* lists: [{
* labelId: label1.labelId,
* }],
* });
* ```
* ```python
* import pulumi
* import pulumi_gitlab as gitlab
* example = gitlab.Group("example",
* name="test_group",
* path="test_group",
* description="An example group")
* label1 = gitlab.GroupLabel("label_1",
* group=example.id,
* color="#FF0000",
* name="red-label")
* label3 = gitlab.GroupLabel("label_3",
* group=example.id,
* name="label-3",
* color="#003000")
* epic_board = gitlab.GroupEpicBoard("epic_board",
* name="epic board 6",
* group=example.path,
* lists=[{
* "label_id": label1.label_id,
* }])
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using GitLab = Pulumi.GitLab;
* return await Deployment.RunAsync(() =>
* {
* var example = new GitLab.Group("example", new()
* {
* Name = "test_group",
* Path = "test_group",
* Description = "An example group",
* });
* var label1 = new GitLab.GroupLabel("label_1", new()
* {
* Group = example.Id,
* Color = "#FF0000",
* Name = "red-label",
* });
* var label3 = new GitLab.GroupLabel("label_3", new()
* {
* Group = example.Id,
* Name = "label-3",
* Color = "#003000",
* });
* var epicBoard = new GitLab.GroupEpicBoard("epic_board", new()
* {
* Name = "epic board 6",
* Group = example.Path,
* Lists = new[]
* {
* new GitLab.Inputs.GroupEpicBoardListArgs
* {
* LabelId = label1.LabelId,
* },
* },
* });
* });
* ```
* ```go
* package main
* import (
* "github.com/pulumi/pulumi-gitlab/sdk/v8/go/gitlab"
* "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
* )
* func main() {
* pulumi.Run(func(ctx *pulumi.Context) error {
* example, err := gitlab.NewGroup(ctx, "example", &gitlab.GroupArgs{
* Name: pulumi.String("test_group"),
* Path: pulumi.String("test_group"),
* Description: pulumi.String("An example group"),
* })
* if err != nil {
* return err
* }
* label1, err := gitlab.NewGroupLabel(ctx, "label_1", &gitlab.GroupLabelArgs{
* Group: example.ID(),
* Color: pulumi.String("#FF0000"),
* Name: pulumi.String("red-label"),
* })
* if err != nil {
* return err
* }
* _, err = gitlab.NewGroupLabel(ctx, "label_3", &gitlab.GroupLabelArgs{
* Group: example.ID(),
* Name: pulumi.String("label-3"),
* Color: pulumi.String("#003000"),
* })
* if err != nil {
* return err
* }
* _, err = gitlab.NewGroupEpicBoard(ctx, "epic_board", &gitlab.GroupEpicBoardArgs{
* Name: pulumi.String("epic board 6"),
* Group: example.Path,
* Lists: gitlab.GroupEpicBoardListArray{
* &gitlab.GroupEpicBoardListArgs{
* LabelId: label1.LabelId,
* },
* },
* })
* if err != nil {
* return err
* }
* return nil
* })
* }
* ```
* ```java
* package generated_program;
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.gitlab.Group;
* import com.pulumi.gitlab.GroupArgs;
* import com.pulumi.gitlab.GroupLabel;
* import com.pulumi.gitlab.GroupLabelArgs;
* import com.pulumi.gitlab.GroupEpicBoard;
* import com.pulumi.gitlab.GroupEpicBoardArgs;
* import com.pulumi.gitlab.inputs.GroupEpicBoardListArgs;
* import java.util.List;
* import java.util.ArrayList;
* import java.util.Map;
* import java.io.File;
* import java.nio.file.Files;
* import java.nio.file.Paths;
* public class App {
* public static void main(String[] args) {
* Pulumi.run(App::stack);
* }
* public static void stack(Context ctx) {
* var example = new Group("example", GroupArgs.builder()
* .name("test_group")
* .path("test_group")
* .description("An example group")
* .build());
* var label1 = new GroupLabel("label1", GroupLabelArgs.builder()
* .group(example.id())
* .color("#FF0000")
* .name("red-label")
* .build());
* var label3 = new GroupLabel("label3", GroupLabelArgs.builder()
* .group(example.id())
* .name("label-3")
* .color("#003000")
* .build());
* var epicBoard = new GroupEpicBoard("epicBoard", GroupEpicBoardArgs.builder()
* .name("epic board 6")
* .group(example.path())
* .lists(GroupEpicBoardListArgs.builder()
* .labelId(label1.labelId())
* .build())
* .build());
* }
* }
* ```
* ```yaml
* resources:
* example:
* type: gitlab:Group
* properties:
* name: test_group
* path: test_group
* description: An example group
* label1:
* type: gitlab:GroupLabel
* name: label_1
* properties:
* group: ${example.id}
* color: '#FF0000'
* name: red-label
* label3:
* type: gitlab:GroupLabel
* name: label_3
* properties:
* group: ${example.id}
* name: label-3
* color: '#003000'
* epicBoard:
* type: gitlab:GroupEpicBoard
* name: epic_board
* properties:
* name: epic board 6
* group: ${example.path}
* lists:
* - labelId: ${label1.labelId}
* ```
*
* ## Import
* Starting in Terraform v1.5.0 you can use an import block to import `gitlab_group_epic_board`. For example:
* terraform
* import {
* to = gitlab_group_epic_board.example
* id = "see CLI command below for ID"
* }
* Import using the CLI is supported using the following syntax:
* You can import this resource with an id made up of `{group-id}:{epic-board-id}`, e.g.
* ```sh
* $ pulumi import gitlab:index/groupEpicBoard:GroupEpicBoard agile 70:156
* ```
*/
public class GroupEpicBoard internal constructor(
override val javaResource: com.pulumi.gitlab.GroupEpicBoard,
) : KotlinCustomResource(javaResource, GroupEpicBoardMapper) {
/**
* The ID or URL-encoded path of the group owned by the authenticated user.
*/
public val group: Output
get() = javaResource.group().applyValue({ args0 -> args0 })
/**
* The list of epic board lists.
*/
public val lists: Output>?
get() = javaResource.lists().applyValue({ args0 ->
args0.map({ args0 ->
args0.map({ args0 ->
args0.let({ args0 -> toKotlin(args0) })
})
}).orElse(null)
})
/**
* The name of the board.
*/
public val name: Output
get() = javaResource.name().applyValue({ args0 -> args0 })
}
public object GroupEpicBoardMapper : ResourceMapper {
override fun supportsMappingOfType(javaResource: Resource): Boolean =
com.pulumi.gitlab.GroupEpicBoard::class == javaResource::class
override fun map(javaResource: Resource): GroupEpicBoard = GroupEpicBoard(
javaResource as
com.pulumi.gitlab.GroupEpicBoard,
)
}
/**
* @see [GroupEpicBoard].
* @param name The _unique_ name of the resulting resource.
* @param block Builder for [GroupEpicBoard].
*/
public suspend fun groupEpicBoard(
name: String,
block: suspend GroupEpicBoardResourceBuilder.() -> Unit,
): GroupEpicBoard {
val builder = GroupEpicBoardResourceBuilder()
builder.name(name)
block(builder)
return builder.build()
}
/**
* @see [GroupEpicBoard].
* @param name The _unique_ name of the resulting resource.
*/
public fun groupEpicBoard(name: String): GroupEpicBoard {
val builder = GroupEpicBoardResourceBuilder()
builder.name(name)
return builder.build()
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy