# ============================================================================= # CLOUDFLARE : Access Controls : Applications # ============================================================================= #====================================================== # INFRASTRUCTURE Application: Test Home Network Access #====================================================== resource "cloudflare_zero_trust_access_application" "zero_trust_access_application" { account_id = local.cloudflare_account_id type = "self_hosted" name = "Home Network Access Application" domain = "home.tips-of-mine.org" session_duration = "24h" skip_interstitial = true tags = [cloudflare_zero_trust_access_tag.tags["engineers"].name] # tags = [for tag in cloudflare_zero_trust_access_tag.tags : tag.name] depends_on = [ cloudflare_zero_trust_access_tag.tags ] } data "cloudflare_zero_trust_access_application" "zero_trust_access_application" { account_id = local.cloudflare_account_id app_id = cloudflare_zero_trust_access_application.zero_trust_access_application.id } #====================================================== # SELF-HOSTED APP: Competition App #====================================================== # Creating the Self-hosted Application for Competition web application resource "cloudflare_zero_trust_access_application" "cloudflare_app_web_competition" { account_id = local.cloudflare_account_id type = "self_hosted" name = var.cloudflare_sensitive_web_app_name app_launcher_visible = true logo_url = "https://img.freepik.com/free-vector/trophy_78370-345.jpg" tags = [cloudflare_zero_trust_access_tag.tags["engineers"].name] session_duration = "0s" custom_deny_url = "https://denied.tips-of-mine.org/" custom_non_identity_deny_url = "https://denied.tips-of-mine.org/" destinations = [{ type = "public" uri = var.cloudflare_subdomain_web_sensitive }] allowed_idps = [ cloudflare_zero_trust_access_identity_provider.authentik_oidc.id, ] auto_redirect_to_identity = true allow_authenticate_via_warp = false policies = [{ id = cloudflare_zero_trust_access_policy.policies["competition_web_app"].id }] } #====================================================== # SELF-HOSTED APP: Macharpe Intranet #====================================================== # Creating the Self-hosted Application for Administration web application resource "cloudflare_zero_trust_access_application" "cloudflare_app_web_intranet" { account_id = local.cloudflare_account_id type = "self_hosted" name = var.cloudflare_intranet_web_app_name app_launcher_visible = true logo_url = "https://raw.githubusercontent.com/uditkumar489/Icon-pack/master/Entrepreneur/digital-marketing/svg/computer-1.svg" tags = [cloudflare_zero_trust_access_tag.tags["engineers"].name] session_duration = "0s" custom_deny_url = "https://denied.tips-of-mine.org/" custom_non_identity_deny_url = "https://denied.tips-of-mine.org/" destinations = [{ type = "public" uri = var.cloudflare_subdomain_web }] allowed_idps = [ cloudflare_zero_trust_access_identity_provider.authentik_oidc.id, ] auto_redirect_to_identity = true allow_authenticate_via_warp = false policies = [{ id = cloudflare_zero_trust_access_policy.policies["intranet_web_app"].id }] }