Azure / Azure/azure-cli

Deleting an app setting in a function app slot, clears tick for deployment slot setting in production slot

Open
#16,910 5 comments 0 reactions 0 assignees View on GitHub
act-observability-squad Functions Service Attention
Dominant language
Python
Stars
4.6k
Forks
3.5k
Avg merge
3d 2h
Merged PRs (30d)
60

Description

## Describe the bug
I created a slot for a function app, and because of an (I think) [issue](https://github.com/Azure/azure-cli/issues/16805), the app settings are copied from Production slot. Then I have to delete the app settings that I don't want this slot have.
After running the command for deleting the app settings from a slot, I realised that the ticks for deployment slot settings for the same config name in production slot is been cleared.

**Command Name**
```
az functionapp config appsettings delete -g MyRGName -n MyAppName --slot MySlotName --setting-names MySettingName
```

**Errors:**
no error.

## To Reproduce:
Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.

- Create a function app (MyAppName) in a resource group (MyRGName)
- Add a setting (MySettingName) with a value and make it a slot setting:
```
az functionapp config appsettings set -g MyRGName -n MyAppName --setting-names "MySettingName=MySettingValue"
```
- Create a slot:
```
az functionapp deployment slot create --resource-group MyRGName --name MyAppName --slot MySlotName
```
- Delete the setting (MySettingName) from your newly created slot:
```
az functionapp config appsettings delete -g MyRGName -n MyAppName --slot MySlotName --setting-names MySettingName
```
- Check the tick for slot setting for the MySettingName but in production slot.

## Expected Behavior
Updating any configuration in a slot shouldn't affect other slots.

## Environment Summary
```
Windows-10-10.0.19041-SP0
Python 3.6.8
Installer: MSI

azure-cli 2.13.0 *

Extensions:
aks-preview 0.4.61
application-insights 0.1.1
azure-devops 0.13.0
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.