panos.Service
Explore with Pulumi AI
Example Usage
Coming soon!
Coming soon!
Coming soon!
Coming soon!
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.panos.DeviceGroup;
import com.pulumi.panos.DeviceGroupArgs;
import com.pulumi.panos.inputs.DeviceGroupLocationArgs;
import com.pulumi.panos.inputs.DeviceGroupLocationPanoramaArgs;
import com.pulumi.panos.Service;
import com.pulumi.panos.ServiceArgs;
import com.pulumi.panos.inputs.ServiceLocationArgs;
import com.pulumi.panos.inputs.ServiceProtocolArgs;
import com.pulumi.panos.inputs.ServiceProtocolTcpArgs;
import com.pulumi.panos.inputs.ServiceProtocolTcpOverrideArgs;
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 exampleDeviceGroup = new DeviceGroup("exampleDeviceGroup", DeviceGroupArgs.builder()
.location(DeviceGroupLocationArgs.builder()
.panorama()
.build())
.build());
var exampleService = new Service("exampleService", ServiceArgs.builder()
.location(ServiceLocationArgs.builder()
.device_group(%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference))
.build())
.description("example service")
.protocol(ServiceProtocolArgs.builder()
.tcp(ServiceProtocolTcpArgs.builder()
.destinationPort("80")
.override(ServiceProtocolTcpOverrideArgs.builder()
.timeout(600)
.halfcloseTimeout(300)
.timewaitTimeout(60)
.build())
.build())
.build())
.build());
}
}
resources:
exampleService:
type: panos:Service
properties:
location:
device_group:
name: ${exampleDeviceGroup.name}
description: example service
protocol:
tcp:
destinationPort: '80'
override:
timeout: 600
halfcloseTimeout: 300
timewaitTimeout: 60
exampleDeviceGroup:
type: panos:DeviceGroup
properties:
location:
panorama: {}
Create Service Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Service(name: string, args: ServiceArgs, opts?: CustomResourceOptions);
@overload
def Service(resource_name: str,
args: ServiceArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Service(resource_name: str,
opts: Optional[ResourceOptions] = None,
location: Optional[ServiceLocationArgs] = None,
description: Optional[str] = None,
disable_override: Optional[str] = None,
name: Optional[str] = None,
protocol: Optional[ServiceProtocolArgs] = None,
tags: Optional[Sequence[str]] = None)
func NewService(ctx *Context, name string, args ServiceArgs, opts ...ResourceOption) (*Service, error)
public Service(string name, ServiceArgs args, CustomResourceOptions? opts = null)
public Service(String name, ServiceArgs args)
public Service(String name, ServiceArgs args, CustomResourceOptions options)
type: panos:Service
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 ServiceArgs
- 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 ServiceArgs
- 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 ServiceArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ServiceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ServiceArgs
- 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 serviceResource = new Panos.Service("serviceResource", new()
{
Location = new Panos.Inputs.ServiceLocationArgs
{
DeviceGroup = new Panos.Inputs.ServiceLocationDeviceGroupArgs
{
Name = "string",
PanoramaDevice = "string",
},
Shared = null,
Vsys = new Panos.Inputs.ServiceLocationVsysArgs
{
Name = "string",
NgfwDevice = "string",
},
},
Description = "string",
DisableOverride = "string",
Name = "string",
Protocol = new Panos.Inputs.ServiceProtocolArgs
{
Tcp = new Panos.Inputs.ServiceProtocolTcpArgs
{
DestinationPort = "string",
Override = new Panos.Inputs.ServiceProtocolTcpOverrideArgs
{
HalfcloseTimeout = 0,
Timeout = 0,
TimewaitTimeout = 0,
},
SourcePort = "string",
},
Udp = new Panos.Inputs.ServiceProtocolUdpArgs
{
DestinationPort = "string",
Override = new Panos.Inputs.ServiceProtocolUdpOverrideArgs
{
Timeout = 0,
},
SourcePort = "string",
},
},
Tags = new[]
{
"string",
},
});
example, err := panos.NewService(ctx, "serviceResource", &panos.ServiceArgs{
Location: &panos.ServiceLocationArgs{
DeviceGroup: &panos.ServiceLocationDeviceGroupArgs{
Name: pulumi.String("string"),
PanoramaDevice: pulumi.String("string"),
},
Shared: &panos.ServiceLocationSharedArgs{},
Vsys: &panos.ServiceLocationVsysArgs{
Name: pulumi.String("string"),
NgfwDevice: pulumi.String("string"),
},
},
Description: pulumi.String("string"),
DisableOverride: pulumi.String("string"),
Name: pulumi.String("string"),
Protocol: &panos.ServiceProtocolArgs{
Tcp: &panos.ServiceProtocolTcpArgs{
DestinationPort: pulumi.String("string"),
Override: &panos.ServiceProtocolTcpOverrideArgs{
HalfcloseTimeout: pulumi.Float64(0),
Timeout: pulumi.Float64(0),
TimewaitTimeout: pulumi.Float64(0),
},
SourcePort: pulumi.String("string"),
},
Udp: &panos.ServiceProtocolUdpArgs{
DestinationPort: pulumi.String("string"),
Override: &panos.ServiceProtocolUdpOverrideArgs{
Timeout: pulumi.Float64(0),
},
SourcePort: pulumi.String("string"),
},
},
Tags: pulumi.StringArray{
pulumi.String("string"),
},
})
var serviceResource = new Service("serviceResource", ServiceArgs.builder()
.location(ServiceLocationArgs.builder()
.deviceGroup(ServiceLocationDeviceGroupArgs.builder()
.name("string")
.panoramaDevice("string")
.build())
.shared()
.vsys(ServiceLocationVsysArgs.builder()
.name("string")
.ngfwDevice("string")
.build())
.build())
.description("string")
.disableOverride("string")
.name("string")
.protocol(ServiceProtocolArgs.builder()
.tcp(ServiceProtocolTcpArgs.builder()
.destinationPort("string")
.override(ServiceProtocolTcpOverrideArgs.builder()
.halfcloseTimeout(0)
.timeout(0)
.timewaitTimeout(0)
.build())
.sourcePort("string")
.build())
.udp(ServiceProtocolUdpArgs.builder()
.destinationPort("string")
.override(ServiceProtocolUdpOverrideArgs.builder()
.timeout(0)
.build())
.sourcePort("string")
.build())
.build())
.tags("string")
.build());
service_resource = panos.Service("serviceResource",
location={
"device_group": {
"name": "string",
"panorama_device": "string",
},
"shared": {},
"vsys": {
"name": "string",
"ngfw_device": "string",
},
},
description="string",
disable_override="string",
name="string",
protocol={
"tcp": {
"destination_port": "string",
"override": {
"halfclose_timeout": 0,
"timeout": 0,
"timewait_timeout": 0,
},
"source_port": "string",
},
"udp": {
"destination_port": "string",
"override": {
"timeout": 0,
},
"source_port": "string",
},
},
tags=["string"])
const serviceResource = new panos.Service("serviceResource", {
location: {
deviceGroup: {
name: "string",
panoramaDevice: "string",
},
shared: {},
vsys: {
name: "string",
ngfwDevice: "string",
},
},
description: "string",
disableOverride: "string",
name: "string",
protocol: {
tcp: {
destinationPort: "string",
override: {
halfcloseTimeout: 0,
timeout: 0,
timewaitTimeout: 0,
},
sourcePort: "string",
},
udp: {
destinationPort: "string",
override: {
timeout: 0,
},
sourcePort: "string",
},
},
tags: ["string"],
});
type: panos:Service
properties:
description: string
disableOverride: string
location:
deviceGroup:
name: string
panoramaDevice: string
shared: {}
vsys:
name: string
ngfwDevice: string
name: string
protocol:
tcp:
destinationPort: string
override:
halfcloseTimeout: 0
timeout: 0
timewaitTimeout: 0
sourcePort: string
udp:
destinationPort: string
override:
timeout: 0
sourcePort: string
tags:
- string
Service 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 Service resource accepts the following input properties:
- Location
Service
Location - The location of this object.
- Description string
- Disable
Override string - disable object override in child device groups
- Name string
- Protocol
Service
Protocol - List<string>
- Location
Service
Location Args - The location of this object.
- Description string
- Disable
Override string - disable object override in child device groups
- Name string
- Protocol
Service
Protocol Args - []string
- location
Service
Location - The location of this object.
- description String
- disable
Override String - disable object override in child device groups
- name String
- protocol
Service
Protocol - List<String>
- location
Service
Location - The location of this object.
- description string
- disable
Override string - disable object override in child device groups
- name string
- protocol
Service
Protocol - string[]
- location
Service
Location Args - The location of this object.
- description str
- disable_
override str - disable object override in child device groups
- name str
- protocol
Service
Protocol Args - Sequence[str]
- location Property Map
- The location of this object.
- description String
- disable
Override String - disable object override in child device groups
- name String
- protocol Property Map
- List<String>
Outputs
All input properties are implicitly available as output properties. Additionally, the Service 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 Service Resource
Get an existing Service 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?: ServiceState, opts?: CustomResourceOptions): Service
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
description: Optional[str] = None,
disable_override: Optional[str] = None,
location: Optional[ServiceLocationArgs] = None,
name: Optional[str] = None,
protocol: Optional[ServiceProtocolArgs] = None,
tags: Optional[Sequence[str]] = None) -> Service
func GetService(ctx *Context, name string, id IDInput, state *ServiceState, opts ...ResourceOption) (*Service, error)
public static Service Get(string name, Input<string> id, ServiceState? state, CustomResourceOptions? opts = null)
public static Service get(String name, Output<String> id, ServiceState state, CustomResourceOptions options)
resources: _: type: panos:Service 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.
- Description string
- Disable
Override string - disable object override in child device groups
- Location
Service
Location - The location of this object.
- Name string
- Protocol
Service
Protocol - List<string>
- Description string
- Disable
Override string - disable object override in child device groups
- Location
Service
Location Args - The location of this object.
- Name string
- Protocol
Service
Protocol Args - []string
- description String
- disable
Override String - disable object override in child device groups
- location
Service
Location - The location of this object.
- name String
- protocol
Service
Protocol - List<String>
- description string
- disable
Override string - disable object override in child device groups
- location
Service
Location - The location of this object.
- name string
- protocol
Service
Protocol - string[]
- description str
- disable_
override str - disable object override in child device groups
- location
Service
Location Args - The location of this object.
- name str
- protocol
Service
Protocol Args - Sequence[str]
- description String
- disable
Override String - disable object override in child device groups
- location Property Map
- The location of this object.
- name String
- protocol Property Map
- List<String>
Supporting Types
ServiceLocation, ServiceLocationArgs
- Device
Group ServiceLocation Device Group - Located in a specific Device Group
- Service
Location Shared - Panorama shared object
- Vsys
Service
Location Vsys - Located in a specific Virtual System
- Device
Group ServiceLocation Device Group - Located in a specific Device Group
- Service
Location Shared - Panorama shared object
- Vsys
Service
Location Vsys - Located in a specific Virtual System
- device
Group ServiceLocation Device Group - Located in a specific Device Group
- Service
Location Shared - Panorama shared object
- vsys
Service
Location Vsys - Located in a specific Virtual System
- device
Group ServiceLocation Device Group - Located in a specific Device Group
- Service
Location Shared - Panorama shared object
- vsys
Service
Location Vsys - Located in a specific Virtual System
- device_
group ServiceLocation Device Group - Located in a specific Device Group
- Service
Location Shared - Panorama shared object
- vsys
Service
Location Vsys - Located in a specific Virtual System
- device
Group Property Map - Located in a specific Device Group
- Property Map
- Panorama shared object
- vsys Property Map
- Located in a specific Virtual System
ServiceLocationDeviceGroup, ServiceLocationDeviceGroupArgs
- Name string
- Device Group name
- Panorama
Device string - Panorama device name
- Name string
- Device Group name
- Panorama
Device string - Panorama device name
- name String
- Device Group name
- panorama
Device String - Panorama device name
- name string
- Device Group name
- panorama
Device string - Panorama device name
- name str
- Device Group name
- panorama_
device str - Panorama device name
- name String
- Device Group name
- panorama
Device String - Panorama device name
ServiceLocationVsys, ServiceLocationVsysArgs
- Name string
- The Virtual System name
- Ngfw
Device string - The NGFW device name
- Name string
- The Virtual System name
- Ngfw
Device string - The NGFW device name
- name String
- The Virtual System name
- ngfw
Device String - The NGFW device name
- name string
- The Virtual System name
- ngfw
Device string - The NGFW device name
- name str
- The Virtual System name
- ngfw_
device str - The NGFW device name
- name String
- The Virtual System name
- ngfw
Device String - The NGFW device name
ServiceProtocol, ServiceProtocolArgs
ServiceProtocolTcp, ServiceProtocolTcpArgs
- Destination
Port string - Override
Service
Protocol Tcp Override - Source
Port string
- Destination
Port string - Override
Service
Protocol Tcp Override - Source
Port string
- destination
Port String - override
Service
Protocol Tcp Override - source
Port String
- destination
Port string - override
Service
Protocol Tcp Override - source
Port string
- destination
Port String - override Property Map
- source
Port String
ServiceProtocolTcpOverride, ServiceProtocolTcpOverrideArgs
- Halfclose
Timeout double - tcp session half-close timeout value (in second)
- Timeout double
- tcp session timeout value (in second)
- Timewait
Timeout double - tcp session time-wait timeout value (in second)
- Halfclose
Timeout float64 - tcp session half-close timeout value (in second)
- Timeout float64
- tcp session timeout value (in second)
- Timewait
Timeout float64 - tcp session time-wait timeout value (in second)
- halfclose
Timeout Double - tcp session half-close timeout value (in second)
- timeout Double
- tcp session timeout value (in second)
- timewait
Timeout Double - tcp session time-wait timeout value (in second)
- halfclose
Timeout number - tcp session half-close timeout value (in second)
- timeout number
- tcp session timeout value (in second)
- timewait
Timeout number - tcp session time-wait timeout value (in second)
- halfclose_
timeout float - tcp session half-close timeout value (in second)
- timeout float
- tcp session timeout value (in second)
- timewait_
timeout float - tcp session time-wait timeout value (in second)
- halfclose
Timeout Number - tcp session half-close timeout value (in second)
- timeout Number
- tcp session timeout value (in second)
- timewait
Timeout Number - tcp session time-wait timeout value (in second)
ServiceProtocolUdp, ServiceProtocolUdpArgs
- Destination
Port string - Override
Service
Protocol Udp Override - Source
Port string
- Destination
Port string - Override
Service
Protocol Udp Override - Source
Port string
- destination
Port String - override
Service
Protocol Udp Override - source
Port String
- destination
Port string - override
Service
Protocol Udp Override - source
Port string
- destination
Port String - override Property Map
- source
Port String
ServiceProtocolUdpOverride, ServiceProtocolUdpOverrideArgs
- Timeout double
- udp session timeout value (in second)
- Timeout float64
- udp session timeout value (in second)
- timeout Double
- udp session timeout value (in second)
- timeout number
- udp session timeout value (in second)
- timeout float
- udp session timeout value (in second)
- timeout Number
- udp session timeout value (in second)
Package Details
- Repository
- panos paloaltonetworks/terraform-provider-panos
- License
- Notes
- This Pulumi package is based on the
panos
Terraform Provider.