-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
125 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
0.1.0 | ||
0.2.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
# organization | ||
|
||
This module creates following resources. | ||
|
||
- `okta_security_notification_emails` | ||
|
||
<!-- BEGINNING OF PRE-COMMIT-TERRAFORM DOCS HOOK --> | ||
## Requirements | ||
|
||
| Name | Version | | ||
|------|---------| | ||
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.6 | | ||
| <a name="requirement_okta"></a> [okta](#requirement\_okta) | >= 4.8 | | ||
|
||
## Providers | ||
|
||
| Name | Version | | ||
|------|---------| | ||
| <a name="provider_okta"></a> [okta](#provider\_okta) | 4.8.1 | | ||
|
||
## Modules | ||
|
||
No modules. | ||
|
||
## Resources | ||
|
||
| Name | Type | | ||
|------|------| | ||
| [okta_security_notification_emails.this](https://registry.terraform.io/providers/okta/okta/latest/docs/resources/security_notification_emails) | resource | | ||
|
||
## Inputs | ||
|
||
| Name | Description | Type | Default | Required | | ||
|------|-------------|------|---------|:--------:| | ||
| <a name="input_security_notification_email_preferences"></a> [security\_notification\_email\_preferences](#input\_security\_notification\_email\_preferences) | (Optional) A preferences for security notification emails. `security_notification_email_preferences` block as defined below.<br> (Optional) `report_on_suspicious_activity` - Whether to notify end users about suspicious<br> or unrecognized activity from their account. Defaults to `true`.<br> (Optional) `notify_on_factor_enrollment` - Whether to notify end users of any activity on their account related to MFA factor enrollment. Defaults to `true`.<br> (Optional) `notify_on_factor_reset` - Whether to notify end users that one or more factors have been reset for their account. Defaults to `true`.<br> (Optional) `notify_on_new_device` - Whether to notify end users about new sign-on activity. Defaults to `false`.<br> (Optional) `notify_on_password_changed` - Whether to notify end users that the password for their account has changed. Defaults to `true`. | <pre>object({<br> report_on_suspicious_activity = optional(bool, true)<br> notify_on_factor_enrollment = optional(bool, true)<br> notify_on_factor_reset = optional(bool, true)<br> notify_on_new_device = optional(bool, false)<br> notify_on_password_changed = optional(bool, true)<br> })</pre> | `{}` | no | | ||
|
||
## Outputs | ||
|
||
| Name | Description | | ||
|------|-------------| | ||
| <a name="output_security_notification_email_preferences"></a> [security\_notification\_email\_preferences](#output\_security\_notification\_email\_preferences) | The preferences for security notification emails. | | ||
<!-- END OF PRE-COMMIT-TERRAFORM DOCS HOOK --> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# locals { | ||
# metadata = { | ||
# package = "terraform-okta-modules" | ||
# version = trimspace(file("${path.module}/../../VERSION")) | ||
# module = basename(path.module) | ||
# name = var.name | ||
# } | ||
# module_tags = { | ||
# "module.terraform.io/package" = local.metadata.package | ||
# "module.terraform.io/version" = local.metadata.version | ||
# "module.terraform.io/name" = local.metadata.module | ||
# "module.terraform.io/full-name" = "${local.metadata.package}/${local.metadata.module}" | ||
# "module.terraform.io/instance" = local.metadata.name | ||
# } | ||
# } | ||
|
||
|
||
################################################### | ||
# Security Notification Preferences for Organization | ||
################################################### | ||
|
||
resource "okta_security_notification_emails" "this" { | ||
report_suspicious_activity_enabled = var.security_notification_email_preferences.report_on_suspicious_activity | ||
|
||
send_email_for_factor_enrollment_enabled = var.security_notification_email_preferences.notify_on_factor_enrollment | ||
send_email_for_factor_reset_enabled = var.security_notification_email_preferences.notify_on_factor_reset | ||
send_email_for_new_device_enabled = var.security_notification_email_preferences.notify_on_new_device | ||
send_email_for_password_changed_enabled = var.security_notification_email_preferences.notify_on_password_changed | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
output "security_notification_email_preferences" { | ||
description = "The preferences for security notification emails." | ||
value = { | ||
report_on_suspicious_activity = okta_security_notification_emails.this.report_suspicious_activity_enabled | ||
notify_on_factor_enrollment = okta_security_notification_emails.this.send_email_for_factor_enrollment_enabled | ||
notify_on_factor_reset = okta_security_notification_emails.this.send_email_for_factor_reset_enabled | ||
notify_on_new_device = okta_security_notification_emails.this.send_email_for_new_device_enabled | ||
notify_on_password_changed = okta_security_notification_emails.this.send_email_for_password_changed_enabled | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# variable "name" { | ||
# description = "(Required) A name of the organization." | ||
# type = string | ||
# nullable = false | ||
# } | ||
|
||
variable "security_notification_email_preferences" { | ||
description = <<EOF | ||
(Optional) A preferences for security notification emails. `security_notification_email_preferences` block as defined below. | ||
(Optional) `report_on_suspicious_activity` - Whether to notify end users about suspicious | ||
or unrecognized activity from their account. Defaults to `true`. | ||
(Optional) `notify_on_factor_enrollment` - Whether to notify end users of any activity on their account related to MFA factor enrollment. Defaults to `true`. | ||
(Optional) `notify_on_factor_reset` - Whether to notify end users that one or more factors have been reset for their account. Defaults to `true`. | ||
(Optional) `notify_on_new_device` - Whether to notify end users about new sign-on activity. Defaults to `false`. | ||
(Optional) `notify_on_password_changed` - Whether to notify end users that the password for their account has changed. Defaults to `true`. | ||
EOF | ||
type = object({ | ||
report_on_suspicious_activity = optional(bool, true) | ||
notify_on_factor_enrollment = optional(bool, true) | ||
notify_on_factor_reset = optional(bool, true) | ||
notify_on_new_device = optional(bool, false) | ||
notify_on_password_changed = optional(bool, true) | ||
}) | ||
default = {} | ||
nullable = false | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
terraform { | ||
required_version = ">= 1.6" | ||
|
||
required_providers { | ||
okta = { | ||
source = "okta/okta" | ||
version = ">= 4.8" | ||
} | ||
} | ||
} |