1. Packages
  2. Artifactory
  3. API Docs
  4. getRepositories
artifactory v6.7.1 published on Friday, Apr 26, 2024 by Pulumi

artifactory.getRepositories

Explore with Pulumi AI

artifactory logo
artifactory v6.7.1 published on Friday, Apr 26, 2024 by Pulumi

    Returns a list of minimal repository details for all repositories of the specified type.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as artifactory from "@pulumi/artifactory";
    
    const all-alpine-local = artifactory.getRepositories({
        repositoryType: "local",
        packageType: "alpine",
    });
    
    import pulumi
    import pulumi_artifactory as artifactory
    
    all_alpine_local = artifactory.get_repositories(repository_type="local",
        package_type="alpine")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-artifactory/sdk/v6/go/artifactory"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := artifactory.GetRepositories(ctx, &artifactory.GetRepositoriesArgs{
    			RepositoryType: pulumi.StringRef("local"),
    			PackageType:    pulumi.StringRef("alpine"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Artifactory = Pulumi.Artifactory;
    
    return await Deployment.RunAsync(() => 
    {
        var all_alpine_local = Artifactory.GetRepositories.Invoke(new()
        {
            RepositoryType = "local",
            PackageType = "alpine",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.artifactory.ArtifactoryFunctions;
    import com.pulumi.artifactory.inputs.GetRepositoriesArgs;
    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 all-alpine-local = ArtifactoryFunctions.getRepositories(GetRepositoriesArgs.builder()
                .repositoryType("local")
                .packageType("alpine")
                .build());
    
        }
    }
    
    variables:
      all-alpine-local:
        fn::invoke:
          Function: artifactory:getRepositories
          Arguments:
            repositoryType: local
            packageType: alpine
    

    Using getRepositories

    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 getRepositories(args: GetRepositoriesArgs, opts?: InvokeOptions): Promise<GetRepositoriesResult>
    function getRepositoriesOutput(args: GetRepositoriesOutputArgs, opts?: InvokeOptions): Output<GetRepositoriesResult>
    def get_repositories(package_type: Optional[str] = None,
                         project_key: Optional[str] = None,
                         repository_type: Optional[str] = None,
                         opts: Optional[InvokeOptions] = None) -> GetRepositoriesResult
    def get_repositories_output(package_type: Optional[pulumi.Input[str]] = None,
                         project_key: Optional[pulumi.Input[str]] = None,
                         repository_type: Optional[pulumi.Input[str]] = None,
                         opts: Optional[InvokeOptions] = None) -> Output[GetRepositoriesResult]
    func GetRepositories(ctx *Context, args *GetRepositoriesArgs, opts ...InvokeOption) (*GetRepositoriesResult, error)
    func GetRepositoriesOutput(ctx *Context, args *GetRepositoriesOutputArgs, opts ...InvokeOption) GetRepositoriesResultOutput

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

    public static class GetRepositories 
    {
        public static Task<GetRepositoriesResult> InvokeAsync(GetRepositoriesArgs args, InvokeOptions? opts = null)
        public static Output<GetRepositoriesResult> Invoke(GetRepositoriesInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetRepositoriesResult> getRepositories(GetRepositoriesArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: artifactory:index/getRepositories:getRepositories
      arguments:
        # arguments dictionary

    The following arguments are supported:

    PackageType string
    ProjectKey string
    Filter for repositories assigned to a specific project.
    RepositoryType string
    Filter for repositories of a specific type. Allowed values are: local, remote, virtual, federated, distribution
    PackageType string
    ProjectKey string
    Filter for repositories assigned to a specific project.
    RepositoryType string
    Filter for repositories of a specific type. Allowed values are: local, remote, virtual, federated, distribution
    packageType String
    projectKey String
    Filter for repositories assigned to a specific project.
    repositoryType String
    Filter for repositories of a specific type. Allowed values are: local, remote, virtual, federated, distribution
    packageType string
    projectKey string
    Filter for repositories assigned to a specific project.
    repositoryType string
    Filter for repositories of a specific type. Allowed values are: local, remote, virtual, federated, distribution
    package_type str
    project_key str
    Filter for repositories assigned to a specific project.
    repository_type str
    Filter for repositories of a specific type. Allowed values are: local, remote, virtual, federated, distribution
    packageType String
    projectKey String
    Filter for repositories assigned to a specific project.
    repositoryType String
    Filter for repositories of a specific type. Allowed values are: local, remote, virtual, federated, distribution

    getRepositories Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    Repos List<GetRepositoriesRepo>
    A list of repositories.
    PackageType string
    ProjectKey string
    Filter for repositories assigned to a specific project.
    RepositoryType string
    Filter for repositories of a specific type. Allowed values are: local, remote, virtual, federated, distribution
    Id string
    The provider-assigned unique ID for this managed resource.
    Repos []GetRepositoriesRepo
    A list of repositories.
    PackageType string
    ProjectKey string
    Filter for repositories assigned to a specific project.
    RepositoryType string
    Filter for repositories of a specific type. Allowed values are: local, remote, virtual, federated, distribution
    id String
    The provider-assigned unique ID for this managed resource.
    repos List<GetRepositoriesRepo>
    A list of repositories.
    packageType String
    projectKey String
    Filter for repositories assigned to a specific project.
    repositoryType String
    Filter for repositories of a specific type. Allowed values are: local, remote, virtual, federated, distribution
    id string
    The provider-assigned unique ID for this managed resource.
    repos GetRepositoriesRepo[]
    A list of repositories.
    packageType string
    projectKey string
    Filter for repositories assigned to a specific project.
    repositoryType string
    Filter for repositories of a specific type. Allowed values are: local, remote, virtual, federated, distribution
    id str
    The provider-assigned unique ID for this managed resource.
    repos Sequence[GetRepositoriesRepo]
    A list of repositories.
    package_type str
    project_key str
    Filter for repositories assigned to a specific project.
    repository_type str
    Filter for repositories of a specific type. Allowed values are: local, remote, virtual, federated, distribution
    id String
    The provider-assigned unique ID for this managed resource.
    repos List<Property Map>
    A list of repositories.
    packageType String
    projectKey String
    Filter for repositories assigned to a specific project.
    repositoryType String
    Filter for repositories of a specific type. Allowed values are: local, remote, virtual, federated, distribution

    Supporting Types

    GetRepositoriesRepo

    Description string
    Key string
    PackageType string
    Type string
    Url string
    Description string
    Key string
    PackageType string
    Type string
    Url string
    description String
    key String
    packageType String
    type String
    url String
    description string
    key string
    packageType string
    type string
    url string
    description String
    key String
    packageType String
    type String
    url String

    Package Details

    Repository
    artifactory pulumi/pulumi-artifactory
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the artifactory Terraform Provider.
    artifactory logo
    artifactory v6.7.1 published on Friday, Apr 26, 2024 by Pulumi