Export template from a running resource group

In Azure portal, you can pick your current resource group and select Export template in Settings. Once the template is exported, you can download the template file or trigger a new deployment from the portal. You can also find the PowerShell script and CLI script you can use to deploy the template.