sonarqube 0.16.14 published on Monday, Apr 14, 2025 by jdamata
sonarqube.getProject
Explore with Pulumi AI
Use this data source to get a Sonarqube project resource
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as sonarqube from "@pulumi/sonarqube";
const project = sonarqube.getProject({
project: "projet-key-id",
});
import pulumi
import pulumi_sonarqube as sonarqube
project = sonarqube.get_project(project="projet-key-id")
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/sonarqube/sonarqube"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := sonarqube.LookupProject(ctx, &sonarqube.LookupProjectArgs{
Project: "projet-key-id",
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Sonarqube = Pulumi.Sonarqube;
return await Deployment.RunAsync(() =>
{
var project = Sonarqube.GetProject.Invoke(new()
{
Project = "projet-key-id",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.sonarqube.SonarqubeFunctions;
import com.pulumi.sonarqube.inputs.GetProjectArgs;
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) {
final var project = SonarqubeFunctions.getProject(GetProjectArgs.builder()
.project("projet-key-id")
.build());
}
}
variables:
project:
fn::invoke:
function: sonarqube:getProject
arguments:
project: projet-key-id
Using getProject
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 getProject(args: GetProjectArgs, opts?: InvokeOptions): Promise<GetProjectResult>
function getProjectOutput(args: GetProjectOutputArgs, opts?: InvokeOptions): Output<GetProjectResult>
def get_project(id: Optional[str] = None,
project: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetProjectResult
def get_project_output(id: Optional[pulumi.Input[str]] = None,
project: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetProjectResult]
func LookupProject(ctx *Context, args *LookupProjectArgs, opts ...InvokeOption) (*LookupProjectResult, error)
func LookupProjectOutput(ctx *Context, args *LookupProjectOutputArgs, opts ...InvokeOption) LookupProjectResultOutput
> Note: This function is named LookupProject
in the Go SDK.
public static class GetProject
{
public static Task<GetProjectResult> InvokeAsync(GetProjectArgs args, InvokeOptions? opts = null)
public static Output<GetProjectResult> Invoke(GetProjectInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetProjectResult> getProject(GetProjectArgs args, InvokeOptions options)
public static Output<GetProjectResult> getProject(GetProjectArgs args, InvokeOptions options)
fn::invoke:
function: sonarqube:index/getProject:getProject
arguments:
# arguments dictionary
The following arguments are supported:
getProject Result
The following output properties are available:
- Id string
- The ID of this resource.
- Name string
- Name of the project
- Project string
- The project key of the project
- Visibility string
- Project visibility
- Id string
- The ID of this resource.
- Name string
- Name of the project
- Project string
- The project key of the project
- Visibility string
- Project visibility
- id String
- The ID of this resource.
- name String
- Name of the project
- project String
- The project key of the project
- visibility String
- Project visibility
- id string
- The ID of this resource.
- name string
- Name of the project
- project string
- The project key of the project
- visibility string
- Project visibility
- id str
- The ID of this resource.
- name str
- Name of the project
- project str
- The project key of the project
- visibility str
- Project visibility
- id String
- The ID of this resource.
- name String
- Name of the project
- project String
- The project key of the project
- visibility String
- Project visibility
Package Details
- Repository
- sonarqube jdamata/terraform-provider-sonarqube
- License
- Notes
- This Pulumi package is based on the
sonarqube
Terraform Provider.