Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Allow to turn off/on "Incoming client certificates" for azurerm_app_service #2004

Closed
alexeyklots opened this issue Oct 1, 2018 · 5 comments · Fixed by #2765

Comments

@alexeyklots
Copy link

Hi,

Please, add a possibility to turn off/on "Incoming client certificates" in azurerm_app_service resource.
In section SSL setting of the Web App. See screenshot below.

Thanks in advance!
Alexey
image

@kevinneufeld
Copy link

kevinneufeld commented Oct 1, 2018

The app service property is clientCertEnabled:

FWIW: In the meantime, you can try this, it should work, not tested.

resource "azurerm_template_deployment" "service_app_client_cert_enabled" {
  name                = "${format("%s-arm-client-cert-enabled", azurerm_app_service.test.name)}"
  resource_group_name = "${azurerm_app_service.test.resource_group_name}"
  deployment_mode     = "Incremental"

  template_body = <<DEPLOY
{
    "$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
    "contentVersion": "1.0.0.0",
    "parameters":{
        "appServiceName": {
            "type": "String"
        },
        "clientCertEnabled": {
            "type": "String",
        }
    },
    "variables": {},
    "resources": [
        {
            "type": "Microsoft.Web/sites",
            "kind": "app",
            "name": "[parameters('appServiceName')]",
            "apiVersion": "2016-08-01",
            "location": "UK South",
            "properties": {
                "clientCertEnabled": "[bool(parameters('clientCertEnabled'))]"
            },
            "dependsOn": []
        }
    ],
    "outputs": {}
}
DEPLOY

  parameters {
    "appServiceName"    = "${azurerm_app_service.test.name}"
    "clientCertEnabled" = "${var.app_service_client_cert_enabled_bool}"
  }

  depends_on = []
}

@alexeyklots
Copy link
Author

Thanks Kevinneufeld for solution! I understand that I can use ARM template to cover all missed functionality in TF. But I'd like to avoid using such workaround as much as possible.
I hope that this improvement will be included by TF team in their plans.

@maniSbindra
Copy link
Contributor

@tombuildsstuff I will work on PR to add this enhancement

@alexeyklots
Copy link
Author

Thanks!

@ghost
Copy link

ghost commented Mar 5, 2019

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 [email protected]. Thanks!

@ghost ghost locked and limited conversation to collaborators Mar 5, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
5 participants