Akamai

Pulumi Official
Package maintained by Pulumi
v2.9.0 published on Wednesday, Apr 6, 2022 by Pulumi

AppSecActivations

Scopes: Security configuration

Activates or deactivates a security configuration. Security configurations activated on the staging network can be used for testing and fine-tuning; security configurations activated on the production network are used to protect your actual websites.

Note that activation fails if the security configuration includes one or more invalid hostnames. You can find these names in the resulting activation error message. To activate the configuration, remove the invalid hosts and try again.

Related API Endpoint: /appsec/v1/activations

Output Options

The following options can be used to determine the information returned, and how that returned information is formatted:

  • status. Status of the operation. Valid values are:

    • ACTIVATED
    • DEACTIVATED
    • FAILED

Example Usage

using Pulumi;
using Akamai = Pulumi.Akamai;

class MyStack : Stack
{
    public MyStack()
    {
        var configuration = Output.Create(Akamai.GetAppSecConfiguration.InvokeAsync(new Akamai.GetAppSecConfigurationArgs
        {
            Name = "Documentation",
        }));
        var activation = new Akamai.AppSecActivations("activation", new Akamai.AppSecActivationsArgs
        {
            ConfigId = configuration.Apply(configuration => configuration.ConfigId),
            Network = "STAGING",
            Notes = "This configuration was activated for testing purposes only.",
            NotificationEmails = 
            {
                "user@example.com",
            },
        });
    }

}
package main

import (
	"github.com/pulumi/pulumi-akamai/sdk/v2/go/akamai"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		configuration, err := akamai.LookupAppSecConfiguration(ctx, &GetAppSecConfigurationArgs{
			Name: pulumi.StringRef("Documentation"),
		}, nil)
		if err != nil {
			return err
		}
		_, err = akamai.NewAppSecActivations(ctx, "activation", &akamai.AppSecActivationsArgs{
			ConfigId: pulumi.Int(configuration.ConfigId),
			Network:  pulumi.String("STAGING"),
			Notes:    pulumi.String("This configuration was activated for testing purposes only."),
			NotificationEmails: pulumi.StringArray{
				pulumi.String("user@example.com"),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}

Coming soon!

import pulumi
import pulumi_akamai as akamai

configuration = akamai.get_app_sec_configuration(name="Documentation")
activation = akamai.AppSecActivations("activation",
    config_id=configuration.config_id,
    network="STAGING",
    notes="This configuration was activated for testing purposes only.",
    notification_emails=["user@example.com"])
import * as pulumi from "@pulumi/pulumi";
import * as akamai from "@pulumi/akamai";

const configuration = akamai.getAppSecConfiguration({
    name: "Documentation",
});
const activation = new akamai.AppSecActivations("activation", {
    configId: configuration.then(configuration => configuration.configId),
    network: "STAGING",
    notes: "This configuration was activated for testing purposes only.",
    notificationEmails: ["user@example.com"],
});

Coming soon!

Create a AppSecActivations Resource

new AppSecActivations(name: string, args: AppSecActivationsArgs, opts?: CustomResourceOptions);
@overload
def AppSecActivations(resource_name: str,
                      opts: Optional[ResourceOptions] = None,
                      activate: Optional[bool] = None,
                      config_id: Optional[int] = None,
                      network: Optional[str] = None,
                      notes: Optional[str] = None,
                      notification_emails: Optional[Sequence[str]] = None)
@overload
def AppSecActivations(resource_name: str,
                      args: AppSecActivationsArgs,
                      opts: Optional[ResourceOptions] = None)
func NewAppSecActivations(ctx *Context, name string, args AppSecActivationsArgs, opts ...ResourceOption) (*AppSecActivations, error)
public AppSecActivations(string name, AppSecActivationsArgs args, CustomResourceOptions? opts = null)
public AppSecActivations(String name, AppSecActivationsArgs args)
public AppSecActivations(String name, AppSecActivationsArgs args, CustomResourceOptions options)
type: akamai:AppSecActivations
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args AppSecActivationsArgs
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 AppSecActivationsArgs
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 AppSecActivationsArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args AppSecActivationsArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args AppSecActivationsArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

AppSecActivations Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

The AppSecActivations resource accepts the following input properties:

ConfigId int

. Unique identifier of the security configuration being activated.

Notes string

. Brief description of the activation/deactivation process. Note that, if no attributes have changed since the last time you called the akamai.AppSecActivations resource, neither activation nor deactivation takes place: that's because something must be different in order to trigger the activation/deactivation process. With that in mind, it's recommended that you always update the notes argument. That ensures that the resource will be called and that activation or deactivation will occur.

NotificationEmails List<string>

. JSON array containing the email addresses of the people to be notified when activation is complete.

Activate bool

. Set to true to activate the specified security configuration; set to false to deactivate the configuration. If not included, the security configuration will be activated.

Network string

. Network on which activation will occur; allowed values are:

ConfigId int

. Unique identifier of the security configuration being activated.

Notes string

. Brief description of the activation/deactivation process. Note that, if no attributes have changed since the last time you called the akamai.AppSecActivations resource, neither activation nor deactivation takes place: that's because something must be different in order to trigger the activation/deactivation process. With that in mind, it's recommended that you always update the notes argument. That ensures that the resource will be called and that activation or deactivation will occur.

NotificationEmails []string

. JSON array containing the email addresses of the people to be notified when activation is complete.

Activate bool

. Set to true to activate the specified security configuration; set to false to deactivate the configuration. If not included, the security configuration will be activated.

Network string

. Network on which activation will occur; allowed values are:

configId Integer

. Unique identifier of the security configuration being activated.

notes String

. Brief description of the activation/deactivation process. Note that, if no attributes have changed since the last time you called the akamai.AppSecActivations resource, neither activation nor deactivation takes place: that's because something must be different in order to trigger the activation/deactivation process. With that in mind, it's recommended that you always update the notes argument. That ensures that the resource will be called and that activation or deactivation will occur.

notificationEmails List

. JSON array containing the email addresses of the people to be notified when activation is complete.

activate Boolean

. Set to true to activate the specified security configuration; set to false to deactivate the configuration. If not included, the security configuration will be activated.

network String

. Network on which activation will occur; allowed values are:

configId number

. Unique identifier of the security configuration being activated.

notes string

. Brief description of the activation/deactivation process. Note that, if no attributes have changed since the last time you called the akamai.AppSecActivations resource, neither activation nor deactivation takes place: that's because something must be different in order to trigger the activation/deactivation process. With that in mind, it's recommended that you always update the notes argument. That ensures that the resource will be called and that activation or deactivation will occur.

notificationEmails string[]

. JSON array containing the email addresses of the people to be notified when activation is complete.

activate boolean

. Set to true to activate the specified security configuration; set to false to deactivate the configuration. If not included, the security configuration will be activated.

network string

. Network on which activation will occur; allowed values are:

config_id int

. Unique identifier of the security configuration being activated.

notes str

. Brief description of the activation/deactivation process. Note that, if no attributes have changed since the last time you called the akamai.AppSecActivations resource, neither activation nor deactivation takes place: that's because something must be different in order to trigger the activation/deactivation process. With that in mind, it's recommended that you always update the notes argument. That ensures that the resource will be called and that activation or deactivation will occur.

notification_emails Sequence[str]

. JSON array containing the email addresses of the people to be notified when activation is complete.

activate bool

. Set to true to activate the specified security configuration; set to false to deactivate the configuration. If not included, the security configuration will be activated.

network str

. Network on which activation will occur; allowed values are:

configId Number

. Unique identifier of the security configuration being activated.

notes String

. Brief description of the activation/deactivation process. Note that, if no attributes have changed since the last time you called the akamai.AppSecActivations resource, neither activation nor deactivation takes place: that's because something must be different in order to trigger the activation/deactivation process. With that in mind, it's recommended that you always update the notes argument. That ensures that the resource will be called and that activation or deactivation will occur.

notificationEmails List

. JSON array containing the email addresses of the people to be notified when activation is complete.

activate Boolean

. Set to true to activate the specified security configuration; set to false to deactivate the configuration. If not included, the security configuration will be activated.

network String

. Network on which activation will occur; allowed values are:

Outputs

All input properties are implicitly available as output properties. Additionally, the AppSecActivations resource produces the following output properties:

Id string

The provider-assigned unique ID for this managed resource.

Status string
Id string

The provider-assigned unique ID for this managed resource.

Status string
id String

The provider-assigned unique ID for this managed resource.

status String
id string

The provider-assigned unique ID for this managed resource.

status string
id str

The provider-assigned unique ID for this managed resource.

status str
id String

The provider-assigned unique ID for this managed resource.

status String

Look up an Existing AppSecActivations Resource

Get an existing AppSecActivations 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?: AppSecActivationsState, opts?: CustomResourceOptions): AppSecActivations
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        activate: Optional[bool] = None,
        config_id: Optional[int] = None,
        network: Optional[str] = None,
        notes: Optional[str] = None,
        notification_emails: Optional[Sequence[str]] = None,
        status: Optional[str] = None) -> AppSecActivations
func GetAppSecActivations(ctx *Context, name string, id IDInput, state *AppSecActivationsState, opts ...ResourceOption) (*AppSecActivations, error)
public static AppSecActivations Get(string name, Input<string> id, AppSecActivationsState? state, CustomResourceOptions? opts = null)
public static AppSecActivations get(String name, Output<String> id, AppSecActivationsState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
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.
The following state arguments are supported:
Activate bool

. Set to true to activate the specified security configuration; set to false to deactivate the configuration. If not included, the security configuration will be activated.

ConfigId int

. Unique identifier of the security configuration being activated.

Network string

. Network on which activation will occur; allowed values are:

Notes string

. Brief description of the activation/deactivation process. Note that, if no attributes have changed since the last time you called the akamai.AppSecActivations resource, neither activation nor deactivation takes place: that's because something must be different in order to trigger the activation/deactivation process. With that in mind, it's recommended that you always update the notes argument. That ensures that the resource will be called and that activation or deactivation will occur.

NotificationEmails List<string>

. JSON array containing the email addresses of the people to be notified when activation is complete.

Status string
Activate bool

. Set to true to activate the specified security configuration; set to false to deactivate the configuration. If not included, the security configuration will be activated.

ConfigId int

. Unique identifier of the security configuration being activated.

Network string

. Network on which activation will occur; allowed values are:

Notes string

. Brief description of the activation/deactivation process. Note that, if no attributes have changed since the last time you called the akamai.AppSecActivations resource, neither activation nor deactivation takes place: that's because something must be different in order to trigger the activation/deactivation process. With that in mind, it's recommended that you always update the notes argument. That ensures that the resource will be called and that activation or deactivation will occur.

NotificationEmails []string

. JSON array containing the email addresses of the people to be notified when activation is complete.

Status string
activate Boolean

. Set to true to activate the specified security configuration; set to false to deactivate the configuration. If not included, the security configuration will be activated.

configId Integer

. Unique identifier of the security configuration being activated.

network String

. Network on which activation will occur; allowed values are:

notes String

. Brief description of the activation/deactivation process. Note that, if no attributes have changed since the last time you called the akamai.AppSecActivations resource, neither activation nor deactivation takes place: that's because something must be different in order to trigger the activation/deactivation process. With that in mind, it's recommended that you always update the notes argument. That ensures that the resource will be called and that activation or deactivation will occur.

notificationEmails List

. JSON array containing the email addresses of the people to be notified when activation is complete.

status String
activate boolean

. Set to true to activate the specified security configuration; set to false to deactivate the configuration. If not included, the security configuration will be activated.

configId number

. Unique identifier of the security configuration being activated.

network string

. Network on which activation will occur; allowed values are:

notes string

. Brief description of the activation/deactivation process. Note that, if no attributes have changed since the last time you called the akamai.AppSecActivations resource, neither activation nor deactivation takes place: that's because something must be different in order to trigger the activation/deactivation process. With that in mind, it's recommended that you always update the notes argument. That ensures that the resource will be called and that activation or deactivation will occur.

notificationEmails string[]

. JSON array containing the email addresses of the people to be notified when activation is complete.

status string
activate bool

. Set to true to activate the specified security configuration; set to false to deactivate the configuration. If not included, the security configuration will be activated.

config_id int

. Unique identifier of the security configuration being activated.

network str

. Network on which activation will occur; allowed values are:

notes str

. Brief description of the activation/deactivation process. Note that, if no attributes have changed since the last time you called the akamai.AppSecActivations resource, neither activation nor deactivation takes place: that's because something must be different in order to trigger the activation/deactivation process. With that in mind, it's recommended that you always update the notes argument. That ensures that the resource will be called and that activation or deactivation will occur.

notification_emails Sequence[str]

. JSON array containing the email addresses of the people to be notified when activation is complete.

status str
activate Boolean

. Set to true to activate the specified security configuration; set to false to deactivate the configuration. If not included, the security configuration will be activated.

configId Number

. Unique identifier of the security configuration being activated.

network String

. Network on which activation will occur; allowed values are:

notes String

. Brief description of the activation/deactivation process. Note that, if no attributes have changed since the last time you called the akamai.AppSecActivations resource, neither activation nor deactivation takes place: that's because something must be different in order to trigger the activation/deactivation process. With that in mind, it's recommended that you always update the notes argument. That ensures that the resource will be called and that activation or deactivation will occur.

notificationEmails List

. JSON array containing the email addresses of the people to be notified when activation is complete.

status String

Package Details

Repository
https://github.com/pulumi/pulumi-akamai
License
Apache-2.0
Notes

This Pulumi package is based on the akamai Terraform Provider.