1. Packages
  2. Rancher2
  3. API Docs
  4. NodeDriver
Rancher 2 v6.1.1 published on Friday, May 10, 2024 by Pulumi

rancher2.NodeDriver

Explore with Pulumi AI

rancher2 logo
Rancher 2 v6.1.1 published on Friday, May 10, 2024 by Pulumi

    Provides a Rancher v2 Node Driver resource. This can be used to create Node Driver for Rancher v2 RKE clusters and retrieve their information.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as rancher2 from "@pulumi/rancher2";
    
    // Create a new rancher2 Node Driver
    const foo = new rancher2.NodeDriver("foo", {
        active: true,
        builtin: false,
        checksum: "0x0",
        description: "Foo description",
        externalId: "foo_external",
        name: "foo",
        uiUrl: "local://ui",
        url: "local://",
        whitelistDomains: ["*.foo.com"],
    });
    
    import pulumi
    import pulumi_rancher2 as rancher2
    
    # Create a new rancher2 Node Driver
    foo = rancher2.NodeDriver("foo",
        active=True,
        builtin=False,
        checksum="0x0",
        description="Foo description",
        external_id="foo_external",
        name="foo",
        ui_url="local://ui",
        url="local://",
        whitelist_domains=["*.foo.com"])
    
    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 {
    		// Create a new rancher2 Node Driver
    		_, err := rancher2.NewNodeDriver(ctx, "foo", &rancher2.NodeDriverArgs{
    			Active:      pulumi.Bool(true),
    			Builtin:     pulumi.Bool(false),
    			Checksum:    pulumi.String("0x0"),
    			Description: pulumi.String("Foo description"),
    			ExternalId:  pulumi.String("foo_external"),
    			Name:        pulumi.String("foo"),
    			UiUrl:       pulumi.String("local://ui"),
    			Url:         pulumi.String("local://"),
    			WhitelistDomains: pulumi.StringArray{
    				pulumi.String("*.foo.com"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Rancher2 = Pulumi.Rancher2;
    
    return await Deployment.RunAsync(() => 
    {
        // Create a new rancher2 Node Driver
        var foo = new Rancher2.NodeDriver("foo", new()
        {
            Active = true,
            Builtin = false,
            Checksum = "0x0",
            Description = "Foo description",
            ExternalId = "foo_external",
            Name = "foo",
            UiUrl = "local://ui",
            Url = "local://",
            WhitelistDomains = new[]
            {
                "*.foo.com",
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.rancher2.NodeDriver;
    import com.pulumi.rancher2.NodeDriverArgs;
    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) {
            // Create a new rancher2 Node Driver
            var foo = new NodeDriver("foo", NodeDriverArgs.builder()        
                .active(true)
                .builtin(false)
                .checksum("0x0")
                .description("Foo description")
                .externalId("foo_external")
                .name("foo")
                .uiUrl("local://ui")
                .url("local://")
                .whitelistDomains("*.foo.com")
                .build());
    
        }
    }
    
    resources:
      # Create a new rancher2 Node Driver
      foo:
        type: rancher2:NodeDriver
        properties:
          active: true
          builtin: false
          checksum: 0x0
          description: Foo description
          externalId: foo_external
          name: foo
          uiUrl: local://ui
          url: local://
          whitelistDomains:
            - '*.foo.com'
    

    Create NodeDriver Resource

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

    Constructor syntax

    new NodeDriver(name: string, args: NodeDriverArgs, opts?: CustomResourceOptions);
    @overload
    def NodeDriver(resource_name: str,
                   args: NodeDriverArgs,
                   opts: Optional[ResourceOptions] = None)
    
    @overload
    def NodeDriver(resource_name: str,
                   opts: Optional[ResourceOptions] = None,
                   active: Optional[bool] = None,
                   builtin: Optional[bool] = None,
                   url: Optional[str] = None,
                   annotations: Optional[Mapping[str, Any]] = None,
                   checksum: Optional[str] = None,
                   description: Optional[str] = None,
                   external_id: Optional[str] = None,
                   labels: Optional[Mapping[str, Any]] = None,
                   name: Optional[str] = None,
                   ui_url: Optional[str] = None,
                   whitelist_domains: Optional[Sequence[str]] = None)
    func NewNodeDriver(ctx *Context, name string, args NodeDriverArgs, opts ...ResourceOption) (*NodeDriver, error)
    public NodeDriver(string name, NodeDriverArgs args, CustomResourceOptions? opts = null)
    public NodeDriver(String name, NodeDriverArgs args)
    public NodeDriver(String name, NodeDriverArgs args, CustomResourceOptions options)
    
    type: rancher2:NodeDriver
    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 NodeDriverArgs
    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 NodeDriverArgs
    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 NodeDriverArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args NodeDriverArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args NodeDriverArgs
    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 nodeDriverResource = new Rancher2.NodeDriver("nodeDriverResource", new()
    {
        Active = false,
        Builtin = false,
        Url = "string",
        Annotations = 
        {
            { "string", "any" },
        },
        Checksum = "string",
        Description = "string",
        ExternalId = "string",
        Labels = 
        {
            { "string", "any" },
        },
        Name = "string",
        UiUrl = "string",
        WhitelistDomains = new[]
        {
            "string",
        },
    });
    
    example, err := rancher2.NewNodeDriver(ctx, "nodeDriverResource", &rancher2.NodeDriverArgs{
    	Active:  pulumi.Bool(false),
    	Builtin: pulumi.Bool(false),
    	Url:     pulumi.String("string"),
    	Annotations: pulumi.Map{
    		"string": pulumi.Any("any"),
    	},
    	Checksum:    pulumi.String("string"),
    	Description: pulumi.String("string"),
    	ExternalId:  pulumi.String("string"),
    	Labels: pulumi.Map{
    		"string": pulumi.Any("any"),
    	},
    	Name:  pulumi.String("string"),
    	UiUrl: pulumi.String("string"),
    	WhitelistDomains: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    })
    
    var nodeDriverResource = new NodeDriver("nodeDriverResource", NodeDriverArgs.builder()
        .active(false)
        .builtin(false)
        .url("string")
        .annotations(Map.of("string", "any"))
        .checksum("string")
        .description("string")
        .externalId("string")
        .labels(Map.of("string", "any"))
        .name("string")
        .uiUrl("string")
        .whitelistDomains("string")
        .build());
    
    node_driver_resource = rancher2.NodeDriver("nodeDriverResource",
        active=False,
        builtin=False,
        url="string",
        annotations={
            "string": "any",
        },
        checksum="string",
        description="string",
        external_id="string",
        labels={
            "string": "any",
        },
        name="string",
        ui_url="string",
        whitelist_domains=["string"])
    
    const nodeDriverResource = new rancher2.NodeDriver("nodeDriverResource", {
        active: false,
        builtin: false,
        url: "string",
        annotations: {
            string: "any",
        },
        checksum: "string",
        description: "string",
        externalId: "string",
        labels: {
            string: "any",
        },
        name: "string",
        uiUrl: "string",
        whitelistDomains: ["string"],
    });
    
    type: rancher2:NodeDriver
    properties:
        active: false
        annotations:
            string: any
        builtin: false
        checksum: string
        description: string
        externalId: string
        labels:
            string: any
        name: string
        uiUrl: string
        url: string
        whitelistDomains:
            - string
    

    NodeDriver Resource Properties

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

    Inputs

    The NodeDriver resource accepts the following input properties:

    Active bool
    Specify if the node driver state (bool)
    Builtin bool
    Specify wheter the node driver is an internal node driver or not (bool)
    Url string
    The URL to download the machine driver binary for 64-bit Linux (string)
    Annotations Dictionary<string, object>
    Annotations of the resource (map)
    Checksum string
    Verify that the downloaded driver matches the expected checksum (string)
    Description string
    Description of the node driver (string)
    ExternalId string
    External ID (string)
    Labels Dictionary<string, object>
    Labels of the resource (map)
    Name string
    Name of the node driver (string)
    UiUrl string
    The URL to load for customized Add Nodes screen for this driver (string)
    WhitelistDomains List<string>
    Domains to whitelist for the ui (list)
    Active bool
    Specify if the node driver state (bool)
    Builtin bool
    Specify wheter the node driver is an internal node driver or not (bool)
    Url string
    The URL to download the machine driver binary for 64-bit Linux (string)
    Annotations map[string]interface{}
    Annotations of the resource (map)
    Checksum string
    Verify that the downloaded driver matches the expected checksum (string)
    Description string
    Description of the node driver (string)
    ExternalId string
    External ID (string)
    Labels map[string]interface{}
    Labels of the resource (map)
    Name string
    Name of the node driver (string)
    UiUrl string
    The URL to load for customized Add Nodes screen for this driver (string)
    WhitelistDomains []string
    Domains to whitelist for the ui (list)
    active Boolean
    Specify if the node driver state (bool)
    builtin Boolean
    Specify wheter the node driver is an internal node driver or not (bool)
    url String
    The URL to download the machine driver binary for 64-bit Linux (string)
    annotations Map<String,Object>
    Annotations of the resource (map)
    checksum String
    Verify that the downloaded driver matches the expected checksum (string)
    description String
    Description of the node driver (string)
    externalId String
    External ID (string)
    labels Map<String,Object>
    Labels of the resource (map)
    name String
    Name of the node driver (string)
    uiUrl String
    The URL to load for customized Add Nodes screen for this driver (string)
    whitelistDomains List<String>
    Domains to whitelist for the ui (list)
    active boolean
    Specify if the node driver state (bool)
    builtin boolean
    Specify wheter the node driver is an internal node driver or not (bool)
    url string
    The URL to download the machine driver binary for 64-bit Linux (string)
    annotations {[key: string]: any}
    Annotations of the resource (map)
    checksum string
    Verify that the downloaded driver matches the expected checksum (string)
    description string
    Description of the node driver (string)
    externalId string
    External ID (string)
    labels {[key: string]: any}
    Labels of the resource (map)
    name string
    Name of the node driver (string)
    uiUrl string
    The URL to load for customized Add Nodes screen for this driver (string)
    whitelistDomains string[]
    Domains to whitelist for the ui (list)
    active bool
    Specify if the node driver state (bool)
    builtin bool
    Specify wheter the node driver is an internal node driver or not (bool)
    url str
    The URL to download the machine driver binary for 64-bit Linux (string)
    annotations Mapping[str, Any]
    Annotations of the resource (map)
    checksum str
    Verify that the downloaded driver matches the expected checksum (string)
    description str
    Description of the node driver (string)
    external_id str
    External ID (string)
    labels Mapping[str, Any]
    Labels of the resource (map)
    name str
    Name of the node driver (string)
    ui_url str
    The URL to load for customized Add Nodes screen for this driver (string)
    whitelist_domains Sequence[str]
    Domains to whitelist for the ui (list)
    active Boolean
    Specify if the node driver state (bool)
    builtin Boolean
    Specify wheter the node driver is an internal node driver or not (bool)
    url String
    The URL to download the machine driver binary for 64-bit Linux (string)
    annotations Map<Any>
    Annotations of the resource (map)
    checksum String
    Verify that the downloaded driver matches the expected checksum (string)
    description String
    Description of the node driver (string)
    externalId String
    External ID (string)
    labels Map<Any>
    Labels of the resource (map)
    name String
    Name of the node driver (string)
    uiUrl String
    The URL to load for customized Add Nodes screen for this driver (string)
    whitelistDomains List<String>
    Domains to whitelist for the ui (list)

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing NodeDriver Resource

    Get an existing NodeDriver resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: NodeDriverState, opts?: CustomResourceOptions): NodeDriver
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            active: Optional[bool] = None,
            annotations: Optional[Mapping[str, Any]] = None,
            builtin: Optional[bool] = None,
            checksum: Optional[str] = None,
            description: Optional[str] = None,
            external_id: Optional[str] = None,
            labels: Optional[Mapping[str, Any]] = None,
            name: Optional[str] = None,
            ui_url: Optional[str] = None,
            url: Optional[str] = None,
            whitelist_domains: Optional[Sequence[str]] = None) -> NodeDriver
    func GetNodeDriver(ctx *Context, name string, id IDInput, state *NodeDriverState, opts ...ResourceOption) (*NodeDriver, error)
    public static NodeDriver Get(string name, Input<string> id, NodeDriverState? state, CustomResourceOptions? opts = null)
    public static NodeDriver get(String name, Output<String> id, NodeDriverState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Active bool
    Specify if the node driver state (bool)
    Annotations Dictionary<string, object>
    Annotations of the resource (map)
    Builtin bool
    Specify wheter the node driver is an internal node driver or not (bool)
    Checksum string
    Verify that the downloaded driver matches the expected checksum (string)
    Description string
    Description of the node driver (string)
    ExternalId string
    External ID (string)
    Labels Dictionary<string, object>
    Labels of the resource (map)
    Name string
    Name of the node driver (string)
    UiUrl string
    The URL to load for customized Add Nodes screen for this driver (string)
    Url string
    The URL to download the machine driver binary for 64-bit Linux (string)
    WhitelistDomains List<string>
    Domains to whitelist for the ui (list)
    Active bool
    Specify if the node driver state (bool)
    Annotations map[string]interface{}
    Annotations of the resource (map)
    Builtin bool
    Specify wheter the node driver is an internal node driver or not (bool)
    Checksum string
    Verify that the downloaded driver matches the expected checksum (string)
    Description string
    Description of the node driver (string)
    ExternalId string
    External ID (string)
    Labels map[string]interface{}
    Labels of the resource (map)
    Name string
    Name of the node driver (string)
    UiUrl string
    The URL to load for customized Add Nodes screen for this driver (string)
    Url string
    The URL to download the machine driver binary for 64-bit Linux (string)
    WhitelistDomains []string
    Domains to whitelist for the ui (list)
    active Boolean
    Specify if the node driver state (bool)
    annotations Map<String,Object>
    Annotations of the resource (map)
    builtin Boolean
    Specify wheter the node driver is an internal node driver or not (bool)
    checksum String
    Verify that the downloaded driver matches the expected checksum (string)
    description String
    Description of the node driver (string)
    externalId String
    External ID (string)
    labels Map<String,Object>
    Labels of the resource (map)
    name String
    Name of the node driver (string)
    uiUrl String
    The URL to load for customized Add Nodes screen for this driver (string)
    url String
    The URL to download the machine driver binary for 64-bit Linux (string)
    whitelistDomains List<String>
    Domains to whitelist for the ui (list)
    active boolean
    Specify if the node driver state (bool)
    annotations {[key: string]: any}
    Annotations of the resource (map)
    builtin boolean
    Specify wheter the node driver is an internal node driver or not (bool)
    checksum string
    Verify that the downloaded driver matches the expected checksum (string)
    description string
    Description of the node driver (string)
    externalId string
    External ID (string)
    labels {[key: string]: any}
    Labels of the resource (map)
    name string
    Name of the node driver (string)
    uiUrl string
    The URL to load for customized Add Nodes screen for this driver (string)
    url string
    The URL to download the machine driver binary for 64-bit Linux (string)
    whitelistDomains string[]
    Domains to whitelist for the ui (list)
    active bool
    Specify if the node driver state (bool)
    annotations Mapping[str, Any]
    Annotations of the resource (map)
    builtin bool
    Specify wheter the node driver is an internal node driver or not (bool)
    checksum str
    Verify that the downloaded driver matches the expected checksum (string)
    description str
    Description of the node driver (string)
    external_id str
    External ID (string)
    labels Mapping[str, Any]
    Labels of the resource (map)
    name str
    Name of the node driver (string)
    ui_url str
    The URL to load for customized Add Nodes screen for this driver (string)
    url str
    The URL to download the machine driver binary for 64-bit Linux (string)
    whitelist_domains Sequence[str]
    Domains to whitelist for the ui (list)
    active Boolean
    Specify if the node driver state (bool)
    annotations Map<Any>
    Annotations of the resource (map)
    builtin Boolean
    Specify wheter the node driver is an internal node driver or not (bool)
    checksum String
    Verify that the downloaded driver matches the expected checksum (string)
    description String
    Description of the node driver (string)
    externalId String
    External ID (string)
    labels Map<Any>
    Labels of the resource (map)
    name String
    Name of the node driver (string)
    uiUrl String
    The URL to load for customized Add Nodes screen for this driver (string)
    url String
    The URL to download the machine driver binary for 64-bit Linux (string)
    whitelistDomains List<String>
    Domains to whitelist for the ui (list)

    Import

    Node Driver can be imported using the Rancher Node Driver ID

    $ pulumi import rancher2:index/nodeDriver:NodeDriver foo &lt;node_driver_id&gt;
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    Rancher2 pulumi/pulumi-rancher2
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the rancher2 Terraform Provider.
    rancher2 logo
    Rancher 2 v6.1.1 published on Friday, May 10, 2024 by Pulumi