Oracle Cloud Infrastructure v2.11.0 published on Thursday, Sep 19, 2024 by Pulumi
oci.Artifacts.getRepositories
Explore with Pulumi AI
This data source provides the list of Repositories in Oracle Cloud Infrastructure Artifacts service.
Lists repositories in the specified compartment.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testRepositories = oci.Artifacts.getRepositories({
compartmentId: compartmentId,
displayName: repositoryDisplayName,
id: repositoryId,
isImmutable: repositoryIsImmutable,
state: repositoryState,
});
import pulumi
import pulumi_oci as oci
test_repositories = oci.Artifacts.get_repositories(compartment_id=compartment_id,
display_name=repository_display_name,
id=repository_id,
is_immutable=repository_is_immutable,
state=repository_state)
package main
import (
"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/Artifacts"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := Artifacts.GetRepositories(ctx, &artifacts.GetRepositoriesArgs{
CompartmentId: compartmentId,
DisplayName: pulumi.StringRef(repositoryDisplayName),
Id: pulumi.StringRef(repositoryId),
IsImmutable: pulumi.BoolRef(repositoryIsImmutable),
State: pulumi.StringRef(repositoryState),
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Oci = Pulumi.Oci;
return await Deployment.RunAsync(() =>
{
var testRepositories = Oci.Artifacts.GetRepositories.Invoke(new()
{
CompartmentId = compartmentId,
DisplayName = repositoryDisplayName,
Id = repositoryId,
IsImmutable = repositoryIsImmutable,
State = repositoryState,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.Artifacts.ArtifactsFunctions;
import com.pulumi.oci.Artifacts.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 testRepositories = ArtifactsFunctions.getRepositories(GetRepositoriesArgs.builder()
.compartmentId(compartmentId)
.displayName(repositoryDisplayName)
.id(repositoryId)
.isImmutable(repositoryIsImmutable)
.state(repositoryState)
.build());
}
}
variables:
testRepositories:
fn::invoke:
Function: oci:Artifacts:getRepositories
Arguments:
compartmentId: ${compartmentId}
displayName: ${repositoryDisplayName}
id: ${repositoryId}
isImmutable: ${repositoryIsImmutable}
state: ${repositoryState}
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(compartment_id: Optional[str] = None,
display_name: Optional[str] = None,
filters: Optional[Sequence[_artifacts.GetRepositoriesFilter]] = None,
id: Optional[str] = None,
is_immutable: Optional[bool] = None,
state: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetRepositoriesResult
def get_repositories_output(compartment_id: Optional[pulumi.Input[str]] = None,
display_name: Optional[pulumi.Input[str]] = None,
filters: Optional[pulumi.Input[Sequence[pulumi.Input[_artifacts.GetRepositoriesFilterArgs]]]] = None,
id: Optional[pulumi.Input[str]] = None,
is_immutable: Optional[pulumi.Input[bool]] = None,
state: 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: oci:Artifacts/getRepositories:getRepositories
arguments:
# arguments dictionary
The following arguments are supported:
- Compartment
Id string - The OCID of the compartment.
- Display
Name string - A filter to return only resources that match the given display name exactly.
- Filters
List<Get
Repositories Filter> - Id string
- A filter to return the resources for the specified OCID.
- Is
Immutable bool - A filter to return resources that match the isImmutable value.
- State string
- A filter to return only resources that match the given lifecycle state name exactly.
- Compartment
Id string - The OCID of the compartment.
- Display
Name string - A filter to return only resources that match the given display name exactly.
- Filters
[]Get
Repositories Filter - Id string
- A filter to return the resources for the specified OCID.
- Is
Immutable bool - A filter to return resources that match the isImmutable value.
- State string
- A filter to return only resources that match the given lifecycle state name exactly.
- compartment
Id String - The OCID of the compartment.
- display
Name String - A filter to return only resources that match the given display name exactly.
- filters
List<Get
Repositories Filter> - id String
- A filter to return the resources for the specified OCID.
- is
Immutable Boolean - A filter to return resources that match the isImmutable value.
- state String
- A filter to return only resources that match the given lifecycle state name exactly.
- compartment
Id string - The OCID of the compartment.
- display
Name string - A filter to return only resources that match the given display name exactly.
- filters
Get
Repositories Filter[] - id string
- A filter to return the resources for the specified OCID.
- is
Immutable boolean - A filter to return resources that match the isImmutable value.
- state string
- A filter to return only resources that match the given lifecycle state name exactly.
- compartment_
id str - The OCID of the compartment.
- display_
name str - A filter to return only resources that match the given display name exactly.
- filters
Sequence[artifacts.
Get Repositories Filter] - id str
- A filter to return the resources for the specified OCID.
- is_
immutable bool - A filter to return resources that match the isImmutable value.
- state str
- A filter to return only resources that match the given lifecycle state name exactly.
- compartment
Id String - The OCID of the compartment.
- display
Name String - A filter to return only resources that match the given display name exactly.
- filters List<Property Map>
- id String
- A filter to return the resources for the specified OCID.
- is
Immutable Boolean - A filter to return resources that match the isImmutable value.
- state String
- A filter to return only resources that match the given lifecycle state name exactly.
getRepositories Result
The following output properties are available:
- Compartment
Id string - The OCID of the repository's compartment.
- Repository
Collections List<GetRepositories Repository Collection> - The list of repository_collection.
- Display
Name string - The repository name.
- Filters
List<Get
Repositories Filter> - Id string
- The OCID of the repository. Example:
ocid1.artifactrepository.oc1..exampleuniqueID
- Is
Immutable bool - Whether the repository is immutable. The artifacts of an immutable repository cannot be overwritten.
- State string
- The current state of the repository.
- Compartment
Id string - The OCID of the repository's compartment.
- Repository
Collections []GetRepositories Repository Collection - The list of repository_collection.
- Display
Name string - The repository name.
- Filters
[]Get
Repositories Filter - Id string
- The OCID of the repository. Example:
ocid1.artifactrepository.oc1..exampleuniqueID
- Is
Immutable bool - Whether the repository is immutable. The artifacts of an immutable repository cannot be overwritten.
- State string
- The current state of the repository.
- compartment
Id String - The OCID of the repository's compartment.
- repository
Collections List<GetRepositories Repository Collection> - The list of repository_collection.
- display
Name String - The repository name.
- filters
List<Get
Repositories Filter> - id String
- The OCID of the repository. Example:
ocid1.artifactrepository.oc1..exampleuniqueID
- is
Immutable Boolean - Whether the repository is immutable. The artifacts of an immutable repository cannot be overwritten.
- state String
- The current state of the repository.
- compartment
Id string - The OCID of the repository's compartment.
- repository
Collections GetRepositories Repository Collection[] - The list of repository_collection.
- display
Name string - The repository name.
- filters
Get
Repositories Filter[] - id string
- The OCID of the repository. Example:
ocid1.artifactrepository.oc1..exampleuniqueID
- is
Immutable boolean - Whether the repository is immutable. The artifacts of an immutable repository cannot be overwritten.
- state string
- The current state of the repository.
- compartment_
id str - The OCID of the repository's compartment.
- repository_
collections Sequence[artifacts.Get Repositories Repository Collection] - The list of repository_collection.
- display_
name str - The repository name.
- filters
Sequence[artifacts.
Get Repositories Filter] - id str
- The OCID of the repository. Example:
ocid1.artifactrepository.oc1..exampleuniqueID
- is_
immutable bool - Whether the repository is immutable. The artifacts of an immutable repository cannot be overwritten.
- state str
- The current state of the repository.
- compartment
Id String - The OCID of the repository's compartment.
- repository
Collections List<Property Map> - The list of repository_collection.
- display
Name String - The repository name.
- filters List<Property Map>
- id String
- The OCID of the repository. Example:
ocid1.artifactrepository.oc1..exampleuniqueID
- is
Immutable Boolean - Whether the repository is immutable. The artifacts of an immutable repository cannot be overwritten.
- state String
- The current state of the repository.
Supporting Types
GetRepositoriesFilter
GetRepositoriesRepositoryCollection
GetRepositoriesRepositoryCollectionItem
- Compartment
Id string - The OCID of the compartment.
- Dictionary<string, string>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example:
{"Operations.CostCenter": "42"}
- Description string
- The repository description.
- Display
Name string - A filter to return only resources that match the given display name exactly.
- Dictionary<string, string>
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example:
{"Department": "Finance"}
- Id string
- A filter to return the resources for the specified OCID.
- Is
Immutable bool - A filter to return resources that match the isImmutable value.
- Repository
Type string - The repository's supported artifact type.
- State string
- A filter to return only resources that match the given lifecycle state name exactly.
- Time
Created string - An RFC 3339 timestamp indicating when the repository was created.
- Compartment
Id string - The OCID of the compartment.
- map[string]string
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example:
{"Operations.CostCenter": "42"}
- Description string
- The repository description.
- Display
Name string - A filter to return only resources that match the given display name exactly.
- map[string]string
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example:
{"Department": "Finance"}
- Id string
- A filter to return the resources for the specified OCID.
- Is
Immutable bool - A filter to return resources that match the isImmutable value.
- Repository
Type string - The repository's supported artifact type.
- State string
- A filter to return only resources that match the given lifecycle state name exactly.
- Time
Created string - An RFC 3339 timestamp indicating when the repository was created.
- compartment
Id String - The OCID of the compartment.
- Map<String,String>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example:
{"Operations.CostCenter": "42"}
- description String
- The repository description.
- display
Name String - A filter to return only resources that match the given display name exactly.
- Map<String,String>
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example:
{"Department": "Finance"}
- id String
- A filter to return the resources for the specified OCID.
- is
Immutable Boolean - A filter to return resources that match the isImmutable value.
- repository
Type String - The repository's supported artifact type.
- state String
- A filter to return only resources that match the given lifecycle state name exactly.
- time
Created String - An RFC 3339 timestamp indicating when the repository was created.
- compartment
Id string - The OCID of the compartment.
- {[key: string]: string}
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example:
{"Operations.CostCenter": "42"}
- description string
- The repository description.
- display
Name string - A filter to return only resources that match the given display name exactly.
- {[key: string]: string}
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example:
{"Department": "Finance"}
- id string
- A filter to return the resources for the specified OCID.
- is
Immutable boolean - A filter to return resources that match the isImmutable value.
- repository
Type string - The repository's supported artifact type.
- state string
- A filter to return only resources that match the given lifecycle state name exactly.
- time
Created string - An RFC 3339 timestamp indicating when the repository was created.
- compartment_
id str - The OCID of the compartment.
- Mapping[str, str]
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example:
{"Operations.CostCenter": "42"}
- description str
- The repository description.
- display_
name str - A filter to return only resources that match the given display name exactly.
- Mapping[str, str]
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example:
{"Department": "Finance"}
- id str
- A filter to return the resources for the specified OCID.
- is_
immutable bool - A filter to return resources that match the isImmutable value.
- repository_
type str - The repository's supported artifact type.
- state str
- A filter to return only resources that match the given lifecycle state name exactly.
- time_
created str - An RFC 3339 timestamp indicating when the repository was created.
- compartment
Id String - The OCID of the compartment.
- Map<String>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example:
{"Operations.CostCenter": "42"}
- description String
- The repository description.
- display
Name String - A filter to return only resources that match the given display name exactly.
- Map<String>
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example:
{"Department": "Finance"}
- id String
- A filter to return the resources for the specified OCID.
- is
Immutable Boolean - A filter to return resources that match the isImmutable value.
- repository
Type String - The repository's supported artifact type.
- state String
- A filter to return only resources that match the given lifecycle state name exactly.
- time
Created String - An RFC 3339 timestamp indicating when the repository was created.
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
oci
Terraform Provider.