Rancher 2 v6.1.1 published on Friday, May 10, 2024 by Pulumi
rancher2.getSetting
Explore with Pulumi AI
Use this data source to retrieve information about a Rancher v2 setting.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as rancher2 from "@pulumi/rancher2";
const server-image = rancher2.getSetting({
name: "server-image",
});
import pulumi
import pulumi_rancher2 as rancher2
server_image = rancher2.get_setting(name="server-image")
package main
import (
"github.com/pulumi/pulumi-rancher2/sdk/v6/go/rancher2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := rancher2.LookupSetting(ctx, &rancher2.LookupSettingArgs{
Name: "server-image",
}, 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 server_image = Rancher2.GetSetting.Invoke(new()
{
Name = "server-image",
});
});
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.GetSettingArgs;
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 server-image = Rancher2Functions.getSetting(GetSettingArgs.builder()
.name("server-image")
.build());
}
}
variables:
server-image:
fn::invoke:
Function: rancher2:getSetting
Arguments:
name: server-image
Using getSetting
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 getSetting(args: GetSettingArgs, opts?: InvokeOptions): Promise<GetSettingResult>
function getSettingOutput(args: GetSettingOutputArgs, opts?: InvokeOptions): Output<GetSettingResult>
def get_setting(name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetSettingResult
def get_setting_output(name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetSettingResult]
func LookupSetting(ctx *Context, args *LookupSettingArgs, opts ...InvokeOption) (*LookupSettingResult, error)
func LookupSettingOutput(ctx *Context, args *LookupSettingOutputArgs, opts ...InvokeOption) LookupSettingResultOutput
> Note: This function is named LookupSetting
in the Go SDK.
public static class GetSetting
{
public static Task<GetSettingResult> InvokeAsync(GetSettingArgs args, InvokeOptions? opts = null)
public static Output<GetSettingResult> Invoke(GetSettingInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetSettingResult> getSetting(GetSettingArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: rancher2:index/getSetting:getSetting
arguments:
# arguments dictionary
The following arguments are supported:
- Name string
- The setting name.
- Name string
- The setting name.
- name String
- The setting name.
- name string
- The setting name.
- name str
- The setting name.
- name String
- The setting name.
getSetting Result
The following output properties are available:
Package Details
- Repository
- Rancher2 pulumi/pulumi-rancher2
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
rancher2
Terraform Provider.