How to publish environment specific appsettings in .Net core app?

后端 未结 12 2423
刺人心
刺人心 2020-12-04 15:33

I have 3 environment specific appsettings files in my .Net core application

in project.json I have setup publishOptions

12条回答
  •  -上瘾入骨i
    2020-12-04 15:51

    In VS2017 Adding multiple environment

    steps right click project --> Add --> NewItem - select json file - write file name as 'appsettings.staging.json' or 'appsettings.production.json'

    Add appsettings.staging.json file

    Output Looks like

提交回复
热议问题