com.pulumi.gitlab.kotlin.GroupHookArgs.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.GroupHookArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.jvm.JvmName
/**
* The `gitlab.GroupHook` resource allows to manage the lifecycle of a group hook.
* **Upstream API**: [GitLab REST API docs](https://docs.gitlab.com/ee/api/groups.html#hooks)
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as gitlab from "@pulumi/gitlab";
* const example = new gitlab.GroupHook("example", {
* group: "example/hooked",
* url: "https://example.com/hook/example",
* mergeRequestsEvents: true,
* });
* // Setting all attributes
* const allAttributes = new gitlab.GroupHook("all_attributes", {
* group: "1",
* url: "http://example.com",
* token: "supersecret",
* enableSslVerification: false,
* pushEvents: true,
* pushEventsBranchFilter: "devel",
* issuesEvents: false,
* confidentialIssuesEvents: false,
* mergeRequestsEvents: true,
* tagPushEvents: true,
* noteEvents: true,
* confidentialNoteEvents: true,
* jobEvents: true,
* pipelineEvents: true,
* wikiPageEvents: true,
* deploymentEvents: true,
* releasesEvents: true,
* subgroupEvents: true,
* });
* ```
* ```python
* import pulumi
* import pulumi_gitlab as gitlab
* example = gitlab.GroupHook("example",
* group="example/hooked",
* url="https://example.com/hook/example",
* merge_requests_events=True)
* # Setting all attributes
* all_attributes = gitlab.GroupHook("all_attributes",
* group="1",
* url="http://example.com",
* token="supersecret",
* enable_ssl_verification=False,
* push_events=True,
* push_events_branch_filter="devel",
* issues_events=False,
* confidential_issues_events=False,
* merge_requests_events=True,
* tag_push_events=True,
* note_events=True,
* confidential_note_events=True,
* job_events=True,
* pipeline_events=True,
* wiki_page_events=True,
* deployment_events=True,
* releases_events=True,
* subgroup_events=True)
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using GitLab = Pulumi.GitLab;
* return await Deployment.RunAsync(() =>
* {
* var example = new GitLab.GroupHook("example", new()
* {
* Group = "example/hooked",
* Url = "https://example.com/hook/example",
* MergeRequestsEvents = true,
* });
* // Setting all attributes
* var allAttributes = new GitLab.GroupHook("all_attributes", new()
* {
* Group = "1",
* Url = "http://example.com",
* Token = "supersecret",
* EnableSslVerification = false,
* PushEvents = true,
* PushEventsBranchFilter = "devel",
* IssuesEvents = false,
* ConfidentialIssuesEvents = false,
* MergeRequestsEvents = true,
* TagPushEvents = true,
* NoteEvents = true,
* ConfidentialNoteEvents = true,
* JobEvents = true,
* PipelineEvents = true,
* WikiPageEvents = true,
* DeploymentEvents = true,
* ReleasesEvents = true,
* SubgroupEvents = true,
* });
* });
* ```
* ```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 {
* _, err := gitlab.NewGroupHook(ctx, "example", &gitlab.GroupHookArgs{
* Group: pulumi.String("example/hooked"),
* Url: pulumi.String("https://example.com/hook/example"),
* MergeRequestsEvents: pulumi.Bool(true),
* })
* if err != nil {
* return err
* }
* // Setting all attributes
* _, err = gitlab.NewGroupHook(ctx, "all_attributes", &gitlab.GroupHookArgs{
* Group: pulumi.String("1"),
* Url: pulumi.String("http://example.com"),
* Token: pulumi.String("supersecret"),
* EnableSslVerification: pulumi.Bool(false),
* PushEvents: pulumi.Bool(true),
* PushEventsBranchFilter: pulumi.String("devel"),
* IssuesEvents: pulumi.Bool(false),
* ConfidentialIssuesEvents: pulumi.Bool(false),
* MergeRequestsEvents: pulumi.Bool(true),
* TagPushEvents: pulumi.Bool(true),
* NoteEvents: pulumi.Bool(true),
* ConfidentialNoteEvents: pulumi.Bool(true),
* JobEvents: pulumi.Bool(true),
* PipelineEvents: pulumi.Bool(true),
* WikiPageEvents: pulumi.Bool(true),
* DeploymentEvents: pulumi.Bool(true),
* ReleasesEvents: pulumi.Bool(true),
* SubgroupEvents: pulumi.Bool(true),
* })
* 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.GroupHook;
* import com.pulumi.gitlab.GroupHookArgs;
* 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 GroupHook("example", GroupHookArgs.builder()
* .group("example/hooked")
* .url("https://example.com/hook/example")
* .mergeRequestsEvents(true)
* .build());
* // Setting all attributes
* var allAttributes = new GroupHook("allAttributes", GroupHookArgs.builder()
* .group(1)
* .url("http://example.com")
* .token("supersecret")
* .enableSslVerification(false)
* .pushEvents(true)
* .pushEventsBranchFilter("devel")
* .issuesEvents(false)
* .confidentialIssuesEvents(false)
* .mergeRequestsEvents(true)
* .tagPushEvents(true)
* .noteEvents(true)
* .confidentialNoteEvents(true)
* .jobEvents(true)
* .pipelineEvents(true)
* .wikiPageEvents(true)
* .deploymentEvents(true)
* .releasesEvents(true)
* .subgroupEvents(true)
* .build());
* }
* }
* ```
* ```yaml
* resources:
* example:
* type: gitlab:GroupHook
* properties:
* group: example/hooked
* url: https://example.com/hook/example
* mergeRequestsEvents: true
* # Setting all attributes
* allAttributes:
* type: gitlab:GroupHook
* name: all_attributes
* properties:
* group: 1
* url: http://example.com
* token: supersecret
* enableSslVerification: false
* pushEvents: true
* pushEventsBranchFilter: devel
* issuesEvents: false
* confidentialIssuesEvents: false
* mergeRequestsEvents: true
* tagPushEvents: true
* noteEvents: true
* confidentialNoteEvents: true
* jobEvents: true
* pipelineEvents: true
* wikiPageEvents: true
* deploymentEvents: true
* releasesEvents: true
* subgroupEvents: true
* ```
*
* ## Import
* A GitLab Group Hook can be imported using a key composed of `:`, e.g.
* ```sh
* $ pulumi import gitlab:index/groupHook:GroupHook example "12345:1"
* ```
* NOTE: the `token` resource attribute is not available for imported resources as this information cannot be read from the GitLab API.
* @property confidentialIssuesEvents Invoke the hook for confidential issues events.
* @property confidentialNoteEvents Invoke the hook for confidential notes events.
* @property customWebhookTemplate Set a custom webhook template.
* @property deploymentEvents Invoke the hook for deployment events.
* @property enableSslVerification Enable ssl verification when invoking the hook.
* @property group The ID or full path of the group.
* @property issuesEvents Invoke the hook for issues events.
* @property jobEvents Invoke the hook for job events.
* @property mergeRequestsEvents Invoke the hook for merge requests.
* @property noteEvents Invoke the hook for notes events.
* @property pipelineEvents Invoke the hook for pipeline events.
* @property pushEvents Invoke the hook for push events.
* @property pushEventsBranchFilter Invoke the hook for push events on matching branches only.
* @property releasesEvents Invoke the hook for releases events.
* @property subgroupEvents Invoke the hook for subgroup events.
* @property tagPushEvents Invoke the hook for tag push events.
* @property token A token to present when invoking the hook. The token is not available for imported resources.
* @property url The url of the hook to invoke.
* @property wikiPageEvents Invoke the hook for wiki page events.
*/
public data class GroupHookArgs(
public val confidentialIssuesEvents: Output? = null,
public val confidentialNoteEvents: Output? = null,
public val customWebhookTemplate: Output? = null,
public val deploymentEvents: Output? = null,
public val enableSslVerification: Output? = null,
public val group: Output? = null,
public val issuesEvents: Output? = null,
public val jobEvents: Output? = null,
public val mergeRequestsEvents: Output? = null,
public val noteEvents: Output? = null,
public val pipelineEvents: Output? = null,
public val pushEvents: Output? = null,
public val pushEventsBranchFilter: Output? = null,
public val releasesEvents: Output? = null,
public val subgroupEvents: Output? = null,
public val tagPushEvents: Output? = null,
public val token: Output? = null,
public val url: Output? = null,
public val wikiPageEvents: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.gitlab.GroupHookArgs = com.pulumi.gitlab.GroupHookArgs.builder()
.confidentialIssuesEvents(confidentialIssuesEvents?.applyValue({ args0 -> args0 }))
.confidentialNoteEvents(confidentialNoteEvents?.applyValue({ args0 -> args0 }))
.customWebhookTemplate(customWebhookTemplate?.applyValue({ args0 -> args0 }))
.deploymentEvents(deploymentEvents?.applyValue({ args0 -> args0 }))
.enableSslVerification(enableSslVerification?.applyValue({ args0 -> args0 }))
.group(group?.applyValue({ args0 -> args0 }))
.issuesEvents(issuesEvents?.applyValue({ args0 -> args0 }))
.jobEvents(jobEvents?.applyValue({ args0 -> args0 }))
.mergeRequestsEvents(mergeRequestsEvents?.applyValue({ args0 -> args0 }))
.noteEvents(noteEvents?.applyValue({ args0 -> args0 }))
.pipelineEvents(pipelineEvents?.applyValue({ args0 -> args0 }))
.pushEvents(pushEvents?.applyValue({ args0 -> args0 }))
.pushEventsBranchFilter(pushEventsBranchFilter?.applyValue({ args0 -> args0 }))
.releasesEvents(releasesEvents?.applyValue({ args0 -> args0 }))
.subgroupEvents(subgroupEvents?.applyValue({ args0 -> args0 }))
.tagPushEvents(tagPushEvents?.applyValue({ args0 -> args0 }))
.token(token?.applyValue({ args0 -> args0 }))
.url(url?.applyValue({ args0 -> args0 }))
.wikiPageEvents(wikiPageEvents?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [GroupHookArgs].
*/
@PulumiTagMarker
public class GroupHookArgsBuilder internal constructor() {
private var confidentialIssuesEvents: Output? = null
private var confidentialNoteEvents: Output? = null
private var customWebhookTemplate: Output? = null
private var deploymentEvents: Output? = null
private var enableSslVerification: Output? = null
private var group: Output? = null
private var issuesEvents: Output? = null
private var jobEvents: Output? = null
private var mergeRequestsEvents: Output? = null
private var noteEvents: Output? = null
private var pipelineEvents: Output? = null
private var pushEvents: Output? = null
private var pushEventsBranchFilter: Output? = null
private var releasesEvents: Output? = null
private var subgroupEvents: Output? = null
private var tagPushEvents: Output? = null
private var token: Output? = null
private var url: Output? = null
private var wikiPageEvents: Output? = null
/**
* @param value Invoke the hook for confidential issues events.
*/
@JvmName("baytjuvifbmpmqxo")
public suspend fun confidentialIssuesEvents(`value`: Output) {
this.confidentialIssuesEvents = value
}
/**
* @param value Invoke the hook for confidential notes events.
*/
@JvmName("rsmbjfobcexiupei")
public suspend fun confidentialNoteEvents(`value`: Output) {
this.confidentialNoteEvents = value
}
/**
* @param value Set a custom webhook template.
*/
@JvmName("bcghqgwvrcgfnxfa")
public suspend fun customWebhookTemplate(`value`: Output) {
this.customWebhookTemplate = value
}
/**
* @param value Invoke the hook for deployment events.
*/
@JvmName("utruuhfkqpgvkfky")
public suspend fun deploymentEvents(`value`: Output) {
this.deploymentEvents = value
}
/**
* @param value Enable ssl verification when invoking the hook.
*/
@JvmName("ohxxtkcweuxytrcp")
public suspend fun enableSslVerification(`value`: Output) {
this.enableSslVerification = value
}
/**
* @param value The ID or full path of the group.
*/
@JvmName("dbcebhfnypodevla")
public suspend fun group(`value`: Output) {
this.group = value
}
/**
* @param value Invoke the hook for issues events.
*/
@JvmName("logytotnabrbllkm")
public suspend fun issuesEvents(`value`: Output) {
this.issuesEvents = value
}
/**
* @param value Invoke the hook for job events.
*/
@JvmName("iybfmamvxeotrncl")
public suspend fun jobEvents(`value`: Output) {
this.jobEvents = value
}
/**
* @param value Invoke the hook for merge requests.
*/
@JvmName("xgkrnnbwbsliwgmw")
public suspend fun mergeRequestsEvents(`value`: Output) {
this.mergeRequestsEvents = value
}
/**
* @param value Invoke the hook for notes events.
*/
@JvmName("ygjpxdngyasfhkbp")
public suspend fun noteEvents(`value`: Output) {
this.noteEvents = value
}
/**
* @param value Invoke the hook for pipeline events.
*/
@JvmName("wogmgvjkcaruargi")
public suspend fun pipelineEvents(`value`: Output) {
this.pipelineEvents = value
}
/**
* @param value Invoke the hook for push events.
*/
@JvmName("haiumhcyhvqqigks")
public suspend fun pushEvents(`value`: Output) {
this.pushEvents = value
}
/**
* @param value Invoke the hook for push events on matching branches only.
*/
@JvmName("gkmfthmphmcthatf")
public suspend fun pushEventsBranchFilter(`value`: Output) {
this.pushEventsBranchFilter = value
}
/**
* @param value Invoke the hook for releases events.
*/
@JvmName("bclnlprhqxdjbkie")
public suspend fun releasesEvents(`value`: Output) {
this.releasesEvents = value
}
/**
* @param value Invoke the hook for subgroup events.
*/
@JvmName("mkepnnphtuqxerkw")
public suspend fun subgroupEvents(`value`: Output) {
this.subgroupEvents = value
}
/**
* @param value Invoke the hook for tag push events.
*/
@JvmName("olubotbiyqykodxi")
public suspend fun tagPushEvents(`value`: Output) {
this.tagPushEvents = value
}
/**
* @param value A token to present when invoking the hook. The token is not available for imported resources.
*/
@JvmName("qsganibxwvgjedxp")
public suspend fun token(`value`: Output) {
this.token = value
}
/**
* @param value The url of the hook to invoke.
*/
@JvmName("vbkwnnjiptqulyus")
public suspend fun url(`value`: Output) {
this.url = value
}
/**
* @param value Invoke the hook for wiki page events.
*/
@JvmName("odgcmtdloixcrhgt")
public suspend fun wikiPageEvents(`value`: Output) {
this.wikiPageEvents = value
}
/**
* @param value Invoke the hook for confidential issues events.
*/
@JvmName("aaqnmauafdkicylj")
public suspend fun confidentialIssuesEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.confidentialIssuesEvents = mapped
}
/**
* @param value Invoke the hook for confidential notes events.
*/
@JvmName("irtfqclwlmuinlsf")
public suspend fun confidentialNoteEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.confidentialNoteEvents = mapped
}
/**
* @param value Set a custom webhook template.
*/
@JvmName("oujdgecqqekhhioe")
public suspend fun customWebhookTemplate(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.customWebhookTemplate = mapped
}
/**
* @param value Invoke the hook for deployment events.
*/
@JvmName("qhdqutfyltejaxpm")
public suspend fun deploymentEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.deploymentEvents = mapped
}
/**
* @param value Enable ssl verification when invoking the hook.
*/
@JvmName("lwcslvxjxnamtnuk")
public suspend fun enableSslVerification(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.enableSslVerification = mapped
}
/**
* @param value The ID or full path of the group.
*/
@JvmName("neqlehddflceqxiq")
public suspend fun group(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.group = mapped
}
/**
* @param value Invoke the hook for issues events.
*/
@JvmName("quhmrmjptdrewxan")
public suspend fun issuesEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.issuesEvents = mapped
}
/**
* @param value Invoke the hook for job events.
*/
@JvmName("tfbtbgvdvgtbuabk")
public suspend fun jobEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.jobEvents = mapped
}
/**
* @param value Invoke the hook for merge requests.
*/
@JvmName("asobilfookrqlifg")
public suspend fun mergeRequestsEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.mergeRequestsEvents = mapped
}
/**
* @param value Invoke the hook for notes events.
*/
@JvmName("yyjddbltknchbbkg")
public suspend fun noteEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.noteEvents = mapped
}
/**
* @param value Invoke the hook for pipeline events.
*/
@JvmName("cbvfdogsoacslbtw")
public suspend fun pipelineEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.pipelineEvents = mapped
}
/**
* @param value Invoke the hook for push events.
*/
@JvmName("wpyhvksfardrinbj")
public suspend fun pushEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.pushEvents = mapped
}
/**
* @param value Invoke the hook for push events on matching branches only.
*/
@JvmName("icmckwjnbcwdkchg")
public suspend fun pushEventsBranchFilter(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.pushEventsBranchFilter = mapped
}
/**
* @param value Invoke the hook for releases events.
*/
@JvmName("nmmteinwxsnrxqua")
public suspend fun releasesEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.releasesEvents = mapped
}
/**
* @param value Invoke the hook for subgroup events.
*/
@JvmName("acuinflwhpovjeuc")
public suspend fun subgroupEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.subgroupEvents = mapped
}
/**
* @param value Invoke the hook for tag push events.
*/
@JvmName("jextaqmtfwjwwcur")
public suspend fun tagPushEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.tagPushEvents = mapped
}
/**
* @param value A token to present when invoking the hook. The token is not available for imported resources.
*/
@JvmName("pqyebcyjoassqiyd")
public suspend fun token(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.token = mapped
}
/**
* @param value The url of the hook to invoke.
*/
@JvmName("mrlqcdsaogfdgjfw")
public suspend fun url(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.url = mapped
}
/**
* @param value Invoke the hook for wiki page events.
*/
@JvmName("vutfgsccuiraxhne")
public suspend fun wikiPageEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.wikiPageEvents = mapped
}
internal fun build(): GroupHookArgs = GroupHookArgs(
confidentialIssuesEvents = confidentialIssuesEvents,
confidentialNoteEvents = confidentialNoteEvents,
customWebhookTemplate = customWebhookTemplate,
deploymentEvents = deploymentEvents,
enableSslVerification = enableSslVerification,
group = group,
issuesEvents = issuesEvents,
jobEvents = jobEvents,
mergeRequestsEvents = mergeRequestsEvents,
noteEvents = noteEvents,
pipelineEvents = pipelineEvents,
pushEvents = pushEvents,
pushEventsBranchFilter = pushEventsBranchFilter,
releasesEvents = releasesEvents,
subgroupEvents = subgroupEvents,
tagPushEvents = tagPushEvents,
token = token,
url = url,
wikiPageEvents = wikiPageEvents,
)
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy