Skip to content

Commit

Permalink
Adding support for MS SQL Server to docker-compose (#5616)
Browse files Browse the repository at this point in the history
  • Loading branch information
corneil authored Dec 19, 2023
1 parent 00bb9f7 commit 61791f1
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/docker-compose/dc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ SCDIR=$(realpath $SCDIR)
if [ "$1" == "" ]; then
echo "Usage is: "${BASH_SOURCE[0]}" <database> <broker> [compose-command] [options] [flags] [--no-wait]"
echo "Where:"
echo " database: is one of mariadb, mysql or postgres"
echo " database: is one of mariadb, mysql, mssql or postgres"
echo " broker: is on of kafka or rabbitmq"
echo " compose-command: One of up,down,rm,kill,stop,start,run,restart,pull,pause,create,build. Default is up."
echo " options: one or more of ssl, zipkin, prometheus, influxdb, wavefront, ssl, dood, debug-dataflow, debug-skipper"
Expand All @@ -34,6 +34,9 @@ while [ "$1" != "" ]; do
"mysql")
DATABASE=mysql
;;
"mssql")
DATABASE=mssql
;;
"maria" | "mariadb")
DATABASE=mariadb
;;
Expand Down
38 changes: 38 additions & 0 deletions src/docker-compose/docker-compose-mssql.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
version: '3'

# Reconfigures the default docker-compose.yml to replace MariaDB by Postgres
# Usage: docker-compose -f ./docker-compose.yml -f ./docker-compose-postgres.yml up
services:

mssql:
image: mcr.microsoft.com/mssql/server:2019-latest
container_name: dataflow-mssql
restart: always
privileged: true
environment:
LANG: en_US.utf8
LC_ALL: en_US.utf8
JDK_JAVA_OPTIONS: '-Dfile.encoding=UTF-8 -Dsun.jnu.encoding=UTF-8'
MSSQL_SA_PASSWORD: 'MSSqlServer_RootPassword1'
ACCEPT_EULA: 'Y'
expose:
- 1443
ports:
- '1443:1443'

dataflow-server:
environment:
- SPRING_DATASOURCE_URL=jdbc:sqlserver://mssql;encrypt=true;trustServerCertificate=true
- SPRING_DATASOURCE_USERNAME=sa
- SPRING_DATASOURCE_PASSWORD=MSSqlServer_RootPassword1
- SPRING_DATASOURCE_DRIVER_CLASS_NAME=com.microsoft.sqlserver.jdbc.SQLServerDriver
depends_on:
- mssql
skipper-server:
environment:
- SPRING_DATASOURCE_URL=jdbc:sqlserver://mssql;encrypt=true;trustServerCertificate=true
- SPRING_DATASOURCE_USERNAME=sa
- SPRING_DATASOURCE_PASSWORD=MSSqlServer_RootPassword1
- SPRING_DATASOURCE_DRIVER_CLASS_NAME=com.microsoft.sqlserver.jdbc.SQLServerDriver
depends_on:
- mssql

0 comments on commit 61791f1

Please sign in to comment.