pulumi/tests/testdata/codegen/plain-object-disable-defaults/docs/foo/_index.md

68 KiB


title: "Foo" title_tag: "example.Foo" meta_desc: "Documentation for the example.Foo resource with examples, input properties, output properties, lookup functions, and supporting types." layout: api no_edit_this_page: true

test new feature with resoruces

Create Foo Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new Foo(name: string, args: FooArgs, opts?: CustomResourceOptions);
@overload
def Foo(resource_name: str,
        args: FooArgs,
        opts: Optional[ResourceOptions] = None)

@overload
def Foo(resource_name: str,
        opts: Optional[ResourceOptions] = None,
        backup_kube_client_settings: Optional[KubeClientSettingsArgs] = None,
        argument: Optional[str] = None,
        kube_client_settings: Optional[KubeClientSettingsArgs] = None,
        settings: Optional[LayeredTypeArgs] = None)
func NewFoo(ctx *Context, name string, args FooArgs, opts ...ResourceOption) (*Foo, error)
public Foo(string name, FooArgs args, CustomResourceOptions? opts = null)
public Foo(String name, FooArgs args)
public Foo(String name, FooArgs args, CustomResourceOptions options)
type: example:Foo
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name string
The unique name of the resource.
args FooArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
args FooArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args FooArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args FooArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args FooArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Constructor example

The following reference example uses placeholder values for all input properties.

var fooResource = new Example.Foo("fooResource", new()
{
    BackupKubeClientSettings = new Example.Inputs.KubeClientSettingsArgs
    {
        Burst = 0,
        Qps = 0,
        RecTest = kubeClientSettings,
    },
    Argument = "string",
    KubeClientSettings = kubeClientSettings,
    Settings = new Example.Inputs.LayeredTypeArgs
    {
        Other = new Example.Inputs.HelmReleaseSettingsArgs
        {
            RequiredArg = "string",
            Driver = "string",
            PluginsPath = "string",
        },
        Thinker = "string",
        Answer = 0,
        PlainOther = 
        {
            { "requiredArg", "string" },
            { "driver", "string" },
            { "pluginsPath", "string" },
        },
        Question = "string",
        Recursive = layeredType,
    },
});
example, err := example.NewFoo(ctx, "fooResource", &example.FooArgs{
BackupKubeClientSettings: &example.KubeClientSettingsArgs{
Burst: pulumi.Int(0),
Qps: pulumi.Float64(0),
RecTest: pulumi.Any(kubeClientSettings),
},
Argument: "string",
KubeClientSettings: pulumi.Any(kubeClientSettings),
Settings: &example.LayeredTypeArgs{
Other: &example.HelmReleaseSettingsArgs{
RequiredArg: pulumi.String("string"),
Driver: pulumi.String("string"),
PluginsPath: pulumi.String("string"),
},
Thinker: pulumi.String("string"),
Answer: pulumi.Float64(0),
PlainOther: interface{}{
RequiredArg: pulumi.String("string"),
Driver: pulumi.String("string"),
PluginsPath: pulumi.String("string"),
},
Question: pulumi.String("string"),
Recursive: pulumi.Any(layeredType),
},
})
var fooResource = new Foo("fooResource", FooArgs.builder()
    .backupKubeClientSettings(KubeClientSettingsArgs.builder()
        .burst(0)
        .qps(0)
        .recTest(kubeClientSettings)
        .build())
    .argument("string")
    .kubeClientSettings(kubeClientSettings)
    .settings(LayeredTypeArgs.builder()
        .other(HelmReleaseSettingsArgs.builder()
            .requiredArg("string")
            .driver("string")
            .pluginsPath("string")
            .build())
        .thinker("string")
        .answer(0)
        .plainOther(HelmReleaseSettingsArgs.builder()
            .requiredArg("string")
            .driver("string")
            .pluginsPath("string")
            .build())
        .question("string")
        .recursive(layeredType)
        .build())
    .build());
foo_resource = example.Foo("fooResource",
    backup_kube_client_settings={
        "burst": 0,
        "qps": 0,
        "rec_test": kube_client_settings,
    },
    argument="string",
    kube_client_settings=kube_client_settings,
    settings={
        "other": {
            "required_arg": "string",
            "driver": "string",
            "plugins_path": "string",
        },
        "thinker": "string",
        "answer": 0,
        "plain_other": {
            "required_arg": "string",
            "driver": "string",
            "plugins_path": "string",
        },
        "question": "string",
        "recursive": layered_type,
    })
const fooResource = new example.Foo("fooResource", {
    backupKubeClientSettings: {
        burst: 0,
        qps: 0,
        recTest: kubeClientSettings,
    },
    argument: "string",
    kubeClientSettings: kubeClientSettings,
    settings: {
        other: {
            requiredArg: "string",
            driver: "string",
            pluginsPath: "string",
        },
        thinker: "string",
        answer: 0,
        plainOther: {
            requiredArg: "string",
            driver: "string",
            pluginsPath: "string",
        },
        question: "string",
        recursive: layeredType,
    },
});
type: example:Foo
properties:
    argument: string
    backupKubeClientSettings:
        burst: 0
        qps: 0
        recTest: ${kubeClientSettings}
    kubeClientSettings: ${kubeClientSettings}
    settings:
        answer: 0
        other:
            driver: string
            pluginsPath: string
            requiredArg: string
        plainOther:
            driver: string
            pluginsPath: string
            requiredArg: string
        question: string
        recursive: ${layeredType}
        thinker: string

Foo Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The Foo resource accepts the following input properties:

BackupKubeClientSettings KubeClientSettings
Options for tuning the Kubernetes client used by a Provider.
Argument string
KubeClientSettings KubeClientSettings
Options for tuning the Kubernetes client used by a Provider.
Settings LayeredType
describing things
BackupKubeClientSettings KubeClientSettingsArgs
Options for tuning the Kubernetes client used by a Provider.
Argument string
KubeClientSettings KubeClientSettingsArgs
Options for tuning the Kubernetes client used by a Provider.
Settings LayeredTypeArgs
describing things
backupKubeClientSettings KubeClientSettings
Options for tuning the Kubernetes client used by a Provider.
argument String
kubeClientSettings KubeClientSettings
Options for tuning the Kubernetes client used by a Provider.
settings LayeredType
describing things
backupKubeClientSettings KubeClientSettings
Options for tuning the Kubernetes client used by a Provider.
argument string
kubeClientSettings KubeClientSettings
Options for tuning the Kubernetes client used by a Provider.
settings LayeredType
describing things
backup_kube_client_settings KubeClientSettingsArgs
Options for tuning the Kubernetes client used by a Provider.
argument str
kube_client_settings KubeClientSettingsArgs
Options for tuning the Kubernetes client used by a Provider.
settings LayeredTypeArgs
describing things
backupKubeClientSettings Property Map
Options for tuning the Kubernetes client used by a Provider.
argument String
kubeClientSettings Property Map
Options for tuning the Kubernetes client used by a Provider.
settings Property Map
describing things

Outputs

All input properties are implicitly available as output properties. Additionally, the Foo resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
DefaultKubeClientSettings KubeClientSettings
A test for plain types
Id string
The provider-assigned unique ID for this managed resource.
DefaultKubeClientSettings KubeClientSettings
A test for plain types
id String
The provider-assigned unique ID for this managed resource.
defaultKubeClientSettings KubeClientSettings
A test for plain types
id string
The provider-assigned unique ID for this managed resource.
defaultKubeClientSettings KubeClientSettings
A test for plain types
id str
The provider-assigned unique ID for this managed resource.
default_kube_client_settings KubeClientSettings
A test for plain types
id String
The provider-assigned unique ID for this managed resource.
defaultKubeClientSettings Property Map
A test for plain types

Supporting Types

HelmReleaseSettings, HelmReleaseSettingsArgs

RequiredArg string
to test required args
Driver string
The backend storage driver for Helm. Values are: configmap, secret, memory, sql.
PluginsPath string
The path to the helm plugins directory.
RequiredArg string
to test required args
Driver string
The backend storage driver for Helm. Values are: configmap, secret, memory, sql.
PluginsPath string
The path to the helm plugins directory.
requiredArg String
to test required args
driver String
The backend storage driver for Helm. Values are: configmap, secret, memory, sql.
pluginsPath String
The path to the helm plugins directory.
requiredArg string
to test required args
driver string
The backend storage driver for Helm. Values are: configmap, secret, memory, sql.
pluginsPath string
The path to the helm plugins directory.
required_arg str
to test required args
driver str
The backend storage driver for Helm. Values are: configmap, secret, memory, sql.
plugins_path str
The path to the helm plugins directory.
requiredArg String
to test required args
driver String
The backend storage driver for Helm. Values are: configmap, secret, memory, sql.
pluginsPath String
The path to the helm plugins directory.

KubeClientSettings, KubeClientSettingsArgs

Burst int
Maximum burst for throttle. Default value is 10.
Qps double
Maximum queries per second (QPS) to the API server from this client. Default value is 5.
RecTest KubeClientSettings
Burst int
Maximum burst for throttle. Default value is 10.
Qps float64
Maximum queries per second (QPS) to the API server from this client. Default value is 5.
RecTest KubeClientSettings
burst Integer
Maximum burst for throttle. Default value is 10.
qps Double
Maximum queries per second (QPS) to the API server from this client. Default value is 5.
recTest KubeClientSettings
burst number
Maximum burst for throttle. Default value is 10.
qps number
Maximum queries per second (QPS) to the API server from this client. Default value is 5.
recTest KubeClientSettings
burst int
Maximum burst for throttle. Default value is 10.
qps float
Maximum queries per second (QPS) to the API server from this client. Default value is 5.
rec_test KubeClientSettings
burst Number
Maximum burst for throttle. Default value is 10.
qps Number
Maximum queries per second (QPS) to the API server from this client. Default value is 5.
recTest Property Map

LayeredType, LayeredTypeArgs

Other HelmReleaseSettings
Thinker string
To ask and answer
Answer double
The answer to the question
PlainOther HelmReleaseSettings
Test how plain types interact
Question string
The question already answered
Recursive LayeredType
Other HelmReleaseSettings
Thinker string
To ask and answer
Answer float64
The answer to the question
PlainOther HelmReleaseSettings
Test how plain types interact
Question string
The question already answered
Recursive LayeredType
other HelmReleaseSettings
thinker String
To ask and answer
answer Double
The answer to the question
plainOther HelmReleaseSettings
Test how plain types interact
question String
The question already answered
recursive LayeredType
other HelmReleaseSettings
thinker string
To ask and answer
answer number
The answer to the question
plainOther HelmReleaseSettings
Test how plain types interact
question string
The question already answered
recursive LayeredType
other HelmReleaseSettings
thinker str
To ask and answer
answer float
The answer to the question
plain_other HelmReleaseSettings
Test how plain types interact
question str
The question already answered
recursive LayeredType
other Property Map
thinker String
To ask and answer
answer Number
The answer to the question
plainOther Property Map
Test how plain types interact
question String
The question already answered
recursive Property Map

Package Details

Repository
example
License