Skip to content

Commit

Permalink
azurerm_linux_web_app, azurerm_linux_web_app_slot: add python 3.1…
Browse files Browse the repository at this point in the history
…0 support in linux web app (#18744)
  • Loading branch information
xiaxyi authored Oct 13, 2022
1 parent a16ceb9 commit 08ff58c
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 2 deletions.
1 change: 1 addition & 0 deletions internal/services/appservice/helpers/web_app_schema.go
Original file line number Diff line number Diff line change
Expand Up @@ -1193,6 +1193,7 @@ func linuxApplicationStackSchema() *pluginsdk.Schema {
"3.7",
"3.8",
"3.9",
"3.10",
}, false),
AtLeastOneOf: []string{
"site_config.0.application_stack.0.docker_image",
Expand Down
15 changes: 15 additions & 0 deletions internal/services/appservice/linux_web_app_resource_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -673,6 +673,21 @@ func TestAccLinuxWebApp_withPython39(t *testing.T) {
})
}

func TestAccLinuxWebApp_withPython310(t *testing.T) {
data := acceptance.BuildTestData(t, "azurerm_linux_web_app", "test")
r := LinuxWebAppResource{}

data.ResourceTest(t, r, []acceptance.TestStep{
{
Config: r.python(data, "3.10"),
Check: acceptance.ComposeTestCheckFunc(
check.That(data.ResourceName).ExistsInAzure(r),
),
},
data.ImportStep(),
})
}

func TestAccLinuxWebApp_withRuby26(t *testing.T) {
data := acceptance.BuildTestData(t, "azurerm_linux_web_app", "test")
r := LinuxWebAppResource{}
Expand Down
15 changes: 15 additions & 0 deletions internal/services/appservice/linux_web_app_slot_resource_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -686,6 +686,21 @@ func TestAccLinuxWebAppSlot_withPython39(t *testing.T) {
})
}

func TestAccLinuxWebAppSlot_withPython310(t *testing.T) {
data := acceptance.BuildTestData(t, "azurerm_linux_web_app_slot", "test")
r := LinuxWebAppSlotResource{}

data.ResourceTest(t, r, []acceptance.TestStep{
{
Config: r.python(data, "3.10"),
Check: acceptance.ComposeTestCheckFunc(
check.That(data.ResourceName).ExistsInAzure(r),
),
},
data.ImportStep(),
})
}

func TestAccLinuxWebAppSlot_withRuby26(t *testing.T) {
data := acceptance.BuildTestData(t, "azurerm_linux_web_app_slot", "test")
r := LinuxWebAppSlotResource{}
Expand Down
2 changes: 1 addition & 1 deletion website/docs/r/linux_web_app.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ An `application_stack` block supports the following:

~> **NOTE:** versions `5.6` and `7.2` are deprecated and will be removed from the provider in a future version.

* `python_version` - (Optional) The version of Python to run. Possible values include `3.7`, `3.8`, and `3.9`.
* `python_version` - (Optional) The version of Python to run. Possible values include `3.7`, `3.8`, `3.9` and `3.10`.

* `ruby_version` - (Optional) Te version of Ruby to run. Possible values include `2.6` and `2.7`.

Expand Down
2 changes: 1 addition & 1 deletion website/docs/r/linux_web_app_slot.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ An `application_stack` block supports the following:

~> **NOTE:** versions `5.6` and `7.2` are deprecated and will be removed from the provider in a future version.

* `python_version` - (Optional) The version of Python to run. Possible values include `3.7`, `3.8`, and `3.9`.
* `python_version` - (Optional) The version of Python to run. Possible values include `3.7`, `3.8`, `3.9` and `3.10`.

* `ruby_version` - (Optional) Te version of Ruby to run. Possible values include `2.6` and `2.7`.

Expand Down

0 comments on commit 08ff58c

Please sign in to comment.