Skip to content

Commit f283c4c

Browse files
authored
Merge pull request quarkusio#36259 from wjglerum/mssql-docker
Upgrade MSSQL Docker image
2 parents 4400c21 + 3c3a059 commit f283c4c

File tree

16 files changed

+32
-33
lines changed

16 files changed

+32
-33
lines changed

build-parent/pom.xml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@
9191
<postgres.image>docker.io/postgres:14</postgres.image>
9292
<mariadb.image>docker.io/mariadb:10.11</mariadb.image>
9393
<db2.image>docker.io/ibmcom/db2:11.5.7.0a</db2.image>
94-
<mssql.image>mcr.microsoft.com/mssql/server:2019-latest</mssql.image>
94+
<mssql.image>mcr.microsoft.com/mssql/server:2022-latest</mssql.image>
9595
<mysql.image>docker.io/mysql:8.0</mysql.image>
9696
<oracle.image>docker.io/gvenzl/oracle-free:23-slim-faststart</oracle.image>
9797
<mongo.image>docker.io/mongo:4.4</mongo.image>
@@ -169,7 +169,7 @@
169169
<!-- Quarkus Analytics -->
170170
<properties-maven-plugin.version>1.1.0</properties-maven-plugin.version>
171171
<quarkus.analytics.disabled>true</quarkus.analytics.disabled>
172-
172+
173173
<!-- Dev UI -->
174174
<vaadin.version>24.1.9</vaadin.version>
175175
<lit.version>2.8.0</lit.version>
@@ -382,7 +382,7 @@
382382
</exclusion>
383383
</exclusions>
384384
</dependency>
385-
385+
386386
<!-- Dev UI -->
387387
<!-- Vaadin Router -->
388388
<dependency>
@@ -1332,9 +1332,8 @@
13321332

13331333
<!-- See
13341334
https://github.com/microsoft/mssql-docker/issues/668 and https://stackoverflow.com/questions/65398641/docker-connect-sql-server-container-non-zero-code-1/66919852#66919852.
1335-
The MS SQL image segfaults on ARM. Azure Edge is not fully compatible, but it is better than not running the tests at all.
1336-
The :latest tag segfaults with the same segfault as MSSQL Server but 1.0.6 seems to behave well -->
1337-
<mssql.image>mcr.microsoft.com/azure-sql-edge:1.0.6</mssql.image>
1335+
The MS SQL image segfaults on ARM. Azure Edge is not fully compatible, but it is better than not running the tests at all. -->
1336+
<mssql.image>mcr.microsoft.com/azure-sql-edge:latest</mssql.image>
13381337
</properties>
13391338
</profile>
13401339
</profiles>

docs/src/main/asciidoc/databases-dev-services.adoc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ An example file is shown below:
5656
.src/main/resources/container-license-acceptance.txt
5757
----
5858
ibmcom/db2:11.5.0.0a
59-
mcr.microsoft.com/mssql/server:2017-CU12
59+
mcr.microsoft.com/mssql/server:2022-latest
6060
----
6161

6262
== Mapping volumes into Dev Services for Database
@@ -65,7 +65,7 @@ Mapping volumes from the Docker host's filesystem to the containers is handy to
6565

6666
[NOTE]
6767
====
68-
Mapping volumes will only work in Dev Services with a container-based database like PostgreSQL.
68+
Mapping volumes will only work in Dev Services with a container-based database like PostgreSQL.
6969
====
7070

7171
Dev Services volumes can be mapped to the filesystem or the classpath:
@@ -81,7 +81,7 @@ quarkus.datasource.devservices.volumes."classpath:./file"=/container/to <2>
8181
<1> The file or folder "/path/from" from the local machine will be accessible at "/container/to" in the container.
8282
<2> When using classpath volumes, the location has to start with "classpath:". The file or folder "./file" from the project's classpath will be accessible at "/container/to" in the container.
8383

84-
IMPORTANT: when using a classpath volume, the container will only be granted read permission. On the other hand, when using a filesystem volume, the container will be granted read and write permission.
84+
IMPORTANT: when using a classpath volume, the container will only be granted read permission. On the other hand, when using a filesystem volume, the container will be granted read and write permission.
8585

8686
=== Example of mapping volumes to persist the database data
8787

@@ -101,7 +101,7 @@ quarkus.datasource.db-kind=mysql
101101
quarkus.datasource.devservices.volumes."/local/test/data"=/var/lib/mysql
102102
----
103103

104-
When starting Dev Services (for example, in tests or in DEV mode), you will see that the folder "/local/test/data" will be created at your file sytem and that will contain all the database data. When rerunning again the same dev services, this data will contain all the data you might have created beforehand.
104+
When starting Dev Services (for example, in tests or in DEV mode), you will see that the folder "/local/test/data" will be created at your file sytem and that will contain all the database data. When rerunning again the same dev services, this data will contain all the data you might have created beforehand.
105105

106106
[IMPORTANT]
107107
====

extensions/reactive-mssql-client/deployment/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@
151151
</ports>
152152
<env>
153153
<ACCEPT_EULA>Y</ACCEPT_EULA>
154-
<SA_PASSWORD>A_Str0ng_Required_Password</SA_PASSWORD>
154+
<SA_PASSWORD>yourStrong(!)Password</SA_PASSWORD>
155155
</env>
156156
<log>
157157
<prefix>MSSQL:</prefix>

extensions/reactive-mssql-client/deployment/src/test/java/io/quarkus/reactive/mssql/client/ChangingCredentialsProvider.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@
88
public class ChangingCredentialsProvider extends ChangingCredentialsProviderBase {
99

1010
public ChangingCredentialsProvider() {
11-
super("sa", "A_Str0ng_Required_Password", "user2", "user2_Has_A_Str0ng_Required_Password");
11+
super("sa", "yourStrong(!)Password", "user2", "yourStrong(!)Password2");
1212
}
1313
}

extensions/reactive-mssql-client/deployment/src/test/java/io/quarkus/reactive/mssql/client/ChangingCredentialsTestResource.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ public class ChangingCredentialsTestResource {
2424
ChangingCredentialsProvider credentialsProvider;
2525

2626
void addUser(@Observes StartupEvent ignored) {
27-
client.query("CREATE LOGIN user2 WITH PASSWORD = 'user2_Has_A_Str0ng_Required_Password'").executeAndAwait();
27+
client.query("CREATE LOGIN user2 WITH PASSWORD = 'yourStrong(!)Password2'").executeAndAwait();
2828
client.query("CREATE USER user2 FOR LOGIN user2").executeAndAwait();
2929
}
3030

extensions/reactive-mssql-client/deployment/src/test/java/io/quarkus/reactive/mssql/client/CustomCredentialsProvider.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ public class CustomCredentialsProvider implements CredentialsProvider {
1818
public Map<String, String> getCredentials(String credentialsProviderName) {
1919
Map<String, String> properties = new HashMap<>();
2020
properties.put(USER_PROPERTY_NAME, "sa");
21-
properties.put(PASSWORD_PROPERTY_NAME, "A_Str0ng_Required_Password");
21+
properties.put(PASSWORD_PROPERTY_NAME, "yourStrong(!)Password");
2222
log.info("credentials provider returning " + properties);
2323
return properties;
2424
}
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
quarkus.datasource.db-kind=mssql
22
quarkus.datasource.username=sa
3-
quarkus.datasource.password=A_Str0ng_Required_Password
3+
quarkus.datasource.password=yourStrong(!)Password
44
quarkus.datasource.reactive.url=${reactive-mssql.url}
55
# this data source is broken, but will be excluded from the health check, so the overall check should pass
66
quarkus.datasource."broken".db-kind=mssql
77
quarkus.datasource."broken".username=BROKEN
8-
quarkus.datasource."broken".password=A_Str0ng_Required_Password
8+
quarkus.datasource."broken".password=yourStrong(!)Password
99
quarkus.datasource."broken".reactive.url=${reactive-mssql.url}
1010
quarkus.datasource."broken".health-exclude=true
11-
quarkus.datasource.health.enabled=true
11+
quarkus.datasource.health.enabled=true
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
quarkus.datasource.db-kind=mssql
22
quarkus.datasource.username=sa
3-
quarkus.datasource.password=A_Str0ng_Required_Password
3+
quarkus.datasource.password=yourStrong(!)Password
44
quarkus.datasource.reactive.url=vertx-reactive:sqlserver://test:12345
55

66
quarkus.datasource."hibernate".db-kind=mssql
77
quarkus.datasource."hibernate".username=sa
8-
quarkus.datasource."hibernate".password=A_Str0ng_Required_Password
8+
quarkus.datasource."hibernate".password=yourStrong(!)Password
99
quarkus.datasource."hibernate".reactive.url=vertx-reactive:sqlserver://test:55555
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
quarkus.datasource.db-kind=mssql
22
quarkus.datasource.username=sa
3-
quarkus.datasource.password=A_Str0ng_Required_Password
3+
quarkus.datasource.password=yourStrong(!)Password
44
quarkus.datasource.reactive.url=${reactive-mssql.url}
55

66
quarkus.datasource."hibernate".db-kind=mssql
77
quarkus.datasource."hibernate".username=sa
8-
quarkus.datasource."hibernate".password=A_Str0ng_Required_Password
9-
quarkus.datasource."hibernate".reactive.url=${reactive-mssql.url}
8+
quarkus.datasource."hibernate".password=yourStrong(!)Password
9+
quarkus.datasource."hibernate".reactive.url=${reactive-mssql.url}

integration-tests/hibernate-reactive-mssql/pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@
187187
</activation>
188188
<properties>
189189
<!-- Careful: SQL Server refuses to work with trivial passwords. -->
190-
<mssqldb.sa-password>ActuallyRequired11Complexity</mssqldb.sa-password>
190+
<mssqldb.sa-password>yourStrong(!)Password</mssqldb.sa-password>
191191
</properties>
192192
<build>
193193
<plugins>
@@ -205,7 +205,7 @@
205205
</ports>
206206
<env>
207207
<ACCEPT_EULA>Y</ACCEPT_EULA>
208-
<SA_PASSWORD>ActuallyRequired11Complexity</SA_PASSWORD>
208+
<SA_PASSWORD>yourStrong(!)Password</SA_PASSWORD>
209209
</env>
210210
<log>
211211
<prefix>MS SQL Server:</prefix>

0 commit comments

Comments
 (0)