com.pulumi.gitlab.kotlin.ProjectIssueArgs.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.core.Output.of
import com.pulumi.gitlab.ProjectIssueArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.Boolean
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.collections.List
import kotlin.jvm.JvmName
/**
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as gitlab from "@pulumi/gitlab";
* const foo = new gitlab.Project("foo", {
* name: "example project",
* description: "Lorem Ipsum",
* visibilityLevel: "public",
* });
* const welcomeIssue = new gitlab.ProjectIssue("welcome_issue", {
* project: foo.id,
* title: "Welcome!",
* description: pulumi.interpolate` Welcome to the ${foo.name} project!
* `,
* discussionLocked: true,
* });
* export const welcomeIssueWebUrl = webUrl;
* ```
* ```python
* import pulumi
* import pulumi_gitlab as gitlab
* foo = gitlab.Project("foo",
* name="example project",
* description="Lorem Ipsum",
* visibility_level="public")
* welcome_issue = gitlab.ProjectIssue("welcome_issue",
* project=foo.id,
* title="Welcome!",
* description=foo.name.apply(lambda name: f""" Welcome to the {name} project!
* """),
* discussion_locked=True)
* pulumi.export("welcomeIssueWebUrl", web_url)
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using GitLab = Pulumi.GitLab;
* return await Deployment.RunAsync(() =>
* {
* var foo = new GitLab.Project("foo", new()
* {
* Name = "example project",
* Description = "Lorem Ipsum",
* VisibilityLevel = "public",
* });
* var welcomeIssue = new GitLab.ProjectIssue("welcome_issue", new()
* {
* Project = foo.Id,
* Title = "Welcome!",
* Description = foo.Name.Apply(name => @$" Welcome to the {name} project!
* "),
* DiscussionLocked = true,
* });
* return new Dictionary
* {
* ["welcomeIssueWebUrl"] = webUrl,
* };
* });
* ```
* ```go
* package main
* import (
* "fmt"
* "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 {
* foo, err := gitlab.NewProject(ctx, "foo", &gitlab.ProjectArgs{
* Name: pulumi.String("example project"),
* Description: pulumi.String("Lorem Ipsum"),
* VisibilityLevel: pulumi.String("public"),
* })
* if err != nil {
* return err
* }
* _, err = gitlab.NewProjectIssue(ctx, "welcome_issue", &gitlab.ProjectIssueArgs{
* Project: foo.ID(),
* Title: pulumi.String("Welcome!"),
* Description: foo.Name.ApplyT(func(name string) (string, error) {
* return fmt.Sprintf(" Welcome to the %v project!\n\n", name), nil
* }).(pulumi.StringOutput),
* DiscussionLocked: pulumi.Bool(true),
* })
* if err != nil {
* return err
* }
* ctx.Export("welcomeIssueWebUrl", webUrl)
* return nil
* })
* }
* ```
* ```java
* package generated_program;
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.gitlab.Project;
* import com.pulumi.gitlab.ProjectArgs;
* import com.pulumi.gitlab.ProjectIssue;
* import com.pulumi.gitlab.ProjectIssueArgs;
* 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 foo = new Project("foo", ProjectArgs.builder()
* .name("example project")
* .description("Lorem Ipsum")
* .visibilityLevel("public")
* .build());
* var welcomeIssue = new ProjectIssue("welcomeIssue", ProjectIssueArgs.builder()
* .project(foo.id())
* .title("Welcome!")
* .description(foo.name().applyValue(name -> """
* Welcome to the %s project!
* ", name)))
* .discussionLocked(true)
* .build());
* ctx.export("welcomeIssueWebUrl", webUrl);
* }
* }
* ```
* ```yaml
* resources:
* foo:
* type: gitlab:Project
* properties:
* name: example project
* description: Lorem Ipsum
* visibilityLevel: public
* welcomeIssue:
* type: gitlab:ProjectIssue
* name: welcome_issue
* properties:
* project: ${foo.id}
* title: Welcome!
* description: |2+
* Welcome to the ${foo.name} project!
* discussionLocked: true
* outputs:
* welcomeIssueWebUrl: ${webUrl}
* ```
*
* ## Import
* Starting in Terraform v1.5.0 you can use an import block to import `gitlab_project_issue`. For example:
* terraform
* import {
* to = gitlab_project_issue.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 `{project-id}:{issue-id}`, e.g.
* ```sh
* $ pulumi import gitlab:index/projectIssue:ProjectIssue welcome_issue 42:1
* ```
* @property assigneeIds The IDs of the users to assign the issue to.
* @property confidential Set an issue to be confidential.
* @property createdAt When the issue was created. Date time string, ISO 8601 formatted, for example 2016-03-11T03:45:40Z. Requires administrator or project/group owner rights.
* @property deleteOnDestroy Whether the issue is deleted instead of closed during destroy.
* @property description The description of an issue. Limited to 1,048,576 characters.
* @property discussionLocked Whether the issue is locked for discussions or not.
* @property discussionToResolve The ID of a discussion to resolve. This fills out the issue with a default description and mark the discussion as resolved. Use in combination with merge*request*to*resolve*discussions_of.
* @property dueDate The due date. Date time string in the format YYYY-MM-DD, for example 2016-03-11.
* @property epicIssueId The ID of the epic issue.
* @property iid The internal ID of the project's issue.
* @property issueType The type of issue. Valid values are: `issue`, `incident`, `test_case`.
* @property labels The labels of an issue.
* @property mergeRequestToResolveDiscussionsOf The IID of a merge request in which to resolve all issues. This fills out the issue with a default description and mark all discussions as resolved. When passing a description or title, these values take precedence over the default values.
* @property milestoneId The global ID of a milestone to assign issue. To find the milestone_id associated with a milestone, view an issue with the milestone assigned and use the API to retrieve the issue's details.
* @property project The name or ID of the project.
* @property state The state of the issue. Valid values are: `opened`, `closed`.
* @property title The title of the issue.
* @property updatedAt When the issue was updated. Date time string, ISO 8601 formatted, for example 2016-03-11T03:45:40Z.
* @property weight The weight of the issue. Valid values are greater than or equal to 0.
*/
public data class ProjectIssueArgs(
public val assigneeIds: Output>? = null,
public val confidential: Output? = null,
public val createdAt: Output? = null,
public val deleteOnDestroy: Output? = null,
public val description: Output? = null,
public val discussionLocked: Output? = null,
public val discussionToResolve: Output? = null,
public val dueDate: Output? = null,
public val epicIssueId: Output? = null,
public val iid: Output? = null,
public val issueType: Output? = null,
public val labels: Output>? = null,
public val mergeRequestToResolveDiscussionsOf: Output? = null,
public val milestoneId: Output? = null,
public val project: Output? = null,
public val state: Output? = null,
public val title: Output? = null,
public val updatedAt: Output? = null,
public val weight: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.gitlab.ProjectIssueArgs =
com.pulumi.gitlab.ProjectIssueArgs.builder()
.assigneeIds(assigneeIds?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
.confidential(confidential?.applyValue({ args0 -> args0 }))
.createdAt(createdAt?.applyValue({ args0 -> args0 }))
.deleteOnDestroy(deleteOnDestroy?.applyValue({ args0 -> args0 }))
.description(description?.applyValue({ args0 -> args0 }))
.discussionLocked(discussionLocked?.applyValue({ args0 -> args0 }))
.discussionToResolve(discussionToResolve?.applyValue({ args0 -> args0 }))
.dueDate(dueDate?.applyValue({ args0 -> args0 }))
.epicIssueId(epicIssueId?.applyValue({ args0 -> args0 }))
.iid(iid?.applyValue({ args0 -> args0 }))
.issueType(issueType?.applyValue({ args0 -> args0 }))
.labels(labels?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
.mergeRequestToResolveDiscussionsOf(
mergeRequestToResolveDiscussionsOf?.applyValue({ args0 ->
args0
}),
)
.milestoneId(milestoneId?.applyValue({ args0 -> args0 }))
.project(project?.applyValue({ args0 -> args0 }))
.state(state?.applyValue({ args0 -> args0 }))
.title(title?.applyValue({ args0 -> args0 }))
.updatedAt(updatedAt?.applyValue({ args0 -> args0 }))
.weight(weight?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [ProjectIssueArgs].
*/
@PulumiTagMarker
public class ProjectIssueArgsBuilder internal constructor() {
private var assigneeIds: Output>? = null
private var confidential: Output? = null
private var createdAt: Output? = null
private var deleteOnDestroy: Output? = null
private var description: Output? = null
private var discussionLocked: Output? = null
private var discussionToResolve: Output? = null
private var dueDate: Output? = null
private var epicIssueId: Output? = null
private var iid: Output? = null
private var issueType: Output? = null
private var labels: Output>? = null
private var mergeRequestToResolveDiscussionsOf: Output? = null
private var milestoneId: Output? = null
private var project: Output? = null
private var state: Output? = null
private var title: Output? = null
private var updatedAt: Output? = null
private var weight: Output? = null
/**
* @param value The IDs of the users to assign the issue to.
*/
@JvmName("sjdbvjrwcyxlfghd")
public suspend fun assigneeIds(`value`: Output>) {
this.assigneeIds = value
}
@JvmName("ujafburubtsdoreg")
public suspend fun assigneeIds(vararg values: Output) {
this.assigneeIds = Output.all(values.asList())
}
/**
* @param values The IDs of the users to assign the issue to.
*/
@JvmName("jsdqhdjgyixleuul")
public suspend fun assigneeIds(values: List
© 2015 - 2024 Weber Informatics LLC | Privacy Policy