GitLab v8.11.0 published on Friday, Apr 18, 2025 by Pulumi
gitlab.getRelease
Explore with Pulumi AI
The gitlab.Release 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.LookupRelease(ctx, &gitlab.LookupReleaseArgs{
			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 LookupRelease(ctx *Context, args *LookupReleaseArgs, opts ...InvokeOption) (*LookupReleaseResult, error)
func LookupReleaseOutput(ctx *Context, args *LookupReleaseOutputArgs, opts ...InvokeOption) LookupReleaseResultOutput> Note: This function is named LookupRelease 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)
public static Output<GetReleaseResult> getRelease(GetReleaseArgs args, InvokeOptions options)
fn::invoke:
  function: gitlab:index/getRelease:getRelease
  arguments:
    # arguments dictionaryThe following arguments are supported:
- Project
Id string - The ID or URL-encoded path of the project.
 - Tag
Name string - The Git tag the release is associated with.
 - Assets
Pulumi.
Git Lab. Inputs. Get Release Assets  - The assets for a release
 
- Project
Id string - The ID or URL-encoded path of the project.
 - Tag
Name string - The Git tag the release is associated with.
 - Assets
Get
Release Assets  - The assets for a release
 
- project
Id String - The ID or URL-encoded path of the project.
 - tag
Name String - The Git tag the release is associated with.
 - assets
Get
Release Assets  - The assets for a release
 
- project
Id string - The ID or URL-encoded path of the project.
 - tag
Name string - The Git tag the release is associated with.
 - assets
Get
Release Assets  - 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
Get
Release Assets  - The assets for a release
 
- project
Id String - The ID or URL-encoded path of the project.
 - tag
Name 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:
- Created
At 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.
 - Project
Id string - The ID or URL-encoded path of the project.
 - Released
At string - The date the release was created.
 - Tag
Name string - The Git tag the release is associated with.
 - Assets
Pulumi.
Git Lab. Outputs. Get Release Assets  - The assets for a release
 
- Created
At 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.
 - Project
Id string - The ID or URL-encoded path of the project.
 - Released
At string - The date the release was created.
 - Tag
Name string - The Git tag the release is associated with.
 - Assets
Get
Release Assets  - The assets for a release
 
- created
At 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.
 - project
Id String - The ID or URL-encoded path of the project.
 - released
At String - The date the release was created.
 - tag
Name String - The Git tag the release is associated with.
 - assets
Get
Release Assets  - The assets for a release
 
- created
At 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.
 - project
Id string - The ID or URL-encoded path of the project.
 - released
At string - The date the release was created.
 - tag
Name string - The Git tag the release is associated with.
 - assets
Get
Release Assets  - 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
Get
Release Assets  - The assets for a release
 
- created
At 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.
 - project
Id String - The ID or URL-encoded path of the project.
 - released
At String - The date the release was created.
 - tag
Name 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.
Git Lab. Inputs. Get Release Assets Link>  - The links for a release
 - Sources
List<Pulumi.
Git Lab. Inputs. Get Release Assets Source>  - The sources for a release
 
- Count int
 - The number of assets for a release
 - Links
[]Get
Release Assets Link  - The links for a release
 - Sources
[]Get
Release Assets Source  - The sources for a release
 
- count Integer
 - The number of assets for a release
 - links
List<Get
Release Assets Link>  - The links for a release
 - sources
List<Get
Release Assets Source>  - The sources for a release
 
- count number
 - The number of assets for a release
 - links
Get
Release Assets Link[]  - The links for a release
 - sources
Get
Release Assets Source[]  - The sources for a release
 
- count int
 - The number of assets for a release
 - links
Sequence[Get
Release Assets Link]  - The links for a release
 - sources
Sequence[Get
Release Assets Source]  - 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
 
GetReleaseAssetsLink   
GetReleaseAssetsSource   
Package Details
- Repository
 - GitLab pulumi/pulumi-gitlab
 - License
 - Apache-2.0
 - Notes
 - This Pulumi package is based on the 
gitlabTerraform Provider.