Added Authentik TF code
All checks were successful
Check with kubeconform / lint (push) Successful in 12s
All checks were successful
Check with kubeconform / lint (push) Successful in 12s
This commit is contained in:
@@ -46,4 +46,13 @@ resource "authentik_policy_binding" "app_access" {
|
||||
timeout = lookup(each.value, "timeout", 30)
|
||||
negate = lookup(each.value, "negate", false)
|
||||
failure_result = lookup(each.value, "failure_result", true)
|
||||
}
|
||||
|
||||
# Binding groups to the application
|
||||
resource "authentik_policy_binding" "group_bindings" {
|
||||
for_each = { for idx, group_id in var.access_groups : idx => group_id }
|
||||
|
||||
target = authentik_application.app.uuid
|
||||
group = each.value
|
||||
order = 10 + each.key
|
||||
}
|
||||
@@ -10,7 +10,7 @@ output "application_id" {
|
||||
|
||||
output "application_uuid" {
|
||||
description = "UUID of the application"
|
||||
value = authentik_application.app.id
|
||||
value = authentik_application.app.uuid
|
||||
}
|
||||
|
||||
output "application_slug" {
|
||||
|
||||
@@ -142,4 +142,10 @@ variable "access_policies" {
|
||||
failure_result = optional(bool, true)
|
||||
}))
|
||||
default = {}
|
||||
}
|
||||
|
||||
variable "access_groups" {
|
||||
description = "List of group IDs that have access to the application"
|
||||
type = list(string)
|
||||
default = []
|
||||
}
|
||||
Reference in New Issue
Block a user