You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

如何在VS Code中本地调试启用HTTPS的Azure C# Http Trigger Function

在VS Code中同时启用HTTPS并调试Azure HTTP触发函数的问题
  • 已完成证书配置,执行命令func start --cert C:/temp/localhost.pfx --password password可正常启动Function,但无法进行调试。
  • 在VS Code环境下,能够单独完成本地调试,也能单独启用HTTPS运行,但无法同时实现HTTPS启用与本地调试。
  • 配置HTTPS后添加--useHttps参数会直接导致调试功能失效。
  • 运行前必须删除bin和obj文件夹,否则会出现“存在两个项目文件”的提示。

尝试使用的launch配置片段如下:

{
  "label":"runSecureHost",
  "type":"func",
  "command":"func start --cert C:/temp/localhost.pfx --password yourP@ssword --useHttps --debug",
  "isBackground":true,
  "presentation":{
    "reveal":"always"
  },
  "options": {
    "cwd": "${workspaceFolder}/src"
  }
}

内容的提问来源于stack exchange,提问作者EnenDaveyBoy

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.21 16:09:53