sonarqube 0.16.15 published on Saturday, May 17, 2025 by jdamata
sonarqube.getPortfolio
Explore with Pulumi AI
sonarqube 0.16.15 published on Saturday, May 17, 2025 by jdamata
Use this data source to get a Sonarqube portfolio resource
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as sonarqube from "@pulumi/sonarqube";
const portfolio = sonarqube.getPortfolio({
key: "portfolio-key",
});
import pulumi
import pulumi_sonarqube as sonarqube
portfolio = sonarqube.get_portfolio(key="portfolio-key")
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.LookupPortfolio(ctx, &sonarqube.LookupPortfolioArgs{
Key: "portfolio-key",
}, 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 portfolio = Sonarqube.GetPortfolio.Invoke(new()
{
Key = "portfolio-key",
});
});
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.GetPortfolioArgs;
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 portfolio = SonarqubeFunctions.getPortfolio(GetPortfolioArgs.builder()
.key("portfolio-key")
.build());
}
}
variables:
portfolio:
fn::invoke:
function: sonarqube:getPortfolio
arguments:
key: portfolio-key
Using getPortfolio
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 getPortfolio(args: GetPortfolioArgs, opts?: InvokeOptions): Promise<GetPortfolioResult>
function getPortfolioOutput(args: GetPortfolioOutputArgs, opts?: InvokeOptions): Output<GetPortfolioResult>
def get_portfolio(id: Optional[str] = None,
key: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetPortfolioResult
def get_portfolio_output(id: Optional[pulumi.Input[str]] = None,
key: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetPortfolioResult]
func LookupPortfolio(ctx *Context, args *LookupPortfolioArgs, opts ...InvokeOption) (*LookupPortfolioResult, error)
func LookupPortfolioOutput(ctx *Context, args *LookupPortfolioOutputArgs, opts ...InvokeOption) LookupPortfolioResultOutput
> Note: This function is named LookupPortfolio
in the Go SDK.
public static class GetPortfolio
{
public static Task<GetPortfolioResult> InvokeAsync(GetPortfolioArgs args, InvokeOptions? opts = null)
public static Output<GetPortfolioResult> Invoke(GetPortfolioInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetPortfolioResult> getPortfolio(GetPortfolioArgs args, InvokeOptions options)
public static Output<GetPortfolioResult> getPortfolio(GetPortfolioArgs args, InvokeOptions options)
fn::invoke:
function: sonarqube:index/getPortfolio:getPortfolio
arguments:
# arguments dictionary
The following arguments are supported:
getPortfolio Result
The following output properties are available:
- Branch string
- Which branch is analyzed
- Description string
- Description of the portfolio
- Id string
- The ID of this resource.
- Key string
- The key of the portfolio
- Name string
- Name of the portfolio
- Qualifier string
VW
(portfolios always have this qualifier)- Regexp string
- The regular expression used to populate the portfolio. Only active when
selection_mode
isREGEXP
- Selection
Mode string - How the Portfolio is populated. Possible values are
NONE
,MANUAL
,TAGS
,REGEXP
orREST
. See docs for how Portfolio population works - List<string>
- The list of tags used to populate the Portfolio. Only active when
selection_mode
isTAGS
- Visibility string
- Portfolio visibility
- Branch string
- Which branch is analyzed
- Description string
- Description of the portfolio
- Id string
- The ID of this resource.
- Key string
- The key of the portfolio
- Name string
- Name of the portfolio
- Qualifier string
VW
(portfolios always have this qualifier)- Regexp string
- The regular expression used to populate the portfolio. Only active when
selection_mode
isREGEXP
- Selection
Mode string - How the Portfolio is populated. Possible values are
NONE
,MANUAL
,TAGS
,REGEXP
orREST
. See docs for how Portfolio population works - []string
- The list of tags used to populate the Portfolio. Only active when
selection_mode
isTAGS
- Visibility string
- Portfolio visibility
- branch String
- Which branch is analyzed
- description String
- Description of the portfolio
- id String
- The ID of this resource.
- key String
- The key of the portfolio
- name String
- Name of the portfolio
- qualifier String
VW
(portfolios always have this qualifier)- regexp String
- The regular expression used to populate the portfolio. Only active when
selection_mode
isREGEXP
- selection
Mode String - How the Portfolio is populated. Possible values are
NONE
,MANUAL
,TAGS
,REGEXP
orREST
. See docs for how Portfolio population works - List<String>
- The list of tags used to populate the Portfolio. Only active when
selection_mode
isTAGS
- visibility String
- Portfolio visibility
- branch string
- Which branch is analyzed
- description string
- Description of the portfolio
- id string
- The ID of this resource.
- key string
- The key of the portfolio
- name string
- Name of the portfolio
- qualifier string
VW
(portfolios always have this qualifier)- regexp string
- The regular expression used to populate the portfolio. Only active when
selection_mode
isREGEXP
- selection
Mode string - How the Portfolio is populated. Possible values are
NONE
,MANUAL
,TAGS
,REGEXP
orREST
. See docs for how Portfolio population works - string[]
- The list of tags used to populate the Portfolio. Only active when
selection_mode
isTAGS
- visibility string
- Portfolio visibility
- branch str
- Which branch is analyzed
- description str
- Description of the portfolio
- id str
- The ID of this resource.
- key str
- The key of the portfolio
- name str
- Name of the portfolio
- qualifier str
VW
(portfolios always have this qualifier)- regexp str
- The regular expression used to populate the portfolio. Only active when
selection_mode
isREGEXP
- selection_
mode str - How the Portfolio is populated. Possible values are
NONE
,MANUAL
,TAGS
,REGEXP
orREST
. See docs for how Portfolio population works - Sequence[str]
- The list of tags used to populate the Portfolio. Only active when
selection_mode
isTAGS
- visibility str
- Portfolio visibility
- branch String
- Which branch is analyzed
- description String
- Description of the portfolio
- id String
- The ID of this resource.
- key String
- The key of the portfolio
- name String
- Name of the portfolio
- qualifier String
VW
(portfolios always have this qualifier)- regexp String
- The regular expression used to populate the portfolio. Only active when
selection_mode
isREGEXP
- selection
Mode String - How the Portfolio is populated. Possible values are
NONE
,MANUAL
,TAGS
,REGEXP
orREST
. See docs for how Portfolio population works - List<String>
- The list of tags used to populate the Portfolio. Only active when
selection_mode
isTAGS
- visibility String
- Portfolio visibility
Package Details
- Repository
- sonarqube jdamata/terraform-provider-sonarqube
- License
- Notes
- This Pulumi package is based on the
sonarqube
Terraform Provider.
sonarqube 0.16.15 published on Saturday, May 17, 2025 by jdamata