Show / Hide Table of Contents

Class GetProjects

Inheritance
System.Object
GetProjects
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Pulumi.GitLab
Assembly: Pulumi.GitLab.dll
Syntax
public static class GetProjects

Methods

View Source

InvokeAsync(GetProjectsArgs, InvokeOptions)

Provides details about a list of projects in the Gitlab provider. Listing all projects and group projects with project filtering or group project filtering is supported.

NOTE: This data source supports all available filters exposed by the xanzy/go-gitlab package, which might not expose all available filters exposed by the Gitlab APIs.

{{% examples %}}

Example Usage

{{% example %}}

List projects within a group tree

using Pulumi;
using GitLab = Pulumi.GitLab;

class MyStack : Stack
{
public MyStack()
{
    var mygroup = Output.Create(GitLab.GetGroup.InvokeAsync(new GitLab.GetGroupArgs
    {
        FullPath = "mygroup",
    }));
    var groupProjects = mygroup.Apply(mygroup => Output.Create(GitLab.GetProjects.InvokeAsync(new GitLab.GetProjectsArgs
    {
        GroupId = mygroup.Id,
        OrderBy = "name",
        IncludeSubgroups = true,
        WithShared = false,
    })));
}

}

{{% /example %}} {{% example %}}

List projects using the search syntax

using Pulumi;
using GitLab = Pulumi.GitLab;

class MyStack : Stack
{
public MyStack()
{
    var projects = Output.Create(GitLab.GetProjects.InvokeAsync(new GitLab.GetProjectsArgs
    {
        Search = "postgresql",
        Visibility = "private",
    }));
}

}

{{% /example %}} {{% /examples %}}

Declaration
public static Task<GetProjectsResult> InvokeAsync(GetProjectsArgs args = null, InvokeOptions options = null)
Parameters
Type Name Description
GetProjectsArgs args
InvokeOptions options
Returns
Type Description
System.Threading.Tasks.Task<GetProjectsResult>
  • View Source
Back to top Copyright 2016-2020, Pulumi Corporation.