Last active
October 24, 2024 12:22
-
-
Save pbthorste/2dd302939ad84ab26932e9e18b7428d8 to your computer and use it in GitHub Desktop.
Docker image with msssql 2022 with full text search enabled
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Docker image with msssql 2022 with full text search enabled | |
# based on work in: https://github.com/Microsoft/mssql-docker | |
# Base OS layer: Latest Ubuntu LTS | |
FROM --platform=linux/amd64 ubuntu:focal | |
# Install prerequistes since it is needed to get repo config for SQL server | |
RUN export DEBIAN_FRONTEND=noninteractive && \ | |
apt-get update && \ | |
apt-get install -yq curl apt-transport-https gnupg && \ | |
# Get official Microsoft repository configuration | |
curl https://packages.microsoft.com/keys/microsoft.asc | apt-key add - && \ | |
curl https://packages.microsoft.com/config/ubuntu/20.04/packages-microsoft-prod.deb --output packages-microsoft-prod.deb && dpkg -i packages-microsoft-prod.deb && \ | |
curl https://packages.microsoft.com/config/ubuntu/20.04/mssql-server-2022.list | tee /etc/apt/sources.list.d/mssql-server.list && \ | |
apt-get update && \ | |
# Install SQL Server from apt | |
apt-get install -y mssql-server && \ | |
# Install optional packages | |
apt-get install -y mssql-server-fts && \ | |
ACCEPT_EULA=Y apt-get install -y mssql-tools && \ | |
# Cleanup the Dockerfile | |
apt-get clean && \ | |
rm -rf /var/lib/apt/lists | |
# Run SQL Server process | |
CMD /opt/mssql/bin/sqlservr | |
What a king. Much appreciated.
You're saver. Thansk!
Thanks a lot, I've been struggling for several hours without any success.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I've been struggling to get a Dockerfile to work. Your file worked great. Thanks!