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

App Settings Colon Delimiter Not Allowed #12376

Closed
nehme-bilal-ah opened this issue Feb 18, 2020 · 1 comment
Closed

App Settings Colon Delimiter Not Allowed #12376

nehme-bilal-ah opened this issue Feb 18, 2020 · 1 comment

Comments

@nehme-bilal-ah
Copy link

nehme-bilal-ah commented Feb 18, 2020

Hi,

In my appsettings.json file I have settings like this:

  "AzureStorageSettings": {
    "ConnectionString": "",
    "TableName": "Foo"
  }

I want to override the value of AzureStorageSettings:ConnectionString configuration with a secret stored in Azure Devops. In the past, I used to simply add -AzureStorageSettings:ConnectionString $(AzureStorageConnectionString) to the App settings section of the task and that worked perfectly.

However, with version 4, I get an error saying that colon character is not allowed. Is there a new way of achieving this or a way that I can espace the colon character? I tried everything that I can think of.

@nehme-bilal-ah
Copy link
Author

The solution is to use __ instead of : in App settings. The app settings get added as environment variables and Microsoft.Extensions.Configuration can handle __ for nesting configs.

Horsevad added a commit to Horsevad/azure-docs-nhs-typo that referenced this issue Sep 5, 2024
I believe the wrong OS was references here, and that colon (:) is only supported on Windows, (as it is interpreted by bash as a delimiter on a Linux host trying to set the env var) 

Not using colon in things on Linux is also referenced in: 
https://github.com/Azure/azure-functions-host/wiki/Host-IDs
microsoft/azure-pipelines-tasks#12376
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

5 participants