avi.Snmptrapprofile
Explore with Pulumi AI
<!–
Copyright 2021 VMware, Inc.
SPDX-License-Identifier: Mozilla Public License 2.0
–>
layout: “avi”
page_title: “Avi: avi.Snmptrapprofile” sidebar_current: “docs-avi-resource-snmptrapprofile” description: |- Creates and manages Avi SnmpTrapProfile.
avi.Snmptrapprofile
The SnmpTrapProfile resource allows the creation and management of Avi SnmpTrapProfile
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as avi from "@pulumi/avi";
const foo = new avi.Snmptrapprofile("foo", {tenantRef: "/api/tenant/?name=admin"});
import pulumi
import pulumi_avi as avi
foo = avi.Snmptrapprofile("foo", tenant_ref="/api/tenant/?name=admin")
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/avi/v31/avi"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := avi.NewSnmptrapprofile(ctx, "foo", &avi.SnmptrapprofileArgs{
TenantRef: pulumi.String("/api/tenant/?name=admin"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Avi = Pulumi.Avi;
return await Deployment.RunAsync(() =>
{
var foo = new Avi.Snmptrapprofile("foo", new()
{
TenantRef = "/api/tenant/?name=admin",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.avi.Snmptrapprofile;
import com.pulumi.avi.SnmptrapprofileArgs;
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 foo = new Snmptrapprofile("foo", SnmptrapprofileArgs.builder()
.tenantRef("/api/tenant/?name=admin")
.build());
}
}
resources:
foo:
type: avi:Snmptrapprofile
properties:
tenantRef: /api/tenant/?name=admin
Create Snmptrapprofile Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Snmptrapprofile(name: string, args?: SnmptrapprofileArgs, opts?: CustomResourceOptions);
@overload
def Snmptrapprofile(resource_name: str,
args: Optional[SnmptrapprofileArgs] = None,
opts: Optional[ResourceOptions] = None)
@overload
def Snmptrapprofile(resource_name: str,
opts: Optional[ResourceOptions] = None,
configpb_attributes: Optional[Sequence[SnmptrapprofileConfigpbAttributeArgs]] = None,
name: Optional[str] = None,
snmptrapprofile_id: Optional[str] = None,
tenant_ref: Optional[str] = None,
trap_servers: Optional[Sequence[SnmptrapprofileTrapServerArgs]] = None,
uuid: Optional[str] = None)
func NewSnmptrapprofile(ctx *Context, name string, args *SnmptrapprofileArgs, opts ...ResourceOption) (*Snmptrapprofile, error)
public Snmptrapprofile(string name, SnmptrapprofileArgs? args = null, CustomResourceOptions? opts = null)
public Snmptrapprofile(String name, SnmptrapprofileArgs args)
public Snmptrapprofile(String name, SnmptrapprofileArgs args, CustomResourceOptions options)
type: avi:Snmptrapprofile
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 SnmptrapprofileArgs
- 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 SnmptrapprofileArgs
- 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 SnmptrapprofileArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SnmptrapprofileArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args SnmptrapprofileArgs
- 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 snmptrapprofileResource = new Avi.Snmptrapprofile("snmptrapprofileResource", new()
{
ConfigpbAttributes = new[]
{
new Avi.Inputs.SnmptrapprofileConfigpbAttributeArgs
{
Version = "string",
},
},
Name = "string",
SnmptrapprofileId = "string",
TenantRef = "string",
TrapServers = new[]
{
new Avi.Inputs.SnmptrapprofileTrapServerArgs
{
IpAddrs = new[]
{
new Avi.Inputs.SnmptrapprofileTrapServerIpAddrArgs
{
Addr = "string",
Type = "string",
},
},
Community = "string",
Port = "string",
Users = new[]
{
new Avi.Inputs.SnmptrapprofileTrapServerUserArgs
{
AuthPassphrase = "string",
AuthType = "string",
PrivPassphrase = "string",
PrivType = "string",
Username = "string",
},
},
Version = "string",
},
},
Uuid = "string",
});
example, err := avi.NewSnmptrapprofile(ctx, "snmptrapprofileResource", &avi.SnmptrapprofileArgs{
ConfigpbAttributes: avi.SnmptrapprofileConfigpbAttributeArray{
&avi.SnmptrapprofileConfigpbAttributeArgs{
Version: pulumi.String("string"),
},
},
Name: pulumi.String("string"),
SnmptrapprofileId: pulumi.String("string"),
TenantRef: pulumi.String("string"),
TrapServers: avi.SnmptrapprofileTrapServerArray{
&avi.SnmptrapprofileTrapServerArgs{
IpAddrs: avi.SnmptrapprofileTrapServerIpAddrArray{
&avi.SnmptrapprofileTrapServerIpAddrArgs{
Addr: pulumi.String("string"),
Type: pulumi.String("string"),
},
},
Community: pulumi.String("string"),
Port: pulumi.String("string"),
Users: avi.SnmptrapprofileTrapServerUserArray{
&avi.SnmptrapprofileTrapServerUserArgs{
AuthPassphrase: pulumi.String("string"),
AuthType: pulumi.String("string"),
PrivPassphrase: pulumi.String("string"),
PrivType: pulumi.String("string"),
Username: pulumi.String("string"),
},
},
Version: pulumi.String("string"),
},
},
Uuid: pulumi.String("string"),
})
var snmptrapprofileResource = new Snmptrapprofile("snmptrapprofileResource", SnmptrapprofileArgs.builder()
.configpbAttributes(SnmptrapprofileConfigpbAttributeArgs.builder()
.version("string")
.build())
.name("string")
.snmptrapprofileId("string")
.tenantRef("string")
.trapServers(SnmptrapprofileTrapServerArgs.builder()
.ipAddrs(SnmptrapprofileTrapServerIpAddrArgs.builder()
.addr("string")
.type("string")
.build())
.community("string")
.port("string")
.users(SnmptrapprofileTrapServerUserArgs.builder()
.authPassphrase("string")
.authType("string")
.privPassphrase("string")
.privType("string")
.username("string")
.build())
.version("string")
.build())
.uuid("string")
.build());
snmptrapprofile_resource = avi.Snmptrapprofile("snmptrapprofileResource",
configpb_attributes=[{
"version": "string",
}],
name="string",
snmptrapprofile_id="string",
tenant_ref="string",
trap_servers=[{
"ip_addrs": [{
"addr": "string",
"type": "string",
}],
"community": "string",
"port": "string",
"users": [{
"auth_passphrase": "string",
"auth_type": "string",
"priv_passphrase": "string",
"priv_type": "string",
"username": "string",
}],
"version": "string",
}],
uuid="string")
const snmptrapprofileResource = new avi.Snmptrapprofile("snmptrapprofileResource", {
configpbAttributes: [{
version: "string",
}],
name: "string",
snmptrapprofileId: "string",
tenantRef: "string",
trapServers: [{
ipAddrs: [{
addr: "string",
type: "string",
}],
community: "string",
port: "string",
users: [{
authPassphrase: "string",
authType: "string",
privPassphrase: "string",
privType: "string",
username: "string",
}],
version: "string",
}],
uuid: "string",
});
type: avi:Snmptrapprofile
properties:
configpbAttributes:
- version: string
name: string
snmptrapprofileId: string
tenantRef: string
trapServers:
- community: string
ipAddrs:
- addr: string
type: string
port: string
users:
- authPassphrase: string
authType: string
privPassphrase: string
privType: string
username: string
version: string
uuid: string
Snmptrapprofile 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 Snmptrapprofile resource accepts the following input properties:
- Configpb
Attributes List<SnmptrapprofileConfigpb Attribute> - Protobuf versioning for config pbs. Field introduced in 21.1.1. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Name string
- A user-friendly name of the snmp trap configuration. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Snmptrapprofile
Id string - Tenant
Ref string - It is a reference to an object of type tenant. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Trap
Servers List<SnmptrapprofileTrap Server> - The ip address or hostname of the snmp trap destination server. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Uuid string
- Uuid of the snmp trap profile object. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Configpb
Attributes []SnmptrapprofileConfigpb Attribute Args - Protobuf versioning for config pbs. Field introduced in 21.1.1. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Name string
- A user-friendly name of the snmp trap configuration. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Snmptrapprofile
Id string - Tenant
Ref string - It is a reference to an object of type tenant. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Trap
Servers []SnmptrapprofileTrap Server Args - The ip address or hostname of the snmp trap destination server. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Uuid string
- Uuid of the snmp trap profile object. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- configpb
Attributes List<SnmptrapprofileConfigpb Attribute> - Protobuf versioning for config pbs. Field introduced in 21.1.1. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- name String
- A user-friendly name of the snmp trap configuration. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- snmptrapprofile
Id String - tenant
Ref String - It is a reference to an object of type tenant. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- trap
Servers List<SnmptrapprofileTrap Server> - The ip address or hostname of the snmp trap destination server. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- uuid String
- Uuid of the snmp trap profile object. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- configpb
Attributes SnmptrapprofileConfigpb Attribute[] - Protobuf versioning for config pbs. Field introduced in 21.1.1. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- name string
- A user-friendly name of the snmp trap configuration. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- snmptrapprofile
Id string - tenant
Ref string - It is a reference to an object of type tenant. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- trap
Servers SnmptrapprofileTrap Server[] - The ip address or hostname of the snmp trap destination server. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- uuid string
- Uuid of the snmp trap profile object. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- configpb_
attributes Sequence[SnmptrapprofileConfigpb Attribute Args] - Protobuf versioning for config pbs. Field introduced in 21.1.1. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- name str
- A user-friendly name of the snmp trap configuration. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- snmptrapprofile_
id str - tenant_
ref str - It is a reference to an object of type tenant. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- trap_
servers Sequence[SnmptrapprofileTrap Server Args] - The ip address or hostname of the snmp trap destination server. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- uuid str
- Uuid of the snmp trap profile object. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- configpb
Attributes List<Property Map> - Protobuf versioning for config pbs. Field introduced in 21.1.1. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- name String
- A user-friendly name of the snmp trap configuration. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- snmptrapprofile
Id String - tenant
Ref String - It is a reference to an object of type tenant. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- trap
Servers List<Property Map> - The ip address or hostname of the snmp trap destination server. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- uuid String
- Uuid of the snmp trap profile object. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
Outputs
All input properties are implicitly available as output properties. Additionally, the Snmptrapprofile 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 Snmptrapprofile Resource
Get an existing Snmptrapprofile 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?: SnmptrapprofileState, opts?: CustomResourceOptions): Snmptrapprofile
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
configpb_attributes: Optional[Sequence[SnmptrapprofileConfigpbAttributeArgs]] = None,
name: Optional[str] = None,
snmptrapprofile_id: Optional[str] = None,
tenant_ref: Optional[str] = None,
trap_servers: Optional[Sequence[SnmptrapprofileTrapServerArgs]] = None,
uuid: Optional[str] = None) -> Snmptrapprofile
func GetSnmptrapprofile(ctx *Context, name string, id IDInput, state *SnmptrapprofileState, opts ...ResourceOption) (*Snmptrapprofile, error)
public static Snmptrapprofile Get(string name, Input<string> id, SnmptrapprofileState? state, CustomResourceOptions? opts = null)
public static Snmptrapprofile get(String name, Output<String> id, SnmptrapprofileState state, CustomResourceOptions options)
resources: _: type: avi:Snmptrapprofile get: id: ${id}
- 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.
- Configpb
Attributes List<SnmptrapprofileConfigpb Attribute> - Protobuf versioning for config pbs. Field introduced in 21.1.1. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Name string
- A user-friendly name of the snmp trap configuration. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Snmptrapprofile
Id string - Tenant
Ref string - It is a reference to an object of type tenant. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Trap
Servers List<SnmptrapprofileTrap Server> - The ip address or hostname of the snmp trap destination server. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Uuid string
- Uuid of the snmp trap profile object. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Configpb
Attributes []SnmptrapprofileConfigpb Attribute Args - Protobuf versioning for config pbs. Field introduced in 21.1.1. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Name string
- A user-friendly name of the snmp trap configuration. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Snmptrapprofile
Id string - Tenant
Ref string - It is a reference to an object of type tenant. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Trap
Servers []SnmptrapprofileTrap Server Args - The ip address or hostname of the snmp trap destination server. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- Uuid string
- Uuid of the snmp trap profile object. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- configpb
Attributes List<SnmptrapprofileConfigpb Attribute> - Protobuf versioning for config pbs. Field introduced in 21.1.1. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- name String
- A user-friendly name of the snmp trap configuration. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- snmptrapprofile
Id String - tenant
Ref String - It is a reference to an object of type tenant. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- trap
Servers List<SnmptrapprofileTrap Server> - The ip address or hostname of the snmp trap destination server. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- uuid String
- Uuid of the snmp trap profile object. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- configpb
Attributes SnmptrapprofileConfigpb Attribute[] - Protobuf versioning for config pbs. Field introduced in 21.1.1. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- name string
- A user-friendly name of the snmp trap configuration. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- snmptrapprofile
Id string - tenant
Ref string - It is a reference to an object of type tenant. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- trap
Servers SnmptrapprofileTrap Server[] - The ip address or hostname of the snmp trap destination server. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- uuid string
- Uuid of the snmp trap profile object. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- configpb_
attributes Sequence[SnmptrapprofileConfigpb Attribute Args] - Protobuf versioning for config pbs. Field introduced in 21.1.1. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- name str
- A user-friendly name of the snmp trap configuration. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- snmptrapprofile_
id str - tenant_
ref str - It is a reference to an object of type tenant. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- trap_
servers Sequence[SnmptrapprofileTrap Server Args] - The ip address or hostname of the snmp trap destination server. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- uuid str
- Uuid of the snmp trap profile object. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- configpb
Attributes List<Property Map> - Protobuf versioning for config pbs. Field introduced in 21.1.1. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- name String
- A user-friendly name of the snmp trap configuration. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- snmptrapprofile
Id String - tenant
Ref String - It is a reference to an object of type tenant. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- trap
Servers List<Property Map> - The ip address or hostname of the snmp trap destination server. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
- uuid String
- Uuid of the snmp trap profile object. Allowed with any value in enterprise, essentials, basic, enterprise with cloud services edition.
Supporting Types
SnmptrapprofileConfigpbAttribute, SnmptrapprofileConfigpbAttributeArgs
- Version string
- Version string
- version String
- version string
- version str
- version String
SnmptrapprofileTrapServer, SnmptrapprofileTrapServerArgs
- ip
Addrs List<Property Map> - community String
- port String
- users List<Property Map>
- version String
SnmptrapprofileTrapServerIpAddr, SnmptrapprofileTrapServerIpAddrArgs
SnmptrapprofileTrapServerUser, SnmptrapprofileTrapServerUserArgs
- Auth
Passphrase string - Auth
Type string - Priv
Passphrase string - Priv
Type string - Username string
- Auth
Passphrase string - Auth
Type string - Priv
Passphrase string - Priv
Type string - Username string
- auth
Passphrase String - auth
Type String - priv
Passphrase String - priv
Type String - username String
- auth
Passphrase string - auth
Type string - priv
Passphrase string - priv
Type string - username string
- auth_
passphrase str - auth_
type str - priv_
passphrase str - priv_
type str - username str
- auth
Passphrase String - auth
Type String - priv
Passphrase String - priv
Type String - username String
Package Details
- Repository
- avi vmware/terraform-provider-avi
- License
- Notes
- This Pulumi package is based on the
avi
Terraform Provider.