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

Function apps don't handle CI/CD #35794

Closed
MarkAtAgilliance opened this issue Jul 24, 2019 — with docs.microsoft.com · 4 comments
Closed

Function apps don't handle CI/CD #35794

MarkAtAgilliance opened this issue Jul 24, 2019 — with docs.microsoft.com · 4 comments

Comments

Copy link

Just a note that function apps do not parameterize their key values in the ARM template so hard to deploy to multiple environments. Not sure what the plan is but today, this makes a mess of CICD because there is no easy way to override the functionAppUrl or the functionKey values in the ARM template. Maybe add a caution box in the doc above until this is fixed.


Document Details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

@CHEEKATLAPRADEEP-MSFT-zz
Copy link
Contributor

@MarkAtAgilliance Thanks for your feedback! We will investigate and update as appropriate.

@ChiragMishra-MSFT
Copy link
Contributor

@MarkAtAgilliance There were a few changes done recently on Function Apps because of which parameterizing key values in ARM templates was affected. To read more about this, please refer this article. The product team is working on rectifying it and it should be done soon.

There's a workaround however to get you unblocked for now. Here is a sample to inject a default functions key in a key vault secret (Ref :#3994) :

"variables": {
"functionAppId": "[concat(parameters('functionAppResourceGroup'),'/providers/Microsoft.Web/sites/', parameters('functionAppName'))]"
},
"resources": [
{
"type": "Microsoft.KeyVault/vaults/secrets",
"name": "[concat(parameters('keyVaultName'),'/', parameters('functionAppName'))]",
"apiVersion": "2015-06-01",
"properties": {
"contentType": "text/plain",
"value": "[listkeys(concat(variables('functionAppId'), '/host/default/'),'2016-08-01').functionKeys.default]"
},
"dependsOn": []
}
]

Hope this helps.

@ChiragMishra-MSFT
Copy link
Contributor

I will now proceed to close this issue. Please feel free still to comment and tag me if you have any queries or ideally provide your feedback on a doc pertaining to Function apps.

Copy link
Author

just to follow up, I eventually did a similar thing but used powershell script instead. Details in the solution here https://stackoverflow.com/questions/57192228/using-function-app-connector-in-adf-how-to-override-parameters-in-ci-cd
I will also investigate if the custom parameters approach can work around this since we need it for another reason (>256 params).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants