Manage your Azure resources using automation tasks

Published Feb 24 2021 12:13 AM 10.4K Views

There are different ways to manage your Azure resources depending on your specific needs. With automation tasks, Azure offers a simple way to manage a specific resource or resource group using automation task templates. These templates depend on the Azure resource. For example, for an Azure virtual machine, you can create an automation task that turns on or turns off that virtual machine on a predefined schedule or sends the resource's monthly cost. This can be especially helpful if you are trying to reduce the cost of your Azure VMs.

An automation task is actually a workflow that runs on the Azure Logic Apps service behind the scenes. Automation tasks are currently in preview and support sending monthly cost for all Azure resources and special templates for Azure virtual machines, Azure Storage accounts, and Azure Cosmos DB.


You might now think how this is different from Azure Automation. For that, you can check out the following article on Microsoft Docs.



How to create an automation task

Creating an automation task is simple. In the Azure Portal, find the resource you want to manage, and on the resource menu, scroll to the Automation section and select Tasks.


Create automation task for an Azure resourceCreate automation task for an Azure resource


Now you will see the existing automation tasks, or you can click on Add to add a new automation task from a template.


Add a TaskAdd a Task


You can select the template you want to use. Under Authentication, the necessary connections for that specific task appear. You will need to create these connections.



In the configuration section, you can add additional information for the task. In this example, I start the virtual machine every day at 10 am.


Task ConfigurationTask Configuration


After the automation task has been created, you can see it under Tasks. You can see the tasks and view the runs, as well as edit the task.


View and edit automation tasksView and edit automation tasks

You can do in-line editing to make simple changes, but you can also open it in the Logic Apps Designer.


Logic Apps DesignerLogic Apps Designer



Automation Tasks is currently in preview and provides an easy and simple way to manage Azure resources. If you want to learn more, check out Microsoft Docs. If you want to provide feedback, report bugs, or ask questions, you can contact the Azure logic Apps team.




Wondering what is official stance of Microsoft Azure about automation of resources in Azure. Per portal one shall rely on Logic Apps while documentation and common sense says to use Azure Automation. It would be good to invest time and energy in learning one tool for automating resources and not 2 completely different tools which seems to be target to perform similar functions.

Regular Visitor
Unfortunately I always get the following error with my MSDN subscription.


  "error": {
    "code": "InvalidAuthenticationTokenTenant",
    "message": "The access token is from the wrong issuer '*****/'. It must match the tenant '*****/' associated with this subscription. Please use the authority (URL) '*****' to get the token. Note, if the subscription is transferred to another tenant there is no impact to the services, but information about new tenant could take time to propagate (up to an hour). If you just transferred your subscription and see this error message, please try back later."


Regular Visitor

Interestingly, the AutoShutdown function works without problems.

Version history
Last update:
‎May 11 2021 06:42 AM
Updated by: