Skip to content

Commit 4e0b3aa

Browse files
Clarify how docker image publishing registry is determined
Closes gh-31820
1 parent a7dfeae commit 4e0b3aa

File tree

5 files changed

+6
-6
lines changed

5 files changed

+6
-6
lines changed

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/asciidoc/packaging-oci-image.adoc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -373,6 +373,9 @@ The generated image can be published to a Docker registry by enabling a `publish
373373
If the Docker registry requires authentication, the credentials can be configured using `docker.publishRegistry` properties.
374374
If the Docker registry does not require authentication, the `docker.publishRegistry` configuration can be omitted.
375375

376+
NOTE: The registry that the image will be published to is determined by the registry part of the image name (`docker.example.com` in these examples).
377+
If `docker.publishRegistry` credentials are configured and include a `url` property, this value is passed to the registry but is not used to determine the publishing registry location.
378+
376379
[source,groovy,indent=0,subs="verbatim,attributes",role="primary"]
377380
.Groovy
378381
----

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/gradle/packaging/boot-build-image-publish.gradle

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,6 @@ tasks.named("bootBuildImage") {
1515
publishRegistry {
1616
username = "user"
1717
password = "secret"
18-
url = "https://docker.example.com/v1/"
19-
2018
}
2119
}
2220
}

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/gradle/packaging/boot-build-image-publish.gradle.kts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,6 @@ tasks.named<BootBuildImage>("bootBuildImage") {
1818
publishRegistry {
1919
username = "user"
2020
password = "secret"
21-
url = "https://docker.example.com/v1/"
22-
2321
}
2422
}
2523
}

spring-boot-project/spring-boot-tools/spring-boot-maven-plugin/src/docs/asciidoc/packaging-oci-image.adoc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -343,6 +343,9 @@ The generated image can be published to a Docker registry by enabling a `publish
343343
If the Docker registry requires authentication, the credentials can be configured using `docker.publishRegistry` parameters.
344344
If the Docker registry does not require authentication, the `docker.publishRegistry` configuration can be omitted.
345345

346+
NOTE: The registry that the image will be published to is determined by the registry part of the image name (`docker.example.com` in these examples).
347+
If `docker.publishRegistry` credentials are configured and include a `url` parameter, this value is passed to the registry but is not used to determine the publishing registry location.
348+
346349
[source,xml,indent=0,subs="verbatim,attributes",tabsize=4]
347350
----
348351
include::../maven/packaging-oci-image/docker-pom.xml[tags=docker]

spring-boot-project/spring-boot-tools/spring-boot-maven-plugin/src/docs/maven/packaging-oci-image/docker-pom.xml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,6 @@
1515
<publishRegistry>
1616
<username>user</username>
1717
<password>secret</password>
18-
<url>https://docker.example.com/v1/</url>
19-
<email>[email protected]</email>
2018
</publishRegistry>
2119
</docker>
2220
</configuration>

0 commit comments

Comments
 (0)