Rancher 2 v7.1.1 published on Monday, Oct 7, 2024 by Pulumi
rancher2.getCloudCredential
Explore with Pulumi AI
Use this data source to retrieve information about a Rancher v2 Cloud Credential.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as rancher2 from "@pulumi/rancher2";
const test = rancher2.getCloudCredential({
name: "test",
});
import pulumi
import pulumi_rancher2 as rancher2
test = rancher2.get_cloud_credential(name="test")
package main
import (
"github.com/pulumi/pulumi-rancher2/sdk/v7/go/rancher2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := rancher2.LookupCloudCredential(ctx, &rancher2.LookupCloudCredentialArgs{
Name: "test",
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Rancher2 = Pulumi.Rancher2;
return await Deployment.RunAsync(() =>
{
var test = Rancher2.GetCloudCredential.Invoke(new()
{
Name = "test",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.rancher2.Rancher2Functions;
import com.pulumi.rancher2.inputs.GetCloudCredentialArgs;
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 test = Rancher2Functions.getCloudCredential(GetCloudCredentialArgs.builder()
.name("test")
.build());
}
}
variables:
test:
fn::invoke:
Function: rancher2:getCloudCredential
Arguments:
name: test
Using getCloudCredential
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 getCloudCredential(args: GetCloudCredentialArgs, opts?: InvokeOptions): Promise<GetCloudCredentialResult>
function getCloudCredentialOutput(args: GetCloudCredentialOutputArgs, opts?: InvokeOptions): Output<GetCloudCredentialResult>
def get_cloud_credential(name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetCloudCredentialResult
def get_cloud_credential_output(name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetCloudCredentialResult]
func LookupCloudCredential(ctx *Context, args *LookupCloudCredentialArgs, opts ...InvokeOption) (*LookupCloudCredentialResult, error)
func LookupCloudCredentialOutput(ctx *Context, args *LookupCloudCredentialOutputArgs, opts ...InvokeOption) LookupCloudCredentialResultOutput
> Note: This function is named LookupCloudCredential
in the Go SDK.
public static class GetCloudCredential
{
public static Task<GetCloudCredentialResult> InvokeAsync(GetCloudCredentialArgs args, InvokeOptions? opts = null)
public static Output<GetCloudCredentialResult> Invoke(GetCloudCredentialInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetCloudCredentialResult> getCloudCredential(GetCloudCredentialArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: rancher2:index/getCloudCredential:getCloudCredential
arguments:
# arguments dictionary
The following arguments are supported:
- Name string
- The Cloud Credential name.
- Name string
- The Cloud Credential name.
- name String
- The Cloud Credential name.
- name string
- The Cloud Credential name.
- name str
- The Cloud Credential name.
- name String
- The Cloud Credential name.
getCloudCredential Result
The following output properties are available:
- Annotations Dictionary<string, string>
- (Computed) Annotations for the Cloud Credential (map)
- Id string
- The provider-assigned unique ID for this managed resource.
- Labels Dictionary<string, string>
- (Computed) Labels for the Cloud Credential (map)
- Name string
- Annotations map[string]string
- (Computed) Annotations for the Cloud Credential (map)
- Id string
- The provider-assigned unique ID for this managed resource.
- Labels map[string]string
- (Computed) Labels for the Cloud Credential (map)
- Name string
- annotations Map<String,String>
- (Computed) Annotations for the Cloud Credential (map)
- id String
- The provider-assigned unique ID for this managed resource.
- labels Map<String,String>
- (Computed) Labels for the Cloud Credential (map)
- name String
- annotations {[key: string]: string}
- (Computed) Annotations for the Cloud Credential (map)
- id string
- The provider-assigned unique ID for this managed resource.
- labels {[key: string]: string}
- (Computed) Labels for the Cloud Credential (map)
- name string
- annotations Mapping[str, str]
- (Computed) Annotations for the Cloud Credential (map)
- id str
- The provider-assigned unique ID for this managed resource.
- labels Mapping[str, str]
- (Computed) Labels for the Cloud Credential (map)
- name str
- annotations Map<String>
- (Computed) Annotations for the Cloud Credential (map)
- id String
- The provider-assigned unique ID for this managed resource.
- labels Map<String>
- (Computed) Labels for the Cloud Credential (map)
- name String
Package Details
- Repository
- Rancher2 pulumi/pulumi-rancher2
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
rancher2
Terraform Provider.