DevOps
  • DevOps
  • Docker
    • Overview
  • Vagrant
    • Overview
    • Installation
    • Basic Commands
    • Vagrantfile
      • Example
    • Deploying Multiple Machine
    • Distribution
    • Reference
  • Running SQL Server on Windows Docker
    • Introduction
      • Windows Container & Hyper-V Container
    • System Requirements and Prerequisites
    • Version Compatibility
    • Enable Hyper-V & Containers and Install Docker on Window Servers
    • Using Docker to Run MSSQL Image
    • Install SSMS for remoting MSSQL Server Image
    • Using Docker-Compose to Build Up a MSSQL Image
    • Increase the default Windows container's storage
    • Reference
    • Appendix
  • Kubernetes
    • Install Kubernetes with kubeasz
    • Use Hyper-V Manager to create VM for K8S
      • Specification of the VM
      • Use Hyper-V Manager to turn on a VM for K8S
    • Installation
      • Install VirtualBox and its extension on Ubuntu
      • Install kubectl
      • Install minikube
    • Getting Started
      • Running Kubernetes Locally via Minikube
    • Assign Memory Resources to Containers and Pods
    • Assign CPU Resources to Containers and Pods
    • Quality of Services (QoS)
    • Volume for Storage
      • Configure a Pod to Use a Volume for Storage
      • *Configure a Pod to Use a PersistentVolume for Storage
    • In a nutshell...
    • Reference
  • Ansible
    • What is Ansible?
    • Set Up OS Environments for Ansible
    • Install Ansible
    • Structure for ansible
      • Inventory
      • Playbook
      • Modules
      • Variables
      • Conditions
    • Security - Ansible Fault
    • 實際操作測試1 - 使用ssh
    • 實際操作測試2 - Docker容器部署
    • Appendix
    • Reference
  • Azure
    • Overview
    • Terms
    • Getting Started
    • Azure DevOps Services
    • Reference
Powered by GitBook
On this page

Was this helpful?

  1. Running SQL Server on Windows Docker

Using Docker to Run MSSQL Image

Finally, we are here..

Using Docker Command

docker run -e "ACCEPT_EULA=Y" -e "SA_PASSWORD=Atalces!1" -p 1433:1433 --name sqlserver2 -d -h sqlserver microsoft/mssql-server-windows-developer:latest-14393 

docker will pull the mssql image with the version latest-14393

Only this patch can match our vm's OS version and run process-isolation type of container

After 30 seconds, run the command docker ps

CONTAINER ID        IMAGE                                                   COMMAND                  CREATED
 STATUS                    PORTS                    NAMES
55c3dffeeffb        microsoft/mssql-server-windows-developer:latest-14393   "powershell -Command…"   34 hours ago
 Up 38 seconds (healthy)   0.0.0.0:1433->1433/tcp   sqlserver2

Run docker exec -it <sql_container_name> sql and we can execute sql command inside the image.

PreviousEnable Hyper-V & Containers and Install Docker on Window ServersNextInstall SSMS for remoting MSSQL Server Image

Last updated 6 years ago

Was this helpful?