question

StrykerUser-7437 avatar image
0 Votes"
StrykerUser-7437 asked ·

Changed config of the App service but the web.config file not being updated

Hi,

I tried to change the config of the app service from .NET to PHP but the web.config file of the app service is not being updated even after restarting the App service after applying the updates and the PHP pages are also not working.

Please help.

azure-webapps
· 2
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Thanks for asking question! If I am understanding right you want to change the Runtime Stack setting. Try changing by using Powershell or ARM Template.
Check : How to specify / change Stack settings with PowerShell or ARM template

Let us know if issue remains.


0 Votes 0 ·

Hi SnehaAgrawal,

Thanks for your response.

Is there a way this can be done through Azure portal only?

I change the config from > App Service > Settings > Configuration > General Settings > Updated Stack & PHP version > Click Save

76674-image.png

Then went to App Service > Overview > Restart

76634-image.png

Am I doing anything wrong or missing a step?

Please help.


0 Votes 0 ·
image.png (141.3 KiB)
image.png (28.0 KiB)
SnehaAgrawal-MSFT avatar image
0 Votes"
SnehaAgrawal-MSFT answered ·

Thanks for reply! From portal you are following right steps. just wanted to confirm when clicking on save you might be seeing as below: saying Any changes to application settings and connection strings will restart your application and when hitting on continue are you able to receive notification as successfully updated app settings?


76677-configdemo1.png




76691-configdemo2.png



configdemo1.png (72.8 KiB)
configdemo2.png (19.8 KiB)
configdemo1.png (70.1 KiB)
· 1 ·
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Yes right - I got that. I do get the notification and then I click on the Continue button:

76678-image.png

And then I get this notification:

76567-image.png


But still, the PHP info page doesn't work or the web.config file doesn't get updated.

Following are the default documents of this App Service:

76682-image.png

Following are the content of the web.config file even after making the above-mentioned changes:

76590-image.png


Please help.



0 Votes 0 ·
image.png (46.0 KiB)
image.png (36.8 KiB)
image.png (97.8 KiB)
image.png (100.8 KiB)
SnehaAgrawal-MSFT avatar image
0 Votes"
SnehaAgrawal-MSFT answered ·

Thanks for clarifying! To elaborate on this, General settings which includes Stack settings are that apply to the environment of your web app you runs in.

If you want to change web.config files you can use the Azure portal, there is a tool called "App Service Editor" in preview or Kudu that lets you edit any of the files you've deployed.

77228-demo8.png


Let us know if you have further query.



demo8.png (31.5 KiB)
· 1 ·
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

So SnehaAgrawal, by changing the General settings which includes Stack settings - why aren't the changes being applied to the environment my web app is running in?

Also, what are the updates I need to make on the web.config file directly to change the stack from .NET to PHP as shown previously in the screenshot?

0 Votes 0 ·