반응형
ABC.cs
var config = new ConfigurationBuilder()
.SetBasePath(context.FunctionAppDirectory)
.AddJsonFile("local.settings.json", optional: true, reloadOnChange: true)
.AddEnvironmentVariables()
.Build();
#if DEBUG
var webHookUrl = config["TeamsUrlDebug"];
#else
var webHookUrl = config["TeamsUrl"];
#endif
local.settings.json
{
"TeamsUrl":"asdf",
"TeamsUrlDebug":"asdfDebug"
}
www.tomfaltesek.com/azure-functions-local-settings-json-and-source-control/
Azure Functions local.settings.json Secrets and Source Control
Since you've landed on this article, you must have experienced some of the confusion tied to not committing the local.settings.json file to source control. It's not entirely obvious how developers are supposed to manage the local application settings for t
www.tomfaltesek.com
'C#' 카테고리의 다른 글
[C#] TimeSpan 24시간 이상 파싱 (0) | 2021.04.15 |
---|---|
[C#] TimeSpan Add, 더하기: 시간 간격을 다루는 강력한 기능 (0) | 2021.04.14 |
[C#] ?? 및 ??= 연산자 (0) | 2021.04.07 |
[C#] 부울 논리 연산자 (0) | 2021.04.06 |
BBOX 관련 웹 사이트 모음(설명, 예제, 깃허브) (0) | 2021.04.05 |
댓글