here is a diagreme explains what i do manually && what i want to automate
- connect to an on-premise gitlab-ce instance
- start a gitlab backup and wait for it to finish
- copy the backup files to azure blob and wait for it to finish
- copy the backup files from blob to azure vm and and wait for it to finish
- connect to azure vm and restore the backup
i want to automate those tasks that i do with an azure tool . can someone guide me to a direction where i can start looking?
can Azure Functions perform those kind of tasks??
thanks.
CodePudding user response:
Thank you Matt Stannett and Anand Sowmithiran. Posting your suggestions as an answer to help other community members.
You can achieve this using a Durable Azure Function with the function chaining pattern.
You need to automate the initiation of the gitlab backup and pushing that as a blob to Azure blob storage - this part needs to run on-prem, so you could use Powershell to this. Then, your Azure blob storage
trigger function
can pick up the backup blob and do the rest of the steps via initiating a durable function, it has to use Azure sdk to restore the backup inside Azure VM
You can refer to Create your first durable function in Python, Storage Providers for Azure Durable Functions, Azure Functions: How to manage Durable Functions with Blob Triggers?, and Automate Linux VM Customization Tasks Using CustomScript Extension