Use the zia_dc_exclusions Resource to add a data center (DC) exclusion to disable the tunnels terminating at a virtual IP address of a Zscaler DC, triggering a failover from primary to secondary tunnels in the event of service disruptions, Zscaler Trust Portal incidents, disasters, etc. You can configure to exclude a specific DC based on the traffic forwarding method for a designated time period.
NOTE: This an Early Access feature.
Example Usage
data "zia_datacenters" "this" {
name = "SJC4"
}
# Using Unix timestamps
resource "zia_dc_exclusions" "this" {
datacenter_id = data.zia_datacenters.this.datacenter_id
start_time = 1770422399
end_time = 1770508799
description = "Optional description"
}
# Using human-readable UTC date/time (same as zia_sub_cloud exclusions)
resource "zia_dc_exclusions" "utc" {
datacenter_id = data.zia_datacenters.this.datacenter_id
start_time_utc = "02/05/2026 12:00 am"
end_time_utc = "02/19/2026 11:59 pm"
description = "Optional description"
}
Create DCExclusions Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new DCExclusions(name: string, args?: DCExclusionsArgs, opts?: CustomResourceOptions);@overload
def DCExclusions(resource_name: str,
args: Optional[DCExclusionsArgs] = None,
opts: Optional[ResourceOptions] = None)
@overload
def DCExclusions(resource_name: str,
opts: Optional[ResourceOptions] = None,
datacenter_id: Optional[int] = None,
description: Optional[str] = None,
end_time: Optional[int] = None,
end_time_utc: Optional[str] = None,
start_time: Optional[int] = None,
start_time_utc: Optional[str] = None)func NewDCExclusions(ctx *Context, name string, args *DCExclusionsArgs, opts ...ResourceOption) (*DCExclusions, error)public DCExclusions(string name, DCExclusionsArgs? args = null, CustomResourceOptions? opts = null)
public DCExclusions(String name, DCExclusionsArgs args)
public DCExclusions(String name, DCExclusionsArgs args, CustomResourceOptions options)
type: zia:DCExclusions
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 DCExclusionsArgs
- 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 DCExclusionsArgs
- 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 DCExclusionsArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args DCExclusionsArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args DCExclusionsArgs
- 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 dcexclusionsResource = new Zia.DCExclusions("dcexclusionsResource", new()
{
DatacenterId = 0,
Description = "string",
EndTime = 0,
EndTimeUtc = "string",
StartTime = 0,
StartTimeUtc = "string",
});
example, err := zia.NewDCExclusions(ctx, "dcexclusionsResource", &zia.DCExclusionsArgs{
DatacenterId: pulumi.Int(0),
Description: pulumi.String("string"),
EndTime: pulumi.Int(0),
EndTimeUtc: pulumi.String("string"),
StartTime: pulumi.Int(0),
StartTimeUtc: pulumi.String("string"),
})
var dcexclusionsResource = new DCExclusions("dcexclusionsResource", DCExclusionsArgs.builder()
.datacenterId(0)
.description("string")
.endTime(0)
.endTimeUtc("string")
.startTime(0)
.startTimeUtc("string")
.build());
dcexclusions_resource = zia.DCExclusions("dcexclusionsResource",
datacenter_id=0,
description="string",
end_time=0,
end_time_utc="string",
start_time=0,
start_time_utc="string")
const dcexclusionsResource = new zia.DCExclusions("dcexclusionsResource", {
datacenterId: 0,
description: "string",
endTime: 0,
endTimeUtc: "string",
startTime: 0,
startTimeUtc: "string",
});
type: zia:DCExclusions
properties:
datacenterId: 0
description: string
endTime: 0
endTimeUtc: string
startTime: 0
startTimeUtc: string
DCExclusions 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 DCExclusions resource accepts the following input properties:
- Datacenter
Id int - Datacenter ID (dcid) to exclude. Required on create; can be omitted when importing by ID. Use the numeric ID from zia.getDatacenters (e.g. datacenter_id) or this resource's id.
- Description string
- Description of the DC exclusion.
- End
Time int - Unix timestamp when the exclusion window ends. Either end_time or end_time_utc must be set.
- End
Time stringUtc - (String) Exclusion window end in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API). - Start
Time int - Unix timestamp when the exclusion window starts. Either start_time or start_time_utc must be set.
- Start
Time stringUtc - (String) Exclusion window start in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API).
- Datacenter
Id int - Datacenter ID (dcid) to exclude. Required on create; can be omitted when importing by ID. Use the numeric ID from zia.getDatacenters (e.g. datacenter_id) or this resource's id.
- Description string
- Description of the DC exclusion.
- End
Time int - Unix timestamp when the exclusion window ends. Either end_time or end_time_utc must be set.
- End
Time stringUtc - (String) Exclusion window end in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API). - Start
Time int - Unix timestamp when the exclusion window starts. Either start_time or start_time_utc must be set.
- Start
Time stringUtc - (String) Exclusion window start in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API).
- datacenter
Id Integer - Datacenter ID (dcid) to exclude. Required on create; can be omitted when importing by ID. Use the numeric ID from zia.getDatacenters (e.g. datacenter_id) or this resource's id.
- description String
- Description of the DC exclusion.
- end
Time Integer - Unix timestamp when the exclusion window ends. Either end_time or end_time_utc must be set.
- end
Time StringUtc - (String) Exclusion window end in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API). - start
Time Integer - Unix timestamp when the exclusion window starts. Either start_time or start_time_utc must be set.
- start
Time StringUtc - (String) Exclusion window start in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API).
- datacenter
Id number - Datacenter ID (dcid) to exclude. Required on create; can be omitted when importing by ID. Use the numeric ID from zia.getDatacenters (e.g. datacenter_id) or this resource's id.
- description string
- Description of the DC exclusion.
- end
Time number - Unix timestamp when the exclusion window ends. Either end_time or end_time_utc must be set.
- end
Time stringUtc - (String) Exclusion window end in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API). - start
Time number - Unix timestamp when the exclusion window starts. Either start_time or start_time_utc must be set.
- start
Time stringUtc - (String) Exclusion window start in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API).
- datacenter_
id int - Datacenter ID (dcid) to exclude. Required on create; can be omitted when importing by ID. Use the numeric ID from zia.getDatacenters (e.g. datacenter_id) or this resource's id.
- description str
- Description of the DC exclusion.
- end_
time int - Unix timestamp when the exclusion window ends. Either end_time or end_time_utc must be set.
- end_
time_ strutc - (String) Exclusion window end in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API). - start_
time int - Unix timestamp when the exclusion window starts. Either start_time or start_time_utc must be set.
- start_
time_ strutc - (String) Exclusion window start in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API).
- datacenter
Id Number - Datacenter ID (dcid) to exclude. Required on create; can be omitted when importing by ID. Use the numeric ID from zia.getDatacenters (e.g. datacenter_id) or this resource's id.
- description String
- Description of the DC exclusion.
- end
Time Number - Unix timestamp when the exclusion window ends. Either end_time or end_time_utc must be set.
- end
Time StringUtc - (String) Exclusion window end in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API). - start
Time Number - Unix timestamp when the exclusion window starts. Either start_time or start_time_utc must be set.
- start
Time StringUtc - (String) Exclusion window start in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API).
Outputs
All input properties are implicitly available as output properties. Additionally, the DCExclusions resource produces the following output properties:
Look up Existing DCExclusions Resource
Get an existing DCExclusions 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?: DCExclusionsState, opts?: CustomResourceOptions): DCExclusions@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
datacenter_id: Optional[int] = None,
description: Optional[str] = None,
end_time: Optional[int] = None,
end_time_utc: Optional[str] = None,
expired: Optional[bool] = None,
start_time: Optional[int] = None,
start_time_utc: Optional[str] = None) -> DCExclusionsfunc GetDCExclusions(ctx *Context, name string, id IDInput, state *DCExclusionsState, opts ...ResourceOption) (*DCExclusions, error)public static DCExclusions Get(string name, Input<string> id, DCExclusionsState? state, CustomResourceOptions? opts = null)public static DCExclusions get(String name, Output<String> id, DCExclusionsState state, CustomResourceOptions options)resources: _: type: zia:DCExclusions 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.
- Datacenter
Id int - Datacenter ID (dcid) to exclude. Required on create; can be omitted when importing by ID. Use the numeric ID from zia.getDatacenters (e.g. datacenter_id) or this resource's id.
- Description string
- Description of the DC exclusion.
- End
Time int - Unix timestamp when the exclusion window ends. Either end_time or end_time_utc must be set.
- End
Time stringUtc - (String) Exclusion window end in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API). - Expired bool
- (Boolean) Whether the exclusion has expired (read-only from API).
- Start
Time int - Unix timestamp when the exclusion window starts. Either start_time or start_time_utc must be set.
- Start
Time stringUtc - (String) Exclusion window start in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API).
- Datacenter
Id int - Datacenter ID (dcid) to exclude. Required on create; can be omitted when importing by ID. Use the numeric ID from zia.getDatacenters (e.g. datacenter_id) or this resource's id.
- Description string
- Description of the DC exclusion.
- End
Time int - Unix timestamp when the exclusion window ends. Either end_time or end_time_utc must be set.
- End
Time stringUtc - (String) Exclusion window end in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API). - Expired bool
- (Boolean) Whether the exclusion has expired (read-only from API).
- Start
Time int - Unix timestamp when the exclusion window starts. Either start_time or start_time_utc must be set.
- Start
Time stringUtc - (String) Exclusion window start in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API).
- datacenter
Id Integer - Datacenter ID (dcid) to exclude. Required on create; can be omitted when importing by ID. Use the numeric ID from zia.getDatacenters (e.g. datacenter_id) or this resource's id.
- description String
- Description of the DC exclusion.
- end
Time Integer - Unix timestamp when the exclusion window ends. Either end_time or end_time_utc must be set.
- end
Time StringUtc - (String) Exclusion window end in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API). - expired Boolean
- (Boolean) Whether the exclusion has expired (read-only from API).
- start
Time Integer - Unix timestamp when the exclusion window starts. Either start_time or start_time_utc must be set.
- start
Time StringUtc - (String) Exclusion window start in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API).
- datacenter
Id number - Datacenter ID (dcid) to exclude. Required on create; can be omitted when importing by ID. Use the numeric ID from zia.getDatacenters (e.g. datacenter_id) or this resource's id.
- description string
- Description of the DC exclusion.
- end
Time number - Unix timestamp when the exclusion window ends. Either end_time or end_time_utc must be set.
- end
Time stringUtc - (String) Exclusion window end in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API). - expired boolean
- (Boolean) Whether the exclusion has expired (read-only from API).
- start
Time number - Unix timestamp when the exclusion window starts. Either start_time or start_time_utc must be set.
- start
Time stringUtc - (String) Exclusion window start in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API).
- datacenter_
id int - Datacenter ID (dcid) to exclude. Required on create; can be omitted when importing by ID. Use the numeric ID from zia.getDatacenters (e.g. datacenter_id) or this resource's id.
- description str
- Description of the DC exclusion.
- end_
time int - Unix timestamp when the exclusion window ends. Either end_time or end_time_utc must be set.
- end_
time_ strutc - (String) Exclusion window end in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API). - expired bool
- (Boolean) Whether the exclusion has expired (read-only from API).
- start_
time int - Unix timestamp when the exclusion window starts. Either start_time or start_time_utc must be set.
- start_
time_ strutc - (String) Exclusion window start in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API).
- datacenter
Id Number - Datacenter ID (dcid) to exclude. Required on create; can be omitted when importing by ID. Use the numeric ID from zia.getDatacenters (e.g. datacenter_id) or this resource's id.
- description String
- Description of the DC exclusion.
- end
Time Number - Unix timestamp when the exclusion window ends. Either end_time or end_time_utc must be set.
- end
Time StringUtc - (String) Exclusion window end in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API). - expired Boolean
- (Boolean) Whether the exclusion has expired (read-only from API).
- start
Time Number - Unix timestamp when the exclusion window starts. Either start_time or start_time_utc must be set.
- start
Time StringUtc - (String) Exclusion window start in UTC, formatted as
MM/DD/YYYY HH:MM am/pm(computed from API).
Package Details
- Repository
- zia zscaler/pulumi-zia
- License
- MIT
- Notes
- This Pulumi package is based on the
ziaTerraform Provider.
