Skip to content

Commit 969f256

Browse files
committed
Set default Docker image for MongoDB Dev Services
1 parent 75dc4d0 commit 969f256

File tree

4 files changed

+7
-4
lines changed

4 files changed

+7
-4
lines changed

docs/src/main/asciidoc/_attributes.adoc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
:amqp-image: ${amqp.image}
2323
:apicurio-registry-image: ${apicurio-registry.image}
2424
:narayana-lra-image: ${narayana-lra.image}
25+
:mongo-image: ${mongo.image}
2526
:jandex-version: ${jandex.version}
2627
:jandex-gradle-plugin-version: ${jandex-gradle-plugin.version}
2728
:kotlin-version: ${kotlin.version}

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,12 @@ You can disable the sharing with `quarkus.mongodb.devservices.shared=false`.
3535
The MongoDB Dev Services supports xref:compose-dev-services.adoc[Compose Dev Services].
3636
It relies on a `compose-devservices.yml`, such as:
3737

38-
[source,yaml]
38+
[source,yaml,subs=attributes+]
3939
----
4040
name: <application name>
4141
services:
4242
mongo:
43-
image: docker.io/mongo:7.0
43+
image: {mongo-image}
4444
ports:
4545
- "27017"
4646
----

docs/src/main/asciidoc/mongodb.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -372,9 +372,9 @@ startup time if the Mongo Client is inactive. Alternatively, Mongo Clients may a
372372
As by default, `MongoClient` is configured to access a local MongoDB database on port 27017 (the default MongoDB port), if you have a local running database on this port, there is nothing more to do before being able to test it!
373373

374374
If you want to use Docker to run a MongoDB database, you can use the following command to launch one:
375-
[source,bash]
375+
[source,bash,subs=attributes+]
376376
----
377-
docker run -ti --rm -p 27017:27017 mongo:4.4
377+
docker run -ti --rm -p 27017:27017 {mongo-image}
378378
----
379379

380380
[NOTE]

extensions/mongodb-client/deployment/src/main/java/io/quarkus/mongodb/deployment/DevServicesBuildTimeConfig.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
import java.util.Map;
44
import java.util.Optional;
55

6+
import io.quarkus.runtime.annotations.ConfigDocDefault;
67
import io.quarkus.runtime.annotations.ConfigDocMapKey;
78
import io.quarkus.runtime.annotations.ConfigGroup;
89
import io.smallrye.config.WithDefault;
@@ -22,6 +23,7 @@ public interface DevServicesBuildTimeConfig {
2223
/**
2324
* The container image name to use, for container based DevServices providers.
2425
*/
26+
@ConfigDocDefault(value = "`{mongo-image}`", escape = false)
2527
Optional<String> imageName();
2628

2729
/**

0 commit comments

Comments
 (0)