1. Packages
  2. Gitlab Provider
  3. API Docs
  4. IntegrationJenkins
GitLab v8.4.1 published on Tuesday, Sep 24, 2024 by Pulumi

gitlab.IntegrationJenkins

Explore with Pulumi AI

gitlab logo
GitLab v8.4.1 published on Tuesday, Sep 24, 2024 by Pulumi

    The gitlab.IntegrationJenkins resource allows to manage the lifecycle of a project integration with Jenkins.

    Upstream API: GitLab REST API docs

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as gitlab from "@pulumi/gitlab";
    
    const awesomeProject = new gitlab.Project("awesome_project", {
        name: "awesome_project",
        description: "My awesome project.",
        visibilityLevel: "public",
    });
    const jenkins = new gitlab.IntegrationJenkins("jenkins", {
        project: awesomeProject.id,
        jenkinsUrl: "http://jenkins.example.com",
        projectName: "my_project_name",
    });
    
    import pulumi
    import pulumi_gitlab as gitlab
    
    awesome_project = gitlab.Project("awesome_project",
        name="awesome_project",
        description="My awesome project.",
        visibility_level="public")
    jenkins = gitlab.IntegrationJenkins("jenkins",
        project=awesome_project.id,
        jenkins_url="http://jenkins.example.com",
        project_name="my_project_name")
    
    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 {
    		awesomeProject, err := gitlab.NewProject(ctx, "awesome_project", &gitlab.ProjectArgs{
    			Name:            pulumi.String("awesome_project"),
    			Description:     pulumi.String("My awesome project."),
    			VisibilityLevel: pulumi.String("public"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = gitlab.NewIntegrationJenkins(ctx, "jenkins", &gitlab.IntegrationJenkinsArgs{
    			Project:     awesomeProject.ID(),
    			JenkinsUrl:  pulumi.String("http://jenkins.example.com"),
    			ProjectName: pulumi.String("my_project_name"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using GitLab = Pulumi.GitLab;
    
    return await Deployment.RunAsync(() => 
    {
        var awesomeProject = new GitLab.Project("awesome_project", new()
        {
            Name = "awesome_project",
            Description = "My awesome project.",
            VisibilityLevel = "public",
        });
    
        var jenkins = new GitLab.IntegrationJenkins("jenkins", new()
        {
            Project = awesomeProject.Id,
            JenkinsUrl = "http://jenkins.example.com",
            ProjectName = "my_project_name",
        });
    
    });
    
    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.IntegrationJenkins;
    import com.pulumi.gitlab.IntegrationJenkinsArgs;
    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 awesomeProject = new Project("awesomeProject", ProjectArgs.builder()
                .name("awesome_project")
                .description("My awesome project.")
                .visibilityLevel("public")
                .build());
    
            var jenkins = new IntegrationJenkins("jenkins", IntegrationJenkinsArgs.builder()
                .project(awesomeProject.id())
                .jenkinsUrl("http://jenkins.example.com")
                .projectName("my_project_name")
                .build());
    
        }
    }
    
    resources:
      awesomeProject:
        type: gitlab:Project
        name: awesome_project
        properties:
          name: awesome_project
          description: My awesome project.
          visibilityLevel: public
      jenkins:
        type: gitlab:IntegrationJenkins
        properties:
          project: ${awesomeProject.id}
          jenkinsUrl: http://jenkins.example.com
          projectName: my_project_name
    

    Create IntegrationJenkins Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new IntegrationJenkins(name: string, args: IntegrationJenkinsArgs, opts?: CustomResourceOptions);
    @overload
    def IntegrationJenkins(resource_name: str,
                           args: IntegrationJenkinsArgs,
                           opts: Optional[ResourceOptions] = None)
    
    @overload
    def IntegrationJenkins(resource_name: str,
                           opts: Optional[ResourceOptions] = None,
                           jenkins_url: Optional[str] = None,
                           project: Optional[str] = None,
                           project_name: Optional[str] = None,
                           enable_ssl_verification: Optional[bool] = None,
                           merge_request_events: Optional[bool] = None,
                           password: Optional[str] = None,
                           push_events: Optional[bool] = None,
                           tag_push_events: Optional[bool] = None,
                           username: Optional[str] = None)
    func NewIntegrationJenkins(ctx *Context, name string, args IntegrationJenkinsArgs, opts ...ResourceOption) (*IntegrationJenkins, error)
    public IntegrationJenkins(string name, IntegrationJenkinsArgs args, CustomResourceOptions? opts = null)
    public IntegrationJenkins(String name, IntegrationJenkinsArgs args)
    public IntegrationJenkins(String name, IntegrationJenkinsArgs args, CustomResourceOptions options)
    
    type: gitlab:IntegrationJenkins
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args IntegrationJenkinsArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args IntegrationJenkinsArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args IntegrationJenkinsArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args IntegrationJenkinsArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args IntegrationJenkinsArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var integrationJenkinsResource = new GitLab.IntegrationJenkins("integrationJenkinsResource", new()
    {
        JenkinsUrl = "string",
        Project = "string",
        ProjectName = "string",
        EnableSslVerification = false,
        MergeRequestEvents = false,
        Password = "string",
        PushEvents = false,
        TagPushEvents = false,
        Username = "string",
    });
    
    example, err := gitlab.NewIntegrationJenkins(ctx, "integrationJenkinsResource", &gitlab.IntegrationJenkinsArgs{
    	JenkinsUrl:            pulumi.String("string"),
    	Project:               pulumi.String("string"),
    	ProjectName:           pulumi.String("string"),
    	EnableSslVerification: pulumi.Bool(false),
    	MergeRequestEvents:    pulumi.Bool(false),
    	Password:              pulumi.String("string"),
    	PushEvents:            pulumi.Bool(false),
    	TagPushEvents:         pulumi.Bool(false),
    	Username:              pulumi.String("string"),
    })
    
    var integrationJenkinsResource = new IntegrationJenkins("integrationJenkinsResource", IntegrationJenkinsArgs.builder()
        .jenkinsUrl("string")
        .project("string")
        .projectName("string")
        .enableSslVerification(false)
        .mergeRequestEvents(false)
        .password("string")
        .pushEvents(false)
        .tagPushEvents(false)
        .username("string")
        .build());
    
    integration_jenkins_resource = gitlab.IntegrationJenkins("integrationJenkinsResource",
        jenkins_url="string",
        project="string",
        project_name="string",
        enable_ssl_verification=False,
        merge_request_events=False,
        password="string",
        push_events=False,
        tag_push_events=False,
        username="string")
    
    const integrationJenkinsResource = new gitlab.IntegrationJenkins("integrationJenkinsResource", {
        jenkinsUrl: "string",
        project: "string",
        projectName: "string",
        enableSslVerification: false,
        mergeRequestEvents: false,
        password: "string",
        pushEvents: false,
        tagPushEvents: false,
        username: "string",
    });
    
    type: gitlab:IntegrationJenkins
    properties:
        enableSslVerification: false
        jenkinsUrl: string
        mergeRequestEvents: false
        password: string
        project: string
        projectName: string
        pushEvents: false
        tagPushEvents: false
        username: string
    

    IntegrationJenkins Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The IntegrationJenkins resource accepts the following input properties:

    JenkinsUrl string
    Jenkins URL like http://jenkins.example.com
    Project string
    ID of the project you want to activate integration on.
    ProjectName string
    The URL-friendly project name. Example: my_project_name.
    EnableSslVerification bool
    Enable SSL verification. Defaults to true (enabled).
    MergeRequestEvents bool
    Enable notifications for merge request events.
    Password string
    Password for authentication with the Jenkins server, if authentication is required by the server.
    PushEvents bool
    Enable notifications for push events.
    TagPushEvents bool
    Enable notifications for tag push events.
    Username string
    Username for authentication with the Jenkins server, if authentication is required by the server.
    JenkinsUrl string
    Jenkins URL like http://jenkins.example.com
    Project string
    ID of the project you want to activate integration on.
    ProjectName string
    The URL-friendly project name. Example: my_project_name.
    EnableSslVerification bool
    Enable SSL verification. Defaults to true (enabled).
    MergeRequestEvents bool
    Enable notifications for merge request events.
    Password string
    Password for authentication with the Jenkins server, if authentication is required by the server.
    PushEvents bool
    Enable notifications for push events.
    TagPushEvents bool
    Enable notifications for tag push events.
    Username string
    Username for authentication with the Jenkins server, if authentication is required by the server.
    jenkinsUrl String
    Jenkins URL like http://jenkins.example.com
    project String
    ID of the project you want to activate integration on.
    projectName String
    The URL-friendly project name. Example: my_project_name.
    enableSslVerification Boolean
    Enable SSL verification. Defaults to true (enabled).
    mergeRequestEvents Boolean
    Enable notifications for merge request events.
    password String
    Password for authentication with the Jenkins server, if authentication is required by the server.
    pushEvents Boolean
    Enable notifications for push events.
    tagPushEvents Boolean
    Enable notifications for tag push events.
    username String
    Username for authentication with the Jenkins server, if authentication is required by the server.
    jenkinsUrl string
    Jenkins URL like http://jenkins.example.com
    project string
    ID of the project you want to activate integration on.
    projectName string
    The URL-friendly project name. Example: my_project_name.
    enableSslVerification boolean
    Enable SSL verification. Defaults to true (enabled).
    mergeRequestEvents boolean
    Enable notifications for merge request events.
    password string
    Password for authentication with the Jenkins server, if authentication is required by the server.
    pushEvents boolean
    Enable notifications for push events.
    tagPushEvents boolean
    Enable notifications for tag push events.
    username string
    Username for authentication with the Jenkins server, if authentication is required by the server.
    jenkins_url str
    Jenkins URL like http://jenkins.example.com
    project str
    ID of the project you want to activate integration on.
    project_name str
    The URL-friendly project name. Example: my_project_name.
    enable_ssl_verification bool
    Enable SSL verification. Defaults to true (enabled).
    merge_request_events bool
    Enable notifications for merge request events.
    password str
    Password for authentication with the Jenkins server, if authentication is required by the server.
    push_events bool
    Enable notifications for push events.
    tag_push_events bool
    Enable notifications for tag push events.
    username str
    Username for authentication with the Jenkins server, if authentication is required by the server.
    jenkinsUrl String
    Jenkins URL like http://jenkins.example.com
    project String
    ID of the project you want to activate integration on.
    projectName String
    The URL-friendly project name. Example: my_project_name.
    enableSslVerification Boolean
    Enable SSL verification. Defaults to true (enabled).
    mergeRequestEvents Boolean
    Enable notifications for merge request events.
    password String
    Password for authentication with the Jenkins server, if authentication is required by the server.
    pushEvents Boolean
    Enable notifications for push events.
    tagPushEvents Boolean
    Enable notifications for tag push events.
    username String
    Username for authentication with the Jenkins server, if authentication is required by the server.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the IntegrationJenkins resource produces the following output properties:

    Active bool
    Whether the integration is active.
    Id string
    The provider-assigned unique ID for this managed resource.
    Active bool
    Whether the integration is active.
    Id string
    The provider-assigned unique ID for this managed resource.
    active Boolean
    Whether the integration is active.
    id String
    The provider-assigned unique ID for this managed resource.
    active boolean
    Whether the integration is active.
    id string
    The provider-assigned unique ID for this managed resource.
    active bool
    Whether the integration is active.
    id str
    The provider-assigned unique ID for this managed resource.
    active Boolean
    Whether the integration is active.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing IntegrationJenkins Resource

    Get an existing IntegrationJenkins resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: IntegrationJenkinsState, opts?: CustomResourceOptions): IntegrationJenkins
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            active: Optional[bool] = None,
            enable_ssl_verification: Optional[bool] = None,
            jenkins_url: Optional[str] = None,
            merge_request_events: Optional[bool] = None,
            password: Optional[str] = None,
            project: Optional[str] = None,
            project_name: Optional[str] = None,
            push_events: Optional[bool] = None,
            tag_push_events: Optional[bool] = None,
            username: Optional[str] = None) -> IntegrationJenkins
    func GetIntegrationJenkins(ctx *Context, name string, id IDInput, state *IntegrationJenkinsState, opts ...ResourceOption) (*IntegrationJenkins, error)
    public static IntegrationJenkins Get(string name, Input<string> id, IntegrationJenkinsState? state, CustomResourceOptions? opts = null)
    public static IntegrationJenkins get(String name, Output<String> id, IntegrationJenkinsState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Active bool
    Whether the integration is active.
    EnableSslVerification bool
    Enable SSL verification. Defaults to true (enabled).
    JenkinsUrl string
    Jenkins URL like http://jenkins.example.com
    MergeRequestEvents bool
    Enable notifications for merge request events.
    Password string
    Password for authentication with the Jenkins server, if authentication is required by the server.
    Project string
    ID of the project you want to activate integration on.
    ProjectName string
    The URL-friendly project name. Example: my_project_name.
    PushEvents bool
    Enable notifications for push events.
    TagPushEvents bool
    Enable notifications for tag push events.
    Username string
    Username for authentication with the Jenkins server, if authentication is required by the server.
    Active bool
    Whether the integration is active.
    EnableSslVerification bool
    Enable SSL verification. Defaults to true (enabled).
    JenkinsUrl string
    Jenkins URL like http://jenkins.example.com
    MergeRequestEvents bool
    Enable notifications for merge request events.
    Password string
    Password for authentication with the Jenkins server, if authentication is required by the server.
    Project string
    ID of the project you want to activate integration on.
    ProjectName string
    The URL-friendly project name. Example: my_project_name.
    PushEvents bool
    Enable notifications for push events.
    TagPushEvents bool
    Enable notifications for tag push events.
    Username string
    Username for authentication with the Jenkins server, if authentication is required by the server.
    active Boolean
    Whether the integration is active.
    enableSslVerification Boolean
    Enable SSL verification. Defaults to true (enabled).
    jenkinsUrl String
    Jenkins URL like http://jenkins.example.com
    mergeRequestEvents Boolean
    Enable notifications for merge request events.
    password String
    Password for authentication with the Jenkins server, if authentication is required by the server.
    project String
    ID of the project you want to activate integration on.
    projectName String
    The URL-friendly project name. Example: my_project_name.
    pushEvents Boolean
    Enable notifications for push events.
    tagPushEvents Boolean
    Enable notifications for tag push events.
    username String
    Username for authentication with the Jenkins server, if authentication is required by the server.
    active boolean
    Whether the integration is active.
    enableSslVerification boolean
    Enable SSL verification. Defaults to true (enabled).
    jenkinsUrl string
    Jenkins URL like http://jenkins.example.com
    mergeRequestEvents boolean
    Enable notifications for merge request events.
    password string
    Password for authentication with the Jenkins server, if authentication is required by the server.
    project string
    ID of the project you want to activate integration on.
    projectName string
    The URL-friendly project name. Example: my_project_name.
    pushEvents boolean
    Enable notifications for push events.
    tagPushEvents boolean
    Enable notifications for tag push events.
    username string
    Username for authentication with the Jenkins server, if authentication is required by the server.
    active bool
    Whether the integration is active.
    enable_ssl_verification bool
    Enable SSL verification. Defaults to true (enabled).
    jenkins_url str
    Jenkins URL like http://jenkins.example.com
    merge_request_events bool
    Enable notifications for merge request events.
    password str
    Password for authentication with the Jenkins server, if authentication is required by the server.
    project str
    ID of the project you want to activate integration on.
    project_name str
    The URL-friendly project name. Example: my_project_name.
    push_events bool
    Enable notifications for push events.
    tag_push_events bool
    Enable notifications for tag push events.
    username str
    Username for authentication with the Jenkins server, if authentication is required by the server.
    active Boolean
    Whether the integration is active.
    enableSslVerification Boolean
    Enable SSL verification. Defaults to true (enabled).
    jenkinsUrl String
    Jenkins URL like http://jenkins.example.com
    mergeRequestEvents Boolean
    Enable notifications for merge request events.
    password String
    Password for authentication with the Jenkins server, if authentication is required by the server.
    project String
    ID of the project you want to activate integration on.
    projectName String
    The URL-friendly project name. Example: my_project_name.
    pushEvents Boolean
    Enable notifications for push events.
    tagPushEvents Boolean
    Enable notifications for tag push events.
    username String
    Username for authentication with the Jenkins server, if authentication is required by the server.

    Import

    $ pulumi import gitlab:index/integrationJenkins:IntegrationJenkins You can import a gitlab_integration_jenkins state using `<resource> <project_id>`:
    
    $ pulumi import gitlab:index/integrationJenkins:IntegrationJenkins jenkins 1
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    GitLab pulumi/pulumi-gitlab
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the gitlab Terraform Provider.
    gitlab logo
    GitLab v8.4.1 published on Tuesday, Sep 24, 2024 by Pulumi