You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/linux/tutorial-sql-server-containers-kubernetes-DH2i.md
+8-8Lines changed: 8 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -24,11 +24,11 @@ This tutorial explains how to configure SQL Server Always On availability group
24
24
## Prerequisites
25
25
26
26
1. To deploy Azure Kubernetes Service, you must have an Azure account. A two-node cluster is a good starting point for this tutorial.
27
-
2. Create Azure Container Registry. This will be used in our deployment scripts to retrieve the custom image and deploy the containers to Azure Kubernetes. Instead of ACR, you could use your preferred container registry to push the custom container images.
27
+
2. Create Azure Container Registry. This will be used in our deployment scripts to retrieve the custom image and deploy the containers to Azure Kubernetes. Instead of Azure Container Registry (ACR), you could use your preferred container registry to push the custom container images.
28
28
29
29
## Deploy Azure Kubernetes Service
30
30
31
-
Please follow this [quickstart tutorial](/azure/aks/kubernetes-walkthrough-portal#create-an-aks-cluster) to set up a two-node Kubernetes cluster using the Azure Kubernetes Service. After you've created the cluster, you can connect to it by following the steps outlined in the article's ["connect to the cluster"](/azure/aks/kubernetes-walkthrough-portal#connect-to-the-cluster) section.
31
+
Follow this [quickstart tutorial](/azure/aks/kubernetes-walkthrough-portal#create-an-aks-cluster) to set up a two-node Kubernetes cluster using the Azure Kubernetes Service. After you've created the cluster, you can connect to it by following the steps outlined in the article's ["connect to the cluster"](/azure/aks/kubernetes-walkthrough-portal#connect-to-the-cluster) section.
32
32
33
33
You should now have a two-node kubernetes cluster, and running **kubectl get nodes** from your client machine should yield results similar to this:
## Prepare the SQL Server & DH2i DxEnterprise custom container image
43
43
44
-
Next, we'll create the custom container image that will be used in our deployment manifests. This custom container image will deploy SQL Server, .Net and DxEnterprise in a container. The deployment sample dockerfile is provided below; you can modify it to meet your needs, such as changing the SQL Server version.
44
+
Next, we'll create the custom container image that will be used in our deployment manifests. This custom container image will deploy SQL Server, .Net, and DxEnterprise in a container. The deployment sample dockerfile is provided below; you can modify it to meet your needs, such as changing the SQL Server version.
45
45
46
46
```bash
47
47
FROM mcr.microsoft.com/mssql/server:2019-latest
@@ -86,23 +86,23 @@ $docker build -t <tagname> .
86
86
# you should now be able to see the new image sqlimage when you run the docker images command
87
87
```
88
88
89
-
Now, tag the image and push it to ACR using the commands below. Make sure you've already logged in to ACR using the docker login command; for more information, see [login to ACR](/azure/container-registry/container-registry-get-started-portal#log-in-to-registry).
89
+
Now, tag the image and push it to Azure Container Registry (ACR) using the commands below. Make sure you've already logged in to Azure Container Registry (ACR) using the docker login command; for more information, see [login to ACR](/azure/container-registry/container-registry-get-started-portal#log-in-to-registry).
90
90
91
91
```bash
92
92
$docker tag sqlimage/latest amvinacr.azurecr.io/sqlimage:latest
93
93
#now push to the ACR repo:
94
94
$docker push amvinacr.azurecr.io/sqlimage:latest
95
95
#you can browse your ACR through the portal and should see the repo and the tag listed in the ACR.
96
96
```
97
-
This ensures that the custom image has been pushed to Azure Container Registry (ACR) and that you can now integrate your Azure Kubernetes Service with Azure Container Registry by running the following command; for more information, refer to this (article)[/azure/aks/cluster-container-registry-integration].
97
+
This ensures that the custom image has been pushed to Azure Container Registry (ACR) and that you can now integrate your Azure Kubernetes Service with Azure Container Registry by running the following command; for more information, see this (article)[/azure/aks/cluster-container-registry-integration].
98
98
99
99
```bash
100
100
az aks update -n myAKSCluster -g amvindomain --attach-acr amvinacr
101
101
```
102
102
103
103
## Deploy containers on Azure Kubernetes Service
104
104
105
-
We will deploy SQL Server containers as statefulset deployments; a sample deployment file that deploys the containers on the Azure Kubernetes Service is provided below for reference. Please take note of the following points:
105
+
We will deploy SQL Server containers as statefulset deployments; a sample deployment file that deploys the containers on the Azure Kubernetes Service is provided below for reference. Take note of the following points:
106
106
107
107
1. We will set up three SQL Server instances, one as a primary replica and two as secondary replicas. You can optionally add labels to the node to ensure that the primary replica always runs on one node and the secondary replicas run on another. The following are the steps for labelling the nodes:
108
108
@@ -117,7 +117,7 @@ We will deploy SQL Server containers as statefulset deployments; a sample deploy
Copy the preceding code into a new file called sqldeployment.yaml, update the values like port, image and storage details to suit your needs. Create the deployment using the command below:
312
+
Copy the preceding code into a new file called sqldeployment.yaml, update the values like port, image, and storage details to suit your needs. Create the deployment using the command below:
313
313
314
314
```bash
315
315
kubectl apply -f <Path to sqldeployment.yaml file>
0 commit comments