ZoneLockdown

class ZoneLockdown : KotlinCustomResource

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as cloudflare from "@pulumi/cloudflare";
const exampleZoneLockdown = new cloudflare.ZoneLockdown("example_zone_lockdown", {
zoneId: "023e105f4ecef8ad9ca31a8372d0c353",
configurations: [{
target: "ip",
value: "198.51.100.4",
}],
urls: ["shop.example.com/*"],
});
import pulumi
import pulumi_cloudflare as cloudflare
example_zone_lockdown = cloudflare.ZoneLockdown("example_zone_lockdown",
zone_id="023e105f4ecef8ad9ca31a8372d0c353",
configurations=[{
"target": "ip",
"value": "198.51.100.4",
}],
urls=["shop.example.com/*"])
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Cloudflare = Pulumi.Cloudflare;
return await Deployment.RunAsync(() =>
{
var exampleZoneLockdown = new Cloudflare.ZoneLockdown("example_zone_lockdown", new()
{
ZoneId = "023e105f4ecef8ad9ca31a8372d0c353",
Configurations = new[]
{
new Cloudflare.Inputs.ZoneLockdownConfigurationArgs
{
Target = "ip",
Value = "198.51.100.4",
},
},
Urls = new[]
{
"shop.example.com/*",
},
});
});
package main
import (
"github.com/pulumi/pulumi-cloudflare/sdk/v6/go/cloudflare"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := cloudflare.NewZoneLockdown(ctx, "example_zone_lockdown", &cloudflare.ZoneLockdownArgs{
ZoneId: pulumi.String("023e105f4ecef8ad9ca31a8372d0c353"),
Configurations: cloudflare.ZoneLockdownConfigurationArray{
&cloudflare.ZoneLockdownConfigurationArgs{
Target: pulumi.String("ip"),
Value: pulumi.String("198.51.100.4"),
},
},
Urls: pulumi.StringArray{
pulumi.String("shop.example.com/*"),
},
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.cloudflare.ZoneLockdown;
import com.pulumi.cloudflare.ZoneLockdownArgs;
import com.pulumi.cloudflare.inputs.ZoneLockdownConfigurationArgs;
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 exampleZoneLockdown = new ZoneLockdown("exampleZoneLockdown", ZoneLockdownArgs.builder()
.zoneId("023e105f4ecef8ad9ca31a8372d0c353")
.configurations(ZoneLockdownConfigurationArgs.builder()
.target("ip")
.value("198.51.100.4")
.build())
.urls("shop.example.com/*")
.build());
}
}
resources:
exampleZoneLockdown:
type: cloudflare:ZoneLockdown
name: example_zone_lockdown
properties:
zoneId: 023e105f4ecef8ad9ca31a8372d0c353
configurations:
- target: ip
value: 198.51.100.4
urls:
- shop.example.com/*

Import

$ pulumi import cloudflare:index/zoneLockdown:ZoneLockdown example '<zone_id>/<lock_downs_id>'

//////

Properties

Link copied to clipboard

A list of IP addresses or CIDR ranges that will be allowed to access the URLs specified in the Zone Lockdown rule. You can include any number of ip or ip_range configurations.

Link copied to clipboard
val createdOn: Output<String>

The timestamp of when the rule was created.

Link copied to clipboard
val description: Output<String>

An informative summary of the rule.

Link copied to clipboard
val id: Output<String>
Link copied to clipboard
val modifiedOn: Output<String>

The timestamp of when the rule was last modified.

Link copied to clipboard
val paused: Output<Boolean>

When true, indicates that the rule is currently paused.

Link copied to clipboard
val pulumiChildResources: Set<KotlinResource>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val urls: Output<List<String>>

The URLs to include in the current WAF override. You can use wildcards. Each entered URL will be escaped before use, which means you can only use simple wildcard patterns.

Link copied to clipboard
val urn: Output<String>
Link copied to clipboard
val zoneId: Output<String>

Identifier