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

gitlab.getRelease

Explore with Pulumi AI

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

    The gitlab.getRelease data source retrieves information about a gitlab release for a project.

    Upstream API: GitLab REST API docs

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as gitlab from "@pulumi/gitlab";
    
    // By project ID and tag_name
    const example = gitlab.getRelease({
        projectId: "1234",
        tagName: "v1.0",
    });
    
    import pulumi
    import pulumi_gitlab as gitlab
    
    # By project ID and tag_name
    example = gitlab.get_release(project_id="1234",
        tag_name="v1.0")
    
    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 {
    		// By project ID and tag_name
    		_, err := gitlab.GetRelease(ctx, &gitlab.GetReleaseArgs{
    			ProjectId: "1234",
    			TagName:   "v1.0",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using GitLab = Pulumi.GitLab;
    
    return await Deployment.RunAsync(() => 
    {
        // By project ID and tag_name
        var example = GitLab.GetRelease.Invoke(new()
        {
            ProjectId = "1234",
            TagName = "v1.0",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.gitlab.GitlabFunctions;
    import com.pulumi.gitlab.inputs.GetReleaseArgs;
    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) {
            // By project ID and tag_name
            final var example = GitlabFunctions.getRelease(GetReleaseArgs.builder()
                .projectId(1234)
                .tagName("v1.0")
                .build());
    
        }
    }
    
    variables:
      # By project ID and tag_name
      example:
        fn::invoke:
          Function: gitlab:getRelease
          Arguments:
            projectId: 1234
            tagName: v1.0
    

    Using getRelease

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getRelease(args: GetReleaseArgs, opts?: InvokeOptions): Promise<GetReleaseResult>
    function getReleaseOutput(args: GetReleaseOutputArgs, opts?: InvokeOptions): Output<GetReleaseResult>
    def get_release(assets: Optional[GetReleaseAssets] = None,
                    project_id: Optional[str] = None,
                    tag_name: Optional[str] = None,
                    opts: Optional[InvokeOptions] = None) -> GetReleaseResult
    def get_release_output(assets: Optional[pulumi.Input[GetReleaseAssetsArgs]] = None,
                    project_id: Optional[pulumi.Input[str]] = None,
                    tag_name: Optional[pulumi.Input[str]] = None,
                    opts: Optional[InvokeOptions] = None) -> Output[GetReleaseResult]
    func GetRelease(ctx *Context, args *GetReleaseArgs, opts ...InvokeOption) (*GetReleaseResult, error)
    func GetReleaseOutput(ctx *Context, args *GetReleaseOutputArgs, opts ...InvokeOption) GetReleaseResultOutput

    > Note: This function is named GetRelease in the Go SDK.

    public static class GetRelease 
    {
        public static Task<GetReleaseResult> InvokeAsync(GetReleaseArgs args, InvokeOptions? opts = null)
        public static Output<GetReleaseResult> Invoke(GetReleaseInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetReleaseResult> getRelease(GetReleaseArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: gitlab:index/getRelease:getRelease
      arguments:
        # arguments dictionary

    The following arguments are supported:

    ProjectId string
    The ID or URL-encoded path of the project.
    TagName string
    The Git tag the release is associated with.
    Assets Pulumi.GitLab.Inputs.GetReleaseAssets
    The assets for a release
    ProjectId string
    The ID or URL-encoded path of the project.
    TagName string
    The Git tag the release is associated with.
    Assets GetReleaseAssets
    The assets for a release
    projectId String
    The ID or URL-encoded path of the project.
    tagName String
    The Git tag the release is associated with.
    assets GetReleaseAssets
    The assets for a release
    projectId string
    The ID or URL-encoded path of the project.
    tagName string
    The Git tag the release is associated with.
    assets GetReleaseAssets
    The assets for a release
    project_id str
    The ID or URL-encoded path of the project.
    tag_name str
    The Git tag the release is associated with.
    assets GetReleaseAssets
    The assets for a release
    projectId String
    The ID or URL-encoded path of the project.
    tagName String
    The Git tag the release is associated with.
    assets Property Map
    The assets for a release

    getRelease Result

    The following output properties are available:

    CreatedAt string
    The date the release was created.
    Description string
    An HTML rendered description of the release.
    Id string
    Name string
    The name of the release.
    ProjectId string
    The ID or URL-encoded path of the project.
    ReleasedAt string
    The date the release was created.
    TagName string
    The Git tag the release is associated with.
    Assets Pulumi.GitLab.Outputs.GetReleaseAssets
    The assets for a release
    CreatedAt string
    The date the release was created.
    Description string
    An HTML rendered description of the release.
    Id string
    Name string
    The name of the release.
    ProjectId string
    The ID or URL-encoded path of the project.
    ReleasedAt string
    The date the release was created.
    TagName string
    The Git tag the release is associated with.
    Assets GetReleaseAssets
    The assets for a release
    createdAt String
    The date the release was created.
    description String
    An HTML rendered description of the release.
    id String
    name String
    The name of the release.
    projectId String
    The ID or URL-encoded path of the project.
    releasedAt String
    The date the release was created.
    tagName String
    The Git tag the release is associated with.
    assets GetReleaseAssets
    The assets for a release
    createdAt string
    The date the release was created.
    description string
    An HTML rendered description of the release.
    id string
    name string
    The name of the release.
    projectId string
    The ID or URL-encoded path of the project.
    releasedAt string
    The date the release was created.
    tagName string
    The Git tag the release is associated with.
    assets GetReleaseAssets
    The assets for a release
    created_at str
    The date the release was created.
    description str
    An HTML rendered description of the release.
    id str
    name str
    The name of the release.
    project_id str
    The ID or URL-encoded path of the project.
    released_at str
    The date the release was created.
    tag_name str
    The Git tag the release is associated with.
    assets GetReleaseAssets
    The assets for a release
    createdAt String
    The date the release was created.
    description String
    An HTML rendered description of the release.
    id String
    name String
    The name of the release.
    projectId String
    The ID or URL-encoded path of the project.
    releasedAt String
    The date the release was created.
    tagName String
    The Git tag the release is associated with.
    assets Property Map
    The assets for a release

    Supporting Types

    GetReleaseAssets

    Count int
    The number of assets for a release
    Links List<Pulumi.GitLab.Inputs.GetReleaseAssetsLink>
    The links for a release
    Sources List<Pulumi.GitLab.Inputs.GetReleaseAssetsSource>
    The sources for a release
    Count int
    The number of assets for a release
    Links []GetReleaseAssetsLink
    The links for a release
    Sources []GetReleaseAssetsSource
    The sources for a release
    count Integer
    The number of assets for a release
    links List<GetReleaseAssetsLink>
    The links for a release
    sources List<GetReleaseAssetsSource>
    The sources for a release
    count number
    The number of assets for a release
    links GetReleaseAssetsLink[]
    The links for a release
    sources GetReleaseAssetsSource[]
    The sources for a release
    count int
    The number of assets for a release
    links Sequence[GetReleaseAssetsLink]
    The links for a release
    sources Sequence[GetReleaseAssetsSource]
    The sources for a release
    count Number
    The number of assets for a release
    links List<Property Map>
    The links for a release
    sources List<Property Map>
    The sources for a release
    Id int
    The ID of the link
    LinkType string
    The type of the link
    Name string
    The name of the link
    Url string
    The URL of the link
    Id int
    The ID of the link
    LinkType string
    The type of the link
    Name string
    The name of the link
    Url string
    The URL of the link
    id Integer
    The ID of the link
    linkType String
    The type of the link
    name String
    The name of the link
    url String
    The URL of the link
    id number
    The ID of the link
    linkType string
    The type of the link
    name string
    The name of the link
    url string
    The URL of the link
    id int
    The ID of the link
    link_type str
    The type of the link
    name str
    The name of the link
    url str
    The URL of the link
    id Number
    The ID of the link
    linkType String
    The type of the link
    name String
    The name of the link
    url String
    The URL of the link

    GetReleaseAssetsSource

    Format string
    The format of the source
    Url string
    The URL of the source
    Format string
    The format of the source
    Url string
    The URL of the source
    format String
    The format of the source
    url String
    The URL of the source
    format string
    The format of the source
    url string
    The URL of the source
    format str
    The format of the source
    url str
    The URL of the source
    format String
    The format of the source
    url String
    The URL of the source

    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