Mssql-docker: Licensing unclarity

Created on 15 Nov 2017  路  14Comments  路  Source: microsoft/mssql-docker

We're looking into running SQL Server as a container in a production environment. I read before that the normal licensing model applies, but there isn't any direction to how this works in practise. Where do I enter my product key? What if I spin up multiple containers?

Also seems like the actual Windows based MSSQL image is taken down? It used to be at https://hub.docker.com/r/microsoft/mssql-server-windows/

Most helpful comment

Yes, if you pass Standard, it is a fully featured, unlimited Standard instance. It's not a trial. The only thing that "stops" you from using Standard edition without paying for it is the license agreement that you accept with ACCEPT_EULA=Y. The terms of the EULA state that if you use a paid edition like Standard, Enterprise, etc. then you do need to pay for it of course, but we don't try to enforce the payment in some technical way at the time that you start the container.

All 14 comments

You dont need to enter a product key for SQL Server on Linux. You just pass the MSSQL_PID environment variable and specify Enterprise, Standard, Web, Express. Details can be found here: https://hub.docker.com/r/microsoft/mssql-server-linux/

You can have multiple containers but they each need to be licensed. You can read about the different options for licensing SQL Server in containers in the licensing data sheet here: https://www.microsoft.com/en-us/sql-server/sql-server-2017-pricing

There are two Windows SQL Server images:
https://hub.docker.com/r/microsoft/mssql-server-windows-developer/
https://hub.docker.com/r/microsoft/mssql-server-windows-express/
Keep in mind that Windows-based SQL Servers are not supported in production. Only the Linux-based containers.

OK, we would very much like to switch to Linux-based docker containers for SQL Server, but the obvious DB attachment functionality is missing there. Is this going to be added as well?

Probably at some point. In the meantime, you can create use sqlcmd to attach the DB in your own Dockerfile. You can get some ideas on how to do this from this project: https://github.com/twright-msft/mssql-node-docker-demo-app

Thanks for clarifying. Going back to the MSSQL_PID to be passed to the container:

Developer : This will run the container using the Developer Edition (this is the default if no MSSQL_PID environment variable is supplied)
Express : This will run the container using the Express Edition
Standard : This will run the container using the Standard Edition
Enterprise : This will run the container using the Enterprise Edition
EnterpriseCore : This will run the container using the Enterprise Edition Core
: This will run the container with the edition that is associated with the PID

If I simply pass in "Standard", it means it will be running a fully featured "Standard" edition, but as a "trial" or something? What stops us from simply running any edition just like that?

Yes, if you pass Standard, it is a fully featured, unlimited Standard instance. It's not a trial. The only thing that "stops" you from using Standard edition without paying for it is the license agreement that you accept with ACCEPT_EULA=Y. The terms of the EULA state that if you use a paid edition like Standard, Enterprise, etc. then you do need to pay for it of course, but we don't try to enforce the payment in some technical way at the time that you start the container.

@twright-msft
I'm still a little unclear about the licensing and evaluation versions. For example, when I start the linux container store/microsoft/mssql-server-linux:2017-CU1 with an Express PID, I see this in the docker logs

This is an evaluation version.  There are [48] days left in the evaluation period.
2017-12-06 19:38:17.33 Server      Microsoft SQL Server 2017 (RC2) - 14.0.900.75 (X64)
        Jul 27 2017 08:53:49
        Copyright (C) 2017 Microsoft Corporation
        Express Edition (64-bit) on Linux (Ubuntu 16.04.3 LTS)

What will happen in 48 days? Are there separate production and evaluation docker images?

@nburoojy - Something doesnt add up here. The tag you said you are using it 2017-CU1, but the output from the log is RC2. Pre-GA builds are timebombed to expire in 180 days from the day of the build. After GA, including CU builds, there is no timebomb.
Can you please double check that you are using an image which is tagged as GA+?

Thanks for the info @twright-msft

I double-checked and it looks like my image installed a package from https://packages.microsoft.com/config/ubuntu/16.04/mssql-server.list on top of the mssql docker image which effectively replaced the sqlserver install with a pre-GA version.
I've updated this to https://packages.microsoft.com/config/ubuntu/16.04/mssql-server-2017.list and no longer see the timebomb.

Thanks!

OK, good yeah, that would be the problem. Glad you were able to figure it out. If your goal is to always have latest in your image you can use the :latest (latest regardless of version) or :2017-latest (latest within the 2017 version) tag in your FROM in your Dockerfile.

We have license for the 2016 Enterprise edition. Is the license valid also for docker container (2017 version)?
Or do we have order a new license?
I could not find any official docker image for 2016.

That depends on how you purchased your SQL Server 2016 license. If you bought it _with Software Assurance_, then that will cover you for using it on SQL Server 2017. There isn't a container image for SQL Server 2016 right now and no plans for that for the foreseeable future.

Is it license violation, if I am going to run SQL Server 2016 docker image with "MSSQL_PID: Web" on azure cloud?

We want to replace exiting VM with docker container and I see in documentation that "Web" edition is listed in list of MSSQL_PID possible values.

Whatever licensing policies apply to SQL Server also apply to running SQL Server in a container. Web edition is listed there as an option for completeness, but please use the editions in compliance with the software use right of the license you have.

@twright-msft

Not sure to get this right, but is it allowed to use the Express version in a corporate setting for running integration tests in a CI/CD pipeline?

docker run --name 'MySqlServer' -e 'ACCEPT_EULA=Y' -e 'SA_PASSWORD=MyPassword!' -e 'MSSQL_PID=Express' -p 1433:1433 -d mcr.microsoft.com/mssql/server:2017-latest-ubuntu

According to: https://www.microsoft.com/en-us/sql-server/sql-server-2017-pricing
I'd say yes, but not sure if I'm missing out something.

Was this page helpful?
0 / 5 - 0 ratings