Hello @Stan Frambach ,
Welcome to Microsoft Q&A Platform. Thank you for reaching out & hope you are doing well.
I understand that you would like to update the backend settings for a multi path application gateway using Azure CLI or PowerShell.
You can use the az network application-gateway url-path-map rule
command to manage the rules of a URL path map in Azure Application gateway.
To achieve your requirement, run the below Azure CLI command:
az network application-gateway url-path-map rule create -g resourcegroupname --gateway-name appgatewayname -n target2 --path-map-name rulename --paths /bar --address-pool pool --http-settings NEWSETTINGS
Just replace the resource group name, application gateway name and the application gateway rule name where this path-based rules are added in the above command and run it. It will update your target2 path to use the NEWSETTINGS.
NOTE: Even though it is a create rule command, when used with the same path and target name on the application gateway, it will update the existing path target settings.
I tried this in my lab, and it works. You can see the screenshots below for reference:
After the command completed successfully, the httpsettings for the targetname "target2" was updated as below:
Kindly let us know if you need further assistance on this issue.
Please "Accept the answer" if the information helped you. This will help us and others in the community as well.