My T-SQL Tuesday contribution for this month is about doing easy demos using containers. Which is hosted by Anthony Nocentino this month.
Anthony has invited us all to share your experiences using containers, and not just SQL Server in containers. You can find out more about the invite by clicking this link about his T-SQL Tuesday 140 invitation or on the image below.
Easy demos using containers
I’ve been doing easy demos using containers on my laptop for some time now. Because it’s easy to use them for testing purposes. For example, testing SQL Server deployments using Azure DevOps.
More recently, I have been using them for a series of DevOps related sessions that I co-present with Sander Stad.
Due to the increasing demand for Azure DevOps and GitHub we have various sessions about using them for Data Platform deployments. Based on real-life experience. In fact, we even do one now about how to use Azure DevOps and GitHub together for Data Platform deployments. Since that appears to be in demand.
Anyway, during these sessions we tend to do a pipeline demo like the one below. Done within either Azure Pipelines in Azure DevOps or GitHub Actions. I use a standard set of containers locally for both demos. In order to show how to do show deployments to local SQL Server 2019 instances and databases in Azure within one pipeline.
In the above pipeline, I use three separate containers with SQL Server installed for the Integration, Staging and Production stages. Plus, I use a local SQL Server instance for the unit testing stage. I do this for performance reasons because tests showed it ran faster locally and it is a live demo.
It’s very easy to get demos ready using containers within Docker Desktop. To get the SQL Server 2019 instances ready for demos all I do is start the containers up in Docker Dashboard.
In reality, I can also start them from a command line. However, I like doing it this way.
In the past, I did demos like this using Hyper-V virtual machines. However, using containers for demos like this is so much easier.
In addition to testing automated SQL Server deployments, I have been using SQL Server in containers on my laptop to test things as well. For instance, various Azure Data Engineering services.
For example, I used a database inside container to test that I can connect a local SQL Server database to Azure Synapse Analytics.
I call this section stealth containers for a good reason. Because the reality is that I have been using containers a lot in Azure. In fact, so have a lot of people who are reading this post. Due to the fact that containers are used for a lot of Data Platform services.
For example, the Spark clusters used in both Azure Databricks and Azure Synapse Analytics use containers. In addition to other online applications and services that you use. Hence why I call them stealth containers.
Final words about doing easy demos using containers
I hope this month’s contribution about doing easy demos using containers has been an interesting read.
If you use containers for other things you are more than welcome to leave a comment. Because I know that others are keen to know as well.