Oracle Cloud Infrastructure v1.41.0 published on Wednesday, Jun 19, 2024 by Pulumi
oci.DevOps.getRepositoryObject
Explore with Pulumi AI
Oracle Cloud Infrastructure v1.41.0 published on Wednesday, Jun 19, 2024 by Pulumi
This data source provides details about a specific Repository Object resource in Oracle Cloud Infrastructure Devops service.
Retrieves blob of specific branch name/commit ID and file path.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testRepositoryObject = oci.DevOps.getRepositoryObject({
repositoryId: testRepository.id,
filePath: repositoryObjectFilePath,
refName: repositoryObjectRefName,
});
import pulumi
import pulumi_oci as oci
test_repository_object = oci.DevOps.get_repository_object(repository_id=test_repository["id"],
file_path=repository_object_file_path,
ref_name=repository_object_ref_name)
package main
import (
"github.com/pulumi/pulumi-oci/sdk/go/oci/DevOps"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := DevOps.GetRepositoryObject(ctx, &devops.GetRepositoryObjectArgs{
RepositoryId: testRepository.Id,
FilePath: pulumi.StringRef(repositoryObjectFilePath),
RefName: pulumi.StringRef(repositoryObjectRefName),
}, 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 testRepositoryObject = Oci.DevOps.GetRepositoryObject.Invoke(new()
{
RepositoryId = testRepository.Id,
FilePath = repositoryObjectFilePath,
RefName = repositoryObjectRefName,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.DevOps.DevOpsFunctions;
import com.pulumi.oci.DevOps.inputs.GetRepositoryObjectArgs;
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 testRepositoryObject = DevOpsFunctions.getRepositoryObject(GetRepositoryObjectArgs.builder()
.repositoryId(testRepository.id())
.filePath(repositoryObjectFilePath)
.refName(repositoryObjectRefName)
.build());
}
}
variables:
testRepositoryObject:
fn::invoke:
Function: oci:DevOps:getRepositoryObject
Arguments:
repositoryId: ${testRepository.id}
filePath: ${repositoryObjectFilePath}
refName: ${repositoryObjectRefName}
Using getRepositoryObject
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 getRepositoryObject(args: GetRepositoryObjectArgs, opts?: InvokeOptions): Promise<GetRepositoryObjectResult>
function getRepositoryObjectOutput(args: GetRepositoryObjectOutputArgs, opts?: InvokeOptions): Output<GetRepositoryObjectResult>
def get_repository_object(file_path: Optional[str] = None,
ref_name: Optional[str] = None,
repository_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetRepositoryObjectResult
def get_repository_object_output(file_path: Optional[pulumi.Input[str]] = None,
ref_name: Optional[pulumi.Input[str]] = None,
repository_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetRepositoryObjectResult]
func GetRepositoryObject(ctx *Context, args *GetRepositoryObjectArgs, opts ...InvokeOption) (*GetRepositoryObjectResult, error)
func GetRepositoryObjectOutput(ctx *Context, args *GetRepositoryObjectOutputArgs, opts ...InvokeOption) GetRepositoryObjectResultOutput
> Note: This function is named GetRepositoryObject
in the Go SDK.
public static class GetRepositoryObject
{
public static Task<GetRepositoryObjectResult> InvokeAsync(GetRepositoryObjectArgs args, InvokeOptions? opts = null)
public static Output<GetRepositoryObjectResult> Invoke(GetRepositoryObjectInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetRepositoryObjectResult> getRepositoryObject(GetRepositoryObjectArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: oci:DevOps/getRepositoryObject:getRepositoryObject
arguments:
# arguments dictionary
The following arguments are supported:
- Repository
Id string - Unique repository identifier.
- File
Path string - A filter to return only commits that affect any of the specified paths.
- Ref
Name string - A filter to return only resources that match the given reference name.
- Repository
Id string - Unique repository identifier.
- File
Path string - A filter to return only commits that affect any of the specified paths.
- Ref
Name string - A filter to return only resources that match the given reference name.
- repository
Id String - Unique repository identifier.
- file
Path String - A filter to return only commits that affect any of the specified paths.
- ref
Name String - A filter to return only resources that match the given reference name.
- repository
Id string - Unique repository identifier.
- file
Path string - A filter to return only commits that affect any of the specified paths.
- ref
Name string - A filter to return only resources that match the given reference name.
- repository_
id str - Unique repository identifier.
- file_
path str - A filter to return only commits that affect any of the specified paths.
- ref_
name str - A filter to return only resources that match the given reference name.
- repository
Id String - Unique repository identifier.
- file
Path String - A filter to return only commits that affect any of the specified paths.
- ref
Name String - A filter to return only resources that match the given reference name.
getRepositoryObject Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- Is
Binary bool - Flag to determine if the object contains binary file content or not.
- Repository
Id string - Sha string
- SHA-1 hash of git object.
- Size
In stringBytes - Size in bytes.
- Type string
- The type of git object.
- File
Path string - Ref
Name string
- Id string
- The provider-assigned unique ID for this managed resource.
- Is
Binary bool - Flag to determine if the object contains binary file content or not.
- Repository
Id string - Sha string
- SHA-1 hash of git object.
- Size
In stringBytes - Size in bytes.
- Type string
- The type of git object.
- File
Path string - Ref
Name string
- id String
- The provider-assigned unique ID for this managed resource.
- is
Binary Boolean - Flag to determine if the object contains binary file content or not.
- repository
Id String - sha String
- SHA-1 hash of git object.
- size
In StringBytes - Size in bytes.
- type String
- The type of git object.
- file
Path String - ref
Name String
- id string
- The provider-assigned unique ID for this managed resource.
- is
Binary boolean - Flag to determine if the object contains binary file content or not.
- repository
Id string - sha string
- SHA-1 hash of git object.
- size
In stringBytes - Size in bytes.
- type string
- The type of git object.
- file
Path string - ref
Name string
- id str
- The provider-assigned unique ID for this managed resource.
- is_
binary bool - Flag to determine if the object contains binary file content or not.
- repository_
id str - sha str
- SHA-1 hash of git object.
- size_
in_ strbytes - Size in bytes.
- type str
- The type of git object.
- file_
path str - ref_
name str
- id String
- The provider-assigned unique ID for this managed resource.
- is
Binary Boolean - Flag to determine if the object contains binary file content or not.
- repository
Id String - sha String
- SHA-1 hash of git object.
- size
In StringBytes - Size in bytes.
- type String
- The type of git object.
- file
Path String - ref
Name String
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
oci
Terraform Provider.
Oracle Cloud Infrastructure v1.41.0 published on Wednesday, Jun 19, 2024 by Pulumi