Oracle Cloud Infrastructure v0.20.0, May 31 23
Oracle Cloud Infrastructure v0.20.0, May 31 23
oci.CloudGuard.SecurityRecipe
Explore with Pulumi AI
This resource provides the Security Recipe resource in Oracle Cloud Infrastructure Cloud Guard service.
Creates a security zone recipe. A security zone recipe is a collection of security zone policies.
Example Usage
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Oci = Pulumi.Oci;
return await Deployment.RunAsync(() =>
{
var testSecurityRecipe = new Oci.CloudGuard.SecurityRecipe("testSecurityRecipe", new()
{
CompartmentId = @var.Compartment_id,
DisplayName = @var.Security_recipe_display_name,
SecurityPolicies = @var.Security_recipe_security_policies,
DefinedTags =
{
{ "foo-namespace.bar-key", "value" },
},
Description = @var.Security_recipe_description,
FreeformTags =
{
{ "bar-key", "value" },
},
});
});
package main
import (
"github.com/pulumi/pulumi-oci/sdk/go/oci/CloudGuard"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := CloudGuard.NewSecurityRecipe(ctx, "testSecurityRecipe", &CloudGuard.SecurityRecipeArgs{
CompartmentId: pulumi.Any(_var.Compartment_id),
DisplayName: pulumi.Any(_var.Security_recipe_display_name),
SecurityPolicies: pulumi.Any(_var.Security_recipe_security_policies),
DefinedTags: pulumi.AnyMap{
"foo-namespace.bar-key": pulumi.Any("value"),
},
Description: pulumi.Any(_var.Security_recipe_description),
FreeformTags: pulumi.AnyMap{
"bar-key": pulumi.Any("value"),
},
})
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.oci.CloudGuard.SecurityRecipe;
import com.pulumi.oci.CloudGuard.SecurityRecipeArgs;
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 testSecurityRecipe = new SecurityRecipe("testSecurityRecipe", SecurityRecipeArgs.builder()
.compartmentId(var_.compartment_id())
.displayName(var_.security_recipe_display_name())
.securityPolicies(var_.security_recipe_security_policies())
.definedTags(Map.of("foo-namespace.bar-key", "value"))
.description(var_.security_recipe_description())
.freeformTags(Map.of("bar-key", "value"))
.build());
}
}
import pulumi
import pulumi_oci as oci
test_security_recipe = oci.cloud_guard.SecurityRecipe("testSecurityRecipe",
compartment_id=var["compartment_id"],
display_name=var["security_recipe_display_name"],
security_policies=var["security_recipe_security_policies"],
defined_tags={
"foo-namespace.bar-key": "value",
},
description=var["security_recipe_description"],
freeform_tags={
"bar-key": "value",
})
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testSecurityRecipe = new oci.cloudguard.SecurityRecipe("testSecurityRecipe", {
compartmentId: _var.compartment_id,
displayName: _var.security_recipe_display_name,
securityPolicies: _var.security_recipe_security_policies,
definedTags: {
"foo-namespace.bar-key": "value",
},
description: _var.security_recipe_description,
freeformTags: {
"bar-key": "value",
},
});
resources:
testSecurityRecipe:
type: oci:CloudGuard:SecurityRecipe
properties:
#Required
compartmentId: ${var.compartment_id}
displayName: ${var.security_recipe_display_name}
securityPolicies: ${var.security_recipe_security_policies}
#Optional
definedTags:
foo-namespace.bar-key: value
description: ${var.security_recipe_description}
freeformTags:
bar-key: value
Create SecurityRecipe Resource
new SecurityRecipe(name: string, args: SecurityRecipeArgs, opts?: CustomResourceOptions);
@overload
def SecurityRecipe(resource_name: str,
opts: Optional[ResourceOptions] = None,
compartment_id: Optional[str] = None,
defined_tags: Optional[Mapping[str, Any]] = None,
description: Optional[str] = None,
display_name: Optional[str] = None,
freeform_tags: Optional[Mapping[str, Any]] = None,
security_policies: Optional[Sequence[str]] = None)
@overload
def SecurityRecipe(resource_name: str,
args: SecurityRecipeArgs,
opts: Optional[ResourceOptions] = None)
func NewSecurityRecipe(ctx *Context, name string, args SecurityRecipeArgs, opts ...ResourceOption) (*SecurityRecipe, error)
public SecurityRecipe(string name, SecurityRecipeArgs args, CustomResourceOptions? opts = null)
public SecurityRecipe(String name, SecurityRecipeArgs args)
public SecurityRecipe(String name, SecurityRecipeArgs args, CustomResourceOptions options)
type: oci:CloudGuard:SecurityRecipe
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SecurityRecipeArgs
- 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 SecurityRecipeArgs
- 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 SecurityRecipeArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SecurityRecipeArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args SecurityRecipeArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
SecurityRecipe 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 SecurityRecipe resource accepts the following input properties:
- Compartment
Id string (Updatable) The compartment in which to create the recipe
- Display
Name string (Updatable) The recipe's name
- Security
Policies List<string> (Updatable) The list of
SecurityPolicy
ids to include in the recipe** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
- Dictionary<string, object>
(Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- Description string
(Updatable) The recipe's description
- Dictionary<string, object>
(Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
Avoid entering confidential information.
- Compartment
Id string (Updatable) The compartment in which to create the recipe
- Display
Name string (Updatable) The recipe's name
- Security
Policies []string (Updatable) The list of
SecurityPolicy
ids to include in the recipe** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
- map[string]interface{}
(Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- Description string
(Updatable) The recipe's description
- map[string]interface{}
(Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
Avoid entering confidential information.
- compartment
Id String (Updatable) The compartment in which to create the recipe
- display
Name String (Updatable) The recipe's name
- security
Policies List<String> (Updatable) The list of
SecurityPolicy
ids to include in the recipe** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
- Map<String,Object>
(Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- description String
(Updatable) The recipe's description
- Map<String,Object>
(Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
Avoid entering confidential information.
- compartment
Id string (Updatable) The compartment in which to create the recipe
- display
Name string (Updatable) The recipe's name
- security
Policies string[] (Updatable) The list of
SecurityPolicy
ids to include in the recipe** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
- {[key: string]: any}
(Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- description string
(Updatable) The recipe's description
- {[key: string]: any}
(Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
Avoid entering confidential information.
- compartment_
id str (Updatable) The compartment in which to create the recipe
- display_
name str (Updatable) The recipe's name
- security_
policies Sequence[str] (Updatable) The list of
SecurityPolicy
ids to include in the recipe** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
- Mapping[str, Any]
(Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- description str
(Updatable) The recipe's description
- Mapping[str, Any]
(Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
Avoid entering confidential information.
- compartment
Id String (Updatable) The compartment in which to create the recipe
- display
Name String (Updatable) The recipe's name
- security
Policies List<String> (Updatable) The list of
SecurityPolicy
ids to include in the recipe** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
- Map<Any>
(Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- description String
(Updatable) The recipe's description
- Map<Any>
(Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
Avoid entering confidential information.
Outputs
All input properties are implicitly available as output properties. Additionally, the SecurityRecipe resource produces the following output properties:
- Id string
The provider-assigned unique ID for this managed resource.
- Lifecycle
Details string A message describing the current state in more detail. For example, this can be used to provide actionable information for a recipe in the
Failed
state.- Owner string
The owner of the recipe
- State string
The current state of the recipe
- Time
Created string The time the recipe was created. An RFC3339 formatted datetime string.
- Time
Updated string The time the recipe was last updated. An RFC3339 formatted datetime string.
- Id string
The provider-assigned unique ID for this managed resource.
- Lifecycle
Details string A message describing the current state in more detail. For example, this can be used to provide actionable information for a recipe in the
Failed
state.- Owner string
The owner of the recipe
- State string
The current state of the recipe
- Time
Created string The time the recipe was created. An RFC3339 formatted datetime string.
- Time
Updated string The time the recipe was last updated. An RFC3339 formatted datetime string.
- id String
The provider-assigned unique ID for this managed resource.
- lifecycle
Details String A message describing the current state in more detail. For example, this can be used to provide actionable information for a recipe in the
Failed
state.- owner String
The owner of the recipe
- state String
The current state of the recipe
- time
Created String The time the recipe was created. An RFC3339 formatted datetime string.
- time
Updated String The time the recipe was last updated. An RFC3339 formatted datetime string.
- id string
The provider-assigned unique ID for this managed resource.
- lifecycle
Details string A message describing the current state in more detail. For example, this can be used to provide actionable information for a recipe in the
Failed
state.- owner string
The owner of the recipe
- state string
The current state of the recipe
- time
Created string The time the recipe was created. An RFC3339 formatted datetime string.
- time
Updated string The time the recipe was last updated. An RFC3339 formatted datetime string.
- id str
The provider-assigned unique ID for this managed resource.
- lifecycle_
details str A message describing the current state in more detail. For example, this can be used to provide actionable information for a recipe in the
Failed
state.- owner str
The owner of the recipe
- state str
The current state of the recipe
- time_
created str The time the recipe was created. An RFC3339 formatted datetime string.
- time_
updated str The time the recipe was last updated. An RFC3339 formatted datetime string.
- id String
The provider-assigned unique ID for this managed resource.
- lifecycle
Details String A message describing the current state in more detail. For example, this can be used to provide actionable information for a recipe in the
Failed
state.- owner String
The owner of the recipe
- state String
The current state of the recipe
- time
Created String The time the recipe was created. An RFC3339 formatted datetime string.
- time
Updated String The time the recipe was last updated. An RFC3339 formatted datetime string.
Look up Existing SecurityRecipe Resource
Get an existing SecurityRecipe 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?: SecurityRecipeState, opts?: CustomResourceOptions): SecurityRecipe
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
compartment_id: Optional[str] = None,
defined_tags: Optional[Mapping[str, Any]] = None,
description: Optional[str] = None,
display_name: Optional[str] = None,
freeform_tags: Optional[Mapping[str, Any]] = None,
lifecycle_details: Optional[str] = None,
owner: Optional[str] = None,
security_policies: Optional[Sequence[str]] = None,
state: Optional[str] = None,
time_created: Optional[str] = None,
time_updated: Optional[str] = None) -> SecurityRecipe
func GetSecurityRecipe(ctx *Context, name string, id IDInput, state *SecurityRecipeState, opts ...ResourceOption) (*SecurityRecipe, error)
public static SecurityRecipe Get(string name, Input<string> id, SecurityRecipeState? state, CustomResourceOptions? opts = null)
public static SecurityRecipe get(String name, Output<String> id, SecurityRecipeState 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.
- Compartment
Id string (Updatable) The compartment in which to create the recipe
- Dictionary<string, object>
(Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- Description string
(Updatable) The recipe's description
- Display
Name string (Updatable) The recipe's name
- Dictionary<string, object>
(Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
Avoid entering confidential information.
- Lifecycle
Details string A message describing the current state in more detail. For example, this can be used to provide actionable information for a recipe in the
Failed
state.- Owner string
The owner of the recipe
- Security
Policies List<string> (Updatable) The list of
SecurityPolicy
ids to include in the recipe** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
- State string
The current state of the recipe
- Time
Created string The time the recipe was created. An RFC3339 formatted datetime string.
- Time
Updated string The time the recipe was last updated. An RFC3339 formatted datetime string.
- Compartment
Id string (Updatable) The compartment in which to create the recipe
- map[string]interface{}
(Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- Description string
(Updatable) The recipe's description
- Display
Name string (Updatable) The recipe's name
- map[string]interface{}
(Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
Avoid entering confidential information.
- Lifecycle
Details string A message describing the current state in more detail. For example, this can be used to provide actionable information for a recipe in the
Failed
state.- Owner string
The owner of the recipe
- Security
Policies []string (Updatable) The list of
SecurityPolicy
ids to include in the recipe** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
- State string
The current state of the recipe
- Time
Created string The time the recipe was created. An RFC3339 formatted datetime string.
- Time
Updated string The time the recipe was last updated. An RFC3339 formatted datetime string.
- compartment
Id String (Updatable) The compartment in which to create the recipe
- Map<String,Object>
(Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- description String
(Updatable) The recipe's description
- display
Name String (Updatable) The recipe's name
- Map<String,Object>
(Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
Avoid entering confidential information.
- lifecycle
Details String A message describing the current state in more detail. For example, this can be used to provide actionable information for a recipe in the
Failed
state.- owner String
The owner of the recipe
- security
Policies List<String> (Updatable) The list of
SecurityPolicy
ids to include in the recipe** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
- state String
The current state of the recipe
- time
Created String The time the recipe was created. An RFC3339 formatted datetime string.
- time
Updated String The time the recipe was last updated. An RFC3339 formatted datetime string.
- compartment
Id string (Updatable) The compartment in which to create the recipe
- {[key: string]: any}
(Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- description string
(Updatable) The recipe's description
- display
Name string (Updatable) The recipe's name
- {[key: string]: any}
(Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
Avoid entering confidential information.
- lifecycle
Details string A message describing the current state in more detail. For example, this can be used to provide actionable information for a recipe in the
Failed
state.- owner string
The owner of the recipe
- security
Policies string[] (Updatable) The list of
SecurityPolicy
ids to include in the recipe** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
- state string
The current state of the recipe
- time
Created string The time the recipe was created. An RFC3339 formatted datetime string.
- time
Updated string The time the recipe was last updated. An RFC3339 formatted datetime string.
- compartment_
id str (Updatable) The compartment in which to create the recipe
- Mapping[str, Any]
(Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- description str
(Updatable) The recipe's description
- display_
name str (Updatable) The recipe's name
- Mapping[str, Any]
(Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
Avoid entering confidential information.
- lifecycle_
details str A message describing the current state in more detail. For example, this can be used to provide actionable information for a recipe in the
Failed
state.- owner str
The owner of the recipe
- security_
policies Sequence[str] (Updatable) The list of
SecurityPolicy
ids to include in the recipe** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
- state str
The current state of the recipe
- time_
created str The time the recipe was created. An RFC3339 formatted datetime string.
- time_
updated str The time the recipe was last updated. An RFC3339 formatted datetime string.
- compartment
Id String (Updatable) The compartment in which to create the recipe
- Map<Any>
(Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- description String
(Updatable) The recipe's description
- display
Name String (Updatable) The recipe's name
- Map<Any>
(Updatable) Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
Avoid entering confidential information.
- lifecycle
Details String A message describing the current state in more detail. For example, this can be used to provide actionable information for a recipe in the
Failed
state.- owner String
The owner of the recipe
- security
Policies List<String> (Updatable) The list of
SecurityPolicy
ids to include in the recipe** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
- state String
The current state of the recipe
- time
Created String The time the recipe was created. An RFC3339 formatted datetime string.
- time
Updated String The time the recipe was last updated. An RFC3339 formatted datetime string.
Import
SecurityRecipes can be imported using the id
, e.g.
$ pulumi import oci:CloudGuard/securityRecipe:SecurityRecipe test_security_recipe "id"
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
oci
Terraform Provider.