From 7741196235661ce0209faf5442ccb7148fb14d20 Mon Sep 17 00:00:00 2001 From: JJmomark Date: Wed, 11 Apr 2018 18:05:33 +0800 Subject: [PATCH] fix pr ADD MSSQL_PID DEL scale ADD README.md --- templates/mssqlserver/0/README.md | 38 +++++++++++++++++++++ templates/mssqlserver/0/docker-compose.yml | 4 +-- templates/mssqlserver/0/rancher-compose.yml | 26 ++++++++------ templates/mssqlserver/config.yml | 2 +- 4 files changed, 56 insertions(+), 14 deletions(-) create mode 100644 templates/mssqlserver/0/README.md diff --git a/templates/mssqlserver/0/README.md b/templates/mssqlserver/0/README.md new file mode 100644 index 0000000..4c93867 --- /dev/null +++ b/templates/mssqlserver/0/README.md @@ -0,0 +1,38 @@ +# Microsoft Sqlserver 2017 + +Before you start, please read this first. + +### ACCEPT_EULA + +the container of this package will start with 'ACCEPT_EULA=Y' environment variable. +Which means you accepted the [EULA](https://go.microsoft.com/fwlink/?linkid=857698) from Microsoft. + +By passing the value "Y" to the environment variable "ACCEPT_EULA", you are expressing that you have a valid and existing license for the edition and version of SQL Server that you intend to use. You also agree that your use of SQL Server software running in a Docker container image will be governed by the terms of your SQL Server license. + + +### MSSQL_PID + +MSSQL_PID is the Product ID (PID) or Edition that the container will run with. Acceptable values: + +* 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 + +For a complete list of environment variables that can be used, refer to the documentation here + +[https://docs.microsoft.com/en-us/sql/linux/quickstart-install-connect-docker](https://docs.microsoft.com/en-us/sql/linux/quickstart-install-connect-docker). + +### SA_PASSWORD + +A strong system administrator (SA) password: At least 8 characters including uppercase, lowercase letters, base-10 digits and/or non-alphanumeric symbols. + + +### For more information + +please check out here: + +[https://hub.docker.com/r/microsoft/mssql-server-linux/](https://hub.docker.com/r/microsoft/mssql-server-linux/) + +[https://github.com/Microsoft/mssql-docker](https://github.com/Microsoft/mssql-docker) \ No newline at end of file diff --git a/templates/mssqlserver/0/docker-compose.yml b/templates/mssqlserver/0/docker-compose.yml index 76f73c4..6fbe6c7 100644 --- a/templates/mssqlserver/0/docker-compose.yml +++ b/templates/mssqlserver/0/docker-compose.yml @@ -5,16 +5,14 @@ services: environment: ACCEPT_EULA: Y MSSQL_SA_PASSWORD: ${mssql_password} + MSSQL_PID: ${mssql_pid} stdin_open: true volumes: - mssqlvolume:/var/opt/mssql tty: true ports: - ${mssql_port}:1433/tcp - labels: - io.rancher.container.pull_image: always volumes: mssqlvolume: driver: ${VOLUME_DRIVER} - per_container: true \ No newline at end of file diff --git a/templates/mssqlserver/0/rancher-compose.yml b/templates/mssqlserver/0/rancher-compose.yml index 023f0e4..cab2870 100644 --- a/templates/mssqlserver/0/rancher-compose.yml +++ b/templates/mssqlserver/0/rancher-compose.yml @@ -1,26 +1,34 @@ +version: '2' .catalog: name: MSSQLServer version: 2017-CU5-rancher1 description: sqlserver - maintainer: "JagJag " + maintainer: "Jiang Jiang " questions: - - variable: "mssqlscale" - type: "int" + - variable: "mssql_pid" + label: "Mssql edition:" + description: | + Choose mssql edition to be run. + default: Developer required: true - label: "# of mssql instance " - description: "# of mssql instance" - default: 3 + type: enum + options: + - Developer + - Express + - Standard + - Enterprise + - EnterpriseCore - variable: "mssql_password" type: "string" required: true label: "SA Password" - description: "require Strong Password" + description: " At least 8 characters including uppercase, lowercase letters, base-10 digits and/or non-alphanumeric symbols." default: - variable: "mssql_port" type: "string" required: true label: "mssql_port" - description: "connect port" + description: "connect to mssql by this port" default: 1433 - variable: "VOLUME_DRIVER" description: "The VOLUME driver to associate with this server" @@ -34,8 +42,6 @@ - rancher-efs - rancher-ebs -version: '2' services: mssql-linux: - scale: ${mssqlscale} start_on_create: true diff --git a/templates/mssqlserver/config.yml b/templates/mssqlserver/config.yml index 4048232..58d94f6 100644 --- a/templates/mssqlserver/config.yml +++ b/templates/mssqlserver/config.yml @@ -1,4 +1,4 @@ -name: Microsoft SQLSERVER +name: Microsoft Sqlserver description: | Microsoft sqlserver 2017 docker edition version: 2017-CU5-rancher1