Sign inSign up

cilliemalan/sqlserver

By cilliemalan

Updated about 6 years ago

SQL Server with some additional settings for initializing a database

Image
0

1.4K

cilliemalan/sqlserver repository overview

#SQL Server

adds these options on top of the usual ones:

  • DB_NAME - Creates a database with the given name.
  • DB_USER - Creates a login with the given name. Also creates a user on the database above with db_owner.
  • DB_PASSWORD - The password for the login above.

Also differs from the usual SQL Server image in that the container runs as root, but SQL Server itself is run as the mssql user. This is because under certain environments (k8s for example), mssql will not be able to create files in /var/opt/mssql if a volume is mounted there. To fix this, this image chowns that folder (as root) and then starts sql server as mssql with access to that folder, but nothing else.

Warning: the SQL script that creates the above database and login does a naive envsubst, it doesn't escape stuff so don't include quotes or square brackets in your database names.

Tag summary

Content type

Image

Digest

Size

514.3 MB

Last updated

almost 7 years ago

docker pull cilliemalan/sqlserver