Automating Nightly Local Database Refreshes from Azure Blob Storage with Docker

This page summarizes the projects mentioned and recommended in the original post on dev.to

Our great sponsors
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • SaaSHub - Software Alternatives and Reviews
  • AzureAutomation

  • This article assumes that you have already set up an automation to back up your production database to Azure Blob Storage. If you have not done this, you can follow the instructions in this article: Automating Nightly Database Backups to Azure Blob Storage. The script in the article is reaching end of life, and an updated version can be found here.

  • az-bacpac-blob-mssql-importer

    This Docker container is designed to automatically download the latest database backup in a `bacpac` format from an Azure Blob Storage container and import it into the included local, dockerized MSSQL Server instance.

  • The code for this solution is available on GitHub. This docker container is also available on Docker Hub.

  • WorkOS

    The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.

    WorkOS logo
  • jmespath.py

    JMESPath is a query language for JSON.

  • The Azure CLI lets us write queries to filter the results of the az storage blob list command. The queries are written in JMESPath, which is a query language for JSON. In this case, we are filtering the results to only include blobs that end with the .bacpac extension and then selecting the first one as ordered by the lastModified property. If there are no blobs found, the script exits with a failure code. If we find a blob, we download it to the local path specified by the localPath variable.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts