sdwan.PortListPolicyObject
Explore with Pulumi AI
This resource can manage a Port List Policy Object .
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as sdwan from "@pulumi/sdwan";
const example = new sdwan.PortListPolicyObject("example", {
name: "Example",
entries: [{
port: 80,
}],
});
import pulumi
import pulumi_sdwan as sdwan
example = sdwan.PortListPolicyObject("example",
name="Example",
entries=[{
"port": 80,
}])
package main
import (
"github.com/pulumi/pulumi-sdwan/sdk/go/sdwan"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := sdwan.NewPortListPolicyObject(ctx, "example", &sdwan.PortListPolicyObjectArgs{
Name: pulumi.String("Example"),
Entries: sdwan.PortListPolicyObjectEntryArray{
&sdwan.PortListPolicyObjectEntryArgs{
Port: pulumi.Int(80),
},
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Sdwan = Pulumi.Sdwan;
return await Deployment.RunAsync(() =>
{
var example = new Sdwan.PortListPolicyObject("example", new()
{
Name = "Example",
Entries = new[]
{
new Sdwan.Inputs.PortListPolicyObjectEntryArgs
{
Port = 80,
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.sdwan.PortListPolicyObject;
import com.pulumi.sdwan.PortListPolicyObjectArgs;
import com.pulumi.sdwan.inputs.PortListPolicyObjectEntryArgs;
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) {
var example = new PortListPolicyObject("example", PortListPolicyObjectArgs.builder()
.name("Example")
.entries(PortListPolicyObjectEntryArgs.builder()
.port(80)
.build())
.build());
}
}
resources:
example:
type: sdwan:PortListPolicyObject
properties:
name: Example
entries:
- port: 80
Create PortListPolicyObject Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new PortListPolicyObject(name: string, args: PortListPolicyObjectArgs, opts?: CustomResourceOptions);
@overload
def PortListPolicyObject(resource_name: str,
args: PortListPolicyObjectArgs,
opts: Optional[ResourceOptions] = None)
@overload
def PortListPolicyObject(resource_name: str,
opts: Optional[ResourceOptions] = None,
entries: Optional[Sequence[PortListPolicyObjectEntryArgs]] = None,
name: Optional[str] = None)
func NewPortListPolicyObject(ctx *Context, name string, args PortListPolicyObjectArgs, opts ...ResourceOption) (*PortListPolicyObject, error)
public PortListPolicyObject(string name, PortListPolicyObjectArgs args, CustomResourceOptions? opts = null)
public PortListPolicyObject(String name, PortListPolicyObjectArgs args)
public PortListPolicyObject(String name, PortListPolicyObjectArgs args, CustomResourceOptions options)
type: sdwan:PortListPolicyObject
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 PortListPolicyObjectArgs
- 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 PortListPolicyObjectArgs
- 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 PortListPolicyObjectArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args PortListPolicyObjectArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args PortListPolicyObjectArgs
- 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 portListPolicyObjectResource = new Sdwan.PortListPolicyObject("portListPolicyObjectResource", new()
{
Entries = new[]
{
new Sdwan.Inputs.PortListPolicyObjectEntryArgs
{
Port = 0,
},
},
Name = "string",
});
example, err := sdwan.NewPortListPolicyObject(ctx, "portListPolicyObjectResource", &sdwan.PortListPolicyObjectArgs{
Entries: sdwan.PortListPolicyObjectEntryArray{
&sdwan.PortListPolicyObjectEntryArgs{
Port: pulumi.Int(0),
},
},
Name: pulumi.String("string"),
})
var portListPolicyObjectResource = new PortListPolicyObject("portListPolicyObjectResource", PortListPolicyObjectArgs.builder()
.entries(PortListPolicyObjectEntryArgs.builder()
.port(0)
.build())
.name("string")
.build());
port_list_policy_object_resource = sdwan.PortListPolicyObject("portListPolicyObjectResource",
entries=[sdwan.PortListPolicyObjectEntryArgs(
port=0,
)],
name="string")
const portListPolicyObjectResource = new sdwan.PortListPolicyObject("portListPolicyObjectResource", {
entries: [{
port: 0,
}],
name: "string",
});
type: sdwan:PortListPolicyObject
properties:
entries:
- port: 0
name: string
PortListPolicyObject 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 PortListPolicyObject resource accepts the following input properties:
- Entries
List<Port
List Policy Object Entry> - List of entries
- Name string
- The name of the policy object
- Entries
[]Port
List Policy Object Entry Args - List of entries
- Name string
- The name of the policy object
- entries
List<Port
List Policy Object Entry> - List of entries
- name String
- The name of the policy object
- entries
Port
List Policy Object Entry[] - List of entries
- name string
- The name of the policy object
- entries
Sequence[Port
List Policy Object Entry Args] - List of entries
- name str
- The name of the policy object
- entries List<Property Map>
- List of entries
- name String
- The name of the policy object
Outputs
All input properties are implicitly available as output properties. Additionally, the PortListPolicyObject resource produces the following output properties:
Look up Existing PortListPolicyObject Resource
Get an existing PortListPolicyObject 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?: PortListPolicyObjectState, opts?: CustomResourceOptions): PortListPolicyObject
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
entries: Optional[Sequence[PortListPolicyObjectEntryArgs]] = None,
name: Optional[str] = None,
version: Optional[int] = None) -> PortListPolicyObject
func GetPortListPolicyObject(ctx *Context, name string, id IDInput, state *PortListPolicyObjectState, opts ...ResourceOption) (*PortListPolicyObject, error)
public static PortListPolicyObject Get(string name, Input<string> id, PortListPolicyObjectState? state, CustomResourceOptions? opts = null)
public static PortListPolicyObject get(String name, Output<String> id, PortListPolicyObjectState 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.
- Entries
List<Port
List Policy Object Entry> - List of entries
- Name string
- The name of the policy object
- Version int
- The version of the object
- Entries
[]Port
List Policy Object Entry Args - List of entries
- Name string
- The name of the policy object
- Version int
- The version of the object
- entries
List<Port
List Policy Object Entry> - List of entries
- name String
- The name of the policy object
- version Integer
- The version of the object
- entries
Port
List Policy Object Entry[] - List of entries
- name string
- The name of the policy object
- version number
- The version of the object
- entries
Sequence[Port
List Policy Object Entry Args] - List of entries
- name str
- The name of the policy object
- version int
- The version of the object
- entries List<Property Map>
- List of entries
- name String
- The name of the policy object
- version Number
- The version of the object
Supporting Types
PortListPolicyObjectEntry, PortListPolicyObjectEntryArgs
- Port int
- Port number
- Range:
1
-65535
- Range:
- Port int
- Port number
- Range:
1
-65535
- Range:
- port Integer
- Port number
- Range:
1
-65535
- Range:
- port number
- Port number
- Range:
1
-65535
- Range:
- port int
- Port number
- Range:
1
-65535
- Range:
- port Number
- Port number
- Range:
1
-65535
- Range:
Import
$ pulumi import sdwan:index/portListPolicyObject:PortListPolicyObject example "f6b2c44c-693c-4763-b010-895aa3d236bd"
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- sdwan pulumi/pulumi-sdwan
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
sdwan
Terraform Provider.