fastly.NgwafAccountList
Explore with Pulumi AI
Provides a Fastly Next-Gen WAF List resource scoped to an account.
Account-scoped lists are reusable across all workspaces in the account and can be referenced in account-level or workspace-level rules.
Example Usage
Basic usage:
import * as pulumi from "@pulumi/pulumi";
import * as fastly from "@pulumi/fastly";
const example = new fastly.NgwafAccountList("example", {
name: "shared-bot-ip-list",
description: "List of known bot IPs shared across workspaces",
type: "ip",
entries: [
"1.2.3.4",
"5.6.7.8",
"203.0.113.42",
],
});
import pulumi
import pulumi_fastly as fastly
example = fastly.NgwafAccountList("example",
name="shared-bot-ip-list",
description="List of known bot IPs shared across workspaces",
type="ip",
entries=[
"1.2.3.4",
"5.6.7.8",
"203.0.113.42",
])
package main
import (
"github.com/pulumi/pulumi-fastly/sdk/v11/go/fastly"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := fastly.NewNgwafAccountList(ctx, "example", &fastly.NgwafAccountListArgs{
Name: pulumi.String("shared-bot-ip-list"),
Description: pulumi.String("List of known bot IPs shared across workspaces"),
Type: pulumi.String("ip"),
Entries: pulumi.StringArray{
pulumi.String("1.2.3.4"),
pulumi.String("5.6.7.8"),
pulumi.String("203.0.113.42"),
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Fastly = Pulumi.Fastly;
return await Deployment.RunAsync(() =>
{
var example = new Fastly.NgwafAccountList("example", new()
{
Name = "shared-bot-ip-list",
Description = "List of known bot IPs shared across workspaces",
Type = "ip",
Entries = new[]
{
"1.2.3.4",
"5.6.7.8",
"203.0.113.42",
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.fastly.NgwafAccountList;
import com.pulumi.fastly.NgwafAccountListArgs;
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 NgwafAccountList("example", NgwafAccountListArgs.builder()
.name("shared-bot-ip-list")
.description("List of known bot IPs shared across workspaces")
.type("ip")
.entries(
"1.2.3.4",
"5.6.7.8",
"203.0.113.42")
.build());
}
}
resources:
example:
type: fastly:NgwafAccountList
properties:
name: shared-bot-ip-list
description: List of known bot IPs shared across workspaces
type: ip
entries:
- 1.2.3.4
- 5.6.7.8
- 203.0.113.42
Create NgwafAccountList Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new NgwafAccountList(name: string, args: NgwafAccountListArgs, opts?: CustomResourceOptions);
@overload
def NgwafAccountList(resource_name: str,
args: NgwafAccountListArgs,
opts: Optional[ResourceOptions] = None)
@overload
def NgwafAccountList(resource_name: str,
opts: Optional[ResourceOptions] = None,
entries: Optional[Sequence[str]] = None,
type: Optional[str] = None,
description: Optional[str] = None,
name: Optional[str] = None)
func NewNgwafAccountList(ctx *Context, name string, args NgwafAccountListArgs, opts ...ResourceOption) (*NgwafAccountList, error)
public NgwafAccountList(string name, NgwafAccountListArgs args, CustomResourceOptions? opts = null)
public NgwafAccountList(String name, NgwafAccountListArgs args)
public NgwafAccountList(String name, NgwafAccountListArgs args, CustomResourceOptions options)
type: fastly:NgwafAccountList
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 NgwafAccountListArgs
- 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 NgwafAccountListArgs
- 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 NgwafAccountListArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args NgwafAccountListArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args NgwafAccountListArgs
- 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 ngwafAccountListResource = new Fastly.NgwafAccountList("ngwafAccountListResource", new()
{
Entries = new[]
{
"string",
},
Type = "string",
Description = "string",
Name = "string",
});
example, err := fastly.NewNgwafAccountList(ctx, "ngwafAccountListResource", &fastly.NgwafAccountListArgs{
Entries: pulumi.StringArray{
pulumi.String("string"),
},
Type: pulumi.String("string"),
Description: pulumi.String("string"),
Name: pulumi.String("string"),
})
var ngwafAccountListResource = new NgwafAccountList("ngwafAccountListResource", NgwafAccountListArgs.builder()
.entries("string")
.type("string")
.description("string")
.name("string")
.build());
ngwaf_account_list_resource = fastly.NgwafAccountList("ngwafAccountListResource",
entries=["string"],
type="string",
description="string",
name="string")
const ngwafAccountListResource = new fastly.NgwafAccountList("ngwafAccountListResource", {
entries: ["string"],
type: "string",
description: "string",
name: "string",
});
type: fastly:NgwafAccountList
properties:
description: string
entries:
- string
name: string
type: string
NgwafAccountList 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 NgwafAccountList resource accepts the following input properties:
- Entries List<string>
- The values in the list.
- Type string
- The type of list. Accepted values are
string
,wildcard
,ip
,country
, andsignal
. - Description string
- The description of the list.
- Name string
- The name of the list.
- Entries []string
- The values in the list.
- Type string
- The type of list. Accepted values are
string
,wildcard
,ip
,country
, andsignal
. - Description string
- The description of the list.
- Name string
- The name of the list.
- entries List<String>
- The values in the list.
- type String
- The type of list. Accepted values are
string
,wildcard
,ip
,country
, andsignal
. - description String
- The description of the list.
- name String
- The name of the list.
- entries string[]
- The values in the list.
- type string
- The type of list. Accepted values are
string
,wildcard
,ip
,country
, andsignal
. - description string
- The description of the list.
- name string
- The name of the list.
- entries Sequence[str]
- The values in the list.
- type str
- The type of list. Accepted values are
string
,wildcard
,ip
,country
, andsignal
. - description str
- The description of the list.
- name str
- The name of the list.
- entries List<String>
- The values in the list.
- type String
- The type of list. Accepted values are
string
,wildcard
,ip
,country
, andsignal
. - description String
- The description of the list.
- name String
- The name of the list.
Outputs
All input properties are implicitly available as output properties. Additionally, the NgwafAccountList resource produces the following output properties:
- Applies
Tos List<string> - INTERNAL: Used to build scope for account-scoped lists. Not user-configurable.
- Id string
- The provider-assigned unique ID for this managed resource.
- Applies
Tos []string - INTERNAL: Used to build scope for account-scoped lists. Not user-configurable.
- Id string
- The provider-assigned unique ID for this managed resource.
- applies
Tos List<String> - INTERNAL: Used to build scope for account-scoped lists. Not user-configurable.
- id String
- The provider-assigned unique ID for this managed resource.
- applies
Tos string[] - INTERNAL: Used to build scope for account-scoped lists. Not user-configurable.
- id string
- The provider-assigned unique ID for this managed resource.
- applies_
tos Sequence[str] - INTERNAL: Used to build scope for account-scoped lists. Not user-configurable.
- id str
- The provider-assigned unique ID for this managed resource.
- applies
Tos List<String> - INTERNAL: Used to build scope for account-scoped lists. Not user-configurable.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing NgwafAccountList Resource
Get an existing NgwafAccountList 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?: NgwafAccountListState, opts?: CustomResourceOptions): NgwafAccountList
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
applies_tos: Optional[Sequence[str]] = None,
description: Optional[str] = None,
entries: Optional[Sequence[str]] = None,
name: Optional[str] = None,
type: Optional[str] = None) -> NgwafAccountList
func GetNgwafAccountList(ctx *Context, name string, id IDInput, state *NgwafAccountListState, opts ...ResourceOption) (*NgwafAccountList, error)
public static NgwafAccountList Get(string name, Input<string> id, NgwafAccountListState? state, CustomResourceOptions? opts = null)
public static NgwafAccountList get(String name, Output<String> id, NgwafAccountListState state, CustomResourceOptions options)
resources: _: type: fastly:NgwafAccountList 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.
- Applies
Tos List<string> - INTERNAL: Used to build scope for account-scoped lists. Not user-configurable.
- Description string
- The description of the list.
- Entries List<string>
- The values in the list.
- Name string
- The name of the list.
- Type string
- The type of list. Accepted values are
string
,wildcard
,ip
,country
, andsignal
.
- Applies
Tos []string - INTERNAL: Used to build scope for account-scoped lists. Not user-configurable.
- Description string
- The description of the list.
- Entries []string
- The values in the list.
- Name string
- The name of the list.
- Type string
- The type of list. Accepted values are
string
,wildcard
,ip
,country
, andsignal
.
- applies
Tos List<String> - INTERNAL: Used to build scope for account-scoped lists. Not user-configurable.
- description String
- The description of the list.
- entries List<String>
- The values in the list.
- name String
- The name of the list.
- type String
- The type of list. Accepted values are
string
,wildcard
,ip
,country
, andsignal
.
- applies
Tos string[] - INTERNAL: Used to build scope for account-scoped lists. Not user-configurable.
- description string
- The description of the list.
- entries string[]
- The values in the list.
- name string
- The name of the list.
- type string
- The type of list. Accepted values are
string
,wildcard
,ip
,country
, andsignal
.
- applies_
tos Sequence[str] - INTERNAL: Used to build scope for account-scoped lists. Not user-configurable.
- description str
- The description of the list.
- entries Sequence[str]
- The values in the list.
- name str
- The name of the list.
- type str
- The type of list. Accepted values are
string
,wildcard
,ip
,country
, andsignal
.
- applies
Tos List<String> - INTERNAL: Used to build scope for account-scoped lists. Not user-configurable.
- description String
- The description of the list.
- entries List<String>
- The values in the list.
- name String
- The name of the list.
- type String
- The type of list. Accepted values are
string
,wildcard
,ip
,country
, andsignal
.
Import
Fastly Next-Gen WAF account-scoped lists can be imported using just the list ID, e.g.:
$ pulumi import fastly:index/ngwafAccountList:NgwafAccountList demo <listID>
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Fastly pulumi/pulumi-fastly
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
fastly
Terraform Provider.