Creating an OCI Target

A target defines the scope of resources that Cloud Guard monitors, and the detector and responder recipes to be used in the monitoring.

    1. Open the navigation menu and select Identity & Security. Under Cloud Guard, select Configuration.
    2. On the Configuration page, select Targets.
    3. On the Targets page, select Create target.
    4. On the Create target page, Basic information panel, enter a Target name and an optional Description for the target.
      Avoid entering confidential information.
    5. Select the Compartment to assign to the target.
      Note

      An OCI compartment can only be assigned to a single target.

      • You can select only a single compartment. Any child compartments under the selected compartment inherit the detector and responder recipe settings for the target.
      • To exclude a child compartment from the monitoring that applies to the rest of the target, create a separate target that's assigned just to that child compartment.
    6. (Optional) To add tags, Show advanced options, and then enter the following values:
      1. Select a Tag namespace to add a defined tag, or select None to add a free-form tag.
      2. Select or enter a Tag key and Tag value.
      3. Add more tags or delete them as needed.
      4. select Add tag.
    7. select Next.
    8. On the Configuration panel, in the Posture and threat monitoring section, select from the Detector recipes list:
      1. One recipe under the Configuration detector recipe heading.
      2. One recipe under the Activity detector recipe heading.
      3. (Optional) One recipe under the Threat detector recipe heading.
    9. (Optional) In the Instance Security recipe section, select a recipe from the drop-down list.

      If you want the recipe to apply to all Compute instances, select All compute instances.

    10. select Next.
    11. On the Review panel, look over your selections.
      To make changes, select the Edit link for the item you want to change.
    12. To create the resource, select one of the following options:
      • To create the resource now, select Create.
      • To create the resource later using Resource Manager and Terraform, select Save as Stack to save the resource definition as a Terraform configuration.

        For more information about saving stacks from resource definitions, see Creating a Stack from a Resource Creation Page.

  • For a complete list of flags and variable options for CLI commands, see the Command Line Reference.

    Use the oci cloud-guard target create command and required parameters to create a target:

    oci cloud-guard target create --compartment-id, -c <compartment_ocid> --display-name <detector_template_identifier> --target-resource-id <monitored_resource_id> --target-resource-type <type_of_target> [OPTIONS]
  • Run the CreateTarget operation to create a target.

What's Next