Azure / Azure/azure-quickstart-templates

how to create php web app with ARM template

Open
#6,487 3 comments 1 reaction 0 assignees View on GitHub
Dominant language
Bicep
Stars
14.9k
Forks
16.2k
Avg merge
6d 21h
Merged PRs (30d)
6

Description

--------------------MESSAGE FROM ADMIN, DELETE BEFORE SUBMITTING----------------------

Sorry to hear you had a bad experience with one of the templates :worried: But, in case you're just asking a question, we're happy to help. You can also check if the question might already have been asked here https://github.com/Azure/azure-quickstart-templates/issues?utf8=%E2%9C%93&q=is%3Aissue

We've created an outline of recommended sections to fill out that will help make this Pull Request awesome!

--------------------MESSAGE FROM ADMIN, DELETE BEFORE SUBMITTING----------------------

[Template Name goes here](Template link goes here)

[Enter feedback here]
I use the following arm template to create php web app, but after I deploy the template successfully, I also can see the default language is .Net. How to fix it.
The template json is as below
```
{
"apiVersion": "2018-11-01",
"name": "[concat(parameters('webSiteName'),copyIndex(1))]",
"type": "Microsoft.Web/sites",
"location": "[resourceGroup().location]",
"copy": {
"name": "webloop",
"count": 2
},
"identity": {
"type": "SystemAssigned"
},
"dependsOn": [
"[concat(variables('targetResourceId'),copyIndex(1))]",
"[resourceId('Microsoft.Storage/storageAccounts', parameters('storageAccountName'))]"
],
"tags": {
"project": "zdemo"
},
"properties": {
"name": "[concat(parameters('webSiteName'),copyIndex(1))]",
"serverFarmId": "[concat(variables('targetResourceId'),copyIndex(1))]",
"siteConfig": {
"phpVersion": "7.3",
"use32BitWorkerProcess": false,
"connectionStrings": [
{
"name": "connstr",
"connectionString": "[concat('DefaultEndpointsProtocol=https;AccountName=', parameters('storageAccountName'), ';AccountKey=', listKeys(resourceId('Microsoft.Storage/storageAccounts', parameters('storageAccountName')), '2015-05-01-preview').key1,';EndpointSuffix=core.windows.net')]",
"type": "Custom"
}
]
}
}
}
```

---
#### Document Details

⚠ *Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.*

* ID: 583b2ab0-b032-7fa9-d21f-5203284bd68c
* Version Independent ID: 1e1b0a76-476a-2e71-8eae-837658840081
* Content: [Azure Resource Manager template samples - App Service](https://docs.microsoft.com/en-us/azure/app-service/samples-resource-manager-templates)
* Content Source: [articles/app-service/samples-resource-manager-templates.md](https://github.com/Microsoft/azure-docs/blob/master/articles/app-service/samples-resource-manager-templates.md)
* Service: **app-service**
* GitHub Login: @tfitzmac
* Microsoft Alias: **tomfitz**

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with articles/app-service/samples-resource-manager-templates.md and the provided Microsoft.Web/sites resource, especially siteConfig.phpVersion. Compare the sample's App Service configuration with the deployed result; done means a reproducible template configuration that creates the PHP app with PHP as its runtime rather than the reported .NET default.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, php
Domain
cloud, web-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.