Skip to content

Commit 66ead19

Browse files
committed
Update SNAPSHOT to 1.0.3.RELEASE
1 parent 04f59cf commit 66ead19

File tree

31 files changed

+108
-39
lines changed

31 files changed

+108
-39
lines changed

README.adoc

Lines changed: 73 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,15 @@ private DiscoveryClient discoveryClient;
112112
----
113113
====
114114

115+
You can choose to enable `DiscoveryClient` from all namespaces by setting the following property in `application.properties`:
116+
117+
====
118+
[source]
119+
----
120+
spring.cloud.kubernetes.discovery.all-namespaces=true
121+
----
122+
====
123+
115124
If, for any reason, you need to disable the `DiscoveryClient`, you can set the following property in `application.properties`:
116125

117126
====
@@ -124,6 +133,8 @@ spring.cloud.kubernetes.discovery.enabled=false
124133
Some Spring Cloud components use the `DiscoveryClient` in order to obtain information about the local service instance. For
125134
this to work, you need to align the Kubernetes service name with the `spring.application.name` property.
126135

136+
NOTE: `spring.application.name` has no effect as far as the name registered for the application within Kubernetes
137+
127138
Spring Cloud Kubernetes can also watch the Kubernetes service catalog for changes and update the
128139
`DiscoveryClient` implementation accordingly. In order to enable this functionality you need to add
129140
`@EnableScheduling` on a configuration class in your application.
@@ -324,6 +335,59 @@ However, if the `production` profile is active, the configuration becomes:
324335

325336
If both profiles are active, the property that appears last within the `ConfigMap` overwrites any preceding values.
326337

338+
Another option is to create a different config map per profile and spring boot will automatically fetch it based
339+
on active profiles
340+
341+
====
342+
[source,yaml]
343+
----
344+
kind: ConfigMap
345+
apiVersion: v1
346+
metadata:
347+
name: demo
348+
data:
349+
application.yml: |-
350+
greeting:
351+
message: Say Hello to the World
352+
farewell:
353+
message: Say Goodbye
354+
----
355+
====
356+
====
357+
[source,yaml]
358+
----
359+
kind: ConfigMap
360+
apiVersion: v1
361+
metadata:
362+
name: demo-development
363+
data:
364+
application.yml: |-
365+
spring:
366+
profiles: development
367+
greeting:
368+
message: Say Hello to the Developers
369+
farewell:
370+
message: Say Goodbye to the Developers
371+
----
372+
====
373+
====
374+
[source,yaml]
375+
----
376+
kind: ConfigMap
377+
apiVersion: v1
378+
metadata:
379+
name: demo-production
380+
data:
381+
application.yml: |-
382+
spring:
383+
profiles: production
384+
greeting:
385+
message: Say Hello to the Ops
386+
farewell:
387+
message: Say Goodbye
388+
----
389+
====
390+
327391

328392
To tell Spring Boot which `profile` should be enabled at bootstrap, you can pass a system property to the Java
329393
command. To do so, you can launch your Spring Boot application with an environment variable that you can define with the OpenShift
@@ -362,7 +426,7 @@ NOTE: You have to provide the full exact path to each property file, because dir
362426
[options="header,footer"]
363427
|===
364428
| Name | Type | Default | Description
365-
| `spring.cloud.kubernetes.config.enabled` | `Boolean` | `true` | Enable Secrets `PropertySource`
429+
| `spring.cloud.kubernetes.config.enabled` | `Boolean` | `true` | Enable ConfigMaps `PropertySource`
366430
| `spring.cloud.kubernetes.config.name` | `String` | `${spring.application.name}` | Sets the name of `ConfigMap` to look up
367431
| `spring.cloud.kubernetes.config.namespace` | `String` | Client namespace | Sets the Kubernetes namespace where to lookup
368432
| `spring.cloud.kubernetes.config.paths` | `List` | `null` | Sets the paths where `ConfigMap` instances are mounted
@@ -381,10 +445,13 @@ When enabled, the `SecretsPropertySource` looks up Kubernetes for `Secrets` from
381445
. Named after the application (as defined by `spring.application.name`)
382446
. Matching some labels
383447

384-
Note that, by default, consuming Secrets through the API (points 2 and 3 above) *is not enabled* for security reasons.
448+
*Note:*
449+
450+
By default, consuming Secrets through the API (points 2 and 3 above) *is not enabled* for security reasons. The permission 'list' on secrets allows clients to inspect secrets values in the specified namespace.
385451
Further, we recommend that containers share secrets through mounted volumes.
386-
If you enable consuming Secrets through the API, we recommend that you limit access to Secrets by using an
387-
[authorization policy, such as RBAC](https://kubernetes.io/docs/concepts/configuration/secret/#best-practices).
452+
453+
If you enable consuming Secrets through the API, we recommend that you limit access to Secrets by using an authorization policy, such as RBAC.
454+
For more information about risks and best practices when consuming Secrets through the API refer to https://kubernetes.io/docs/concepts/configuration/secret/#best-practices[this doc].
388455

389456
If the secrets are found, their data is made available to the application.
390457

@@ -500,6 +567,7 @@ If you have all the secrets mapped to a common root, you can set them like:
500567
|===
501568

502569
Notes:
570+
503571
* The `spring.cloud.kubernetes.secrets.labels` property behaves as defined by
504572
https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-Configuration-Binding#map-based-binding[Map-based binding].
505573
* The `spring.cloud.kubernetes.secrets.paths` property behaves as defined by
@@ -987,6 +1055,7 @@ $ touch .springformat
9871055
==== Intellij IDEA
9881056

9891057
In order to setup Intellij you should import our coding conventions, inspection profiles and set up the checkstyle plugin.
1058+
The following files can be found in the https://github.com/spring-cloud/spring-cloud-build/tree/master/spring-cloud-build-tools[Spring Cloud Build] project.
9901059

9911060
.spring-cloud-build-tools/
9921061
----

docs/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
<parent>
99
<groupId>org.springframework.cloud</groupId>
1010
<artifactId>spring-cloud-kubernetes</artifactId>
11-
<version>1.0.3.BUILD-SNAPSHOT</version>
11+
<version>1.0.3.RELEASE</version>
1212
</parent>
1313
<packaging>pom</packaging>
1414
<name>Spring Cloud Kubernetes Docs</name>

pom.xml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,13 @@
2424
<parent>
2525
<groupId>org.springframework.cloud</groupId>
2626
<artifactId>spring-cloud-build</artifactId>
27-
<version>2.1.7.BUILD-SNAPSHOT</version>
27+
<version>2.1.7.RELEASE</version>
2828
<relativePath/>
2929
</parent>
3030

3131
<groupId>org.springframework.cloud</groupId>
3232
<artifactId>spring-cloud-kubernetes</artifactId>
33-
<version>1.0.3.BUILD-SNAPSHOT</version>
33+
<version>1.0.3.RELEASE</version>
3434
<packaging>pom</packaging>
3535
<name>Spring Cloud Kubernetes</name>
3636

@@ -63,9 +63,9 @@
6363

6464
<properties>
6565
<!-- Dependency Versions -->
66-
<spring-cloud-commons.version>2.1.3.BUILD-SNAPSHOT</spring-cloud-commons.version>
67-
<spring-cloud-netflix.version>2.1.3.BUILD-SNAPSHOT</spring-cloud-netflix.version>
68-
<spring-cloud-config.version>2.1.4.BUILD-SNAPSHOT</spring-cloud-config.version>
66+
<spring-cloud-commons.version>2.1.3.RELEASE</spring-cloud-commons.version>
67+
<spring-cloud-netflix.version>2.1.3.RELEASE</spring-cloud-netflix.version>
68+
<spring-cloud-config.version>2.1.4.RELEASE</spring-cloud-config.version>
6969

7070
<!-- Maven Plugin Versions -->
7171
<maven-compiler-plugin.version>3.5</maven-compiler-plugin.version>

spring-cloud-kubernetes-config/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>spring-cloud-kubernetes</artifactId>
77
<groupId>org.springframework.cloud</groupId>
8-
<version>1.0.3.BUILD-SNAPSHOT</version>
8+
<version>1.0.3.RELEASE</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

spring-cloud-kubernetes-core/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<parent>
2323
<groupId>org.springframework.cloud</groupId>
2424
<artifactId>spring-cloud-kubernetes</artifactId>
25-
<version>1.0.3.BUILD-SNAPSHOT</version>
25+
<version>1.0.3.RELEASE</version>
2626
</parent>
2727
<modelVersion>4.0.0</modelVersion>
2828

spring-cloud-kubernetes-dependencies/pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@
2323
<parent>
2424
<artifactId>spring-cloud-dependencies-parent</artifactId>
2525
<groupId>org.springframework.cloud</groupId>
26-
<version>2.1.7.BUILD-SNAPSHOT</version>
26+
<version>2.1.7.RELEASE</version>
2727
<relativePath/>
2828
</parent>
2929
<artifactId>spring-cloud-kubernetes-dependencies</artifactId>
30-
<version>1.0.3.BUILD-SNAPSHOT</version>
30+
<version>1.0.3.RELEASE</version>
3131
<packaging>pom</packaging>
3232
<name>Spring Cloud Kubernetes :: Dependencies</name>
3333
<description>Spring Cloud Kubernetes Dependencies</description>

spring-cloud-kubernetes-discovery/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<parent>
2323
<groupId>org.springframework.cloud</groupId>
2424
<artifactId>spring-cloud-kubernetes</artifactId>
25-
<version>1.0.3.BUILD-SNAPSHOT</version>
25+
<version>1.0.3.RELEASE</version>
2626
</parent>
2727
<modelVersion>4.0.0</modelVersion>
2828

spring-cloud-kubernetes-examples/kubernetes-circuitbreaker-ribbon-example/greeting-service/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
<parent>
2424
<groupId>org.springframework.cloud</groupId>
2525
<artifactId>kubernetes-circuitbreaker-ribbon-example</artifactId>
26-
<version>1.0.3.BUILD-SNAPSHOT</version>
26+
<version>1.0.3.RELEASE</version>
2727
</parent>
2828

2929
<artifactId>greeting-service</artifactId>

spring-cloud-kubernetes-examples/kubernetes-circuitbreaker-ribbon-example/name-service/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
<parent>
2424
<groupId>org.springframework.cloud</groupId>
2525
<artifactId>kubernetes-circuitbreaker-ribbon-example</artifactId>
26-
<version>1.0.3.BUILD-SNAPSHOT</version>
26+
<version>1.0.3.RELEASE</version>
2727
</parent>
2828

2929
<artifactId>name-service</artifactId>

spring-cloud-kubernetes-examples/kubernetes-circuitbreaker-ribbon-example/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
<parent>
2424
<artifactId>spring-cloud-kubernetes-examples</artifactId>
2525
<groupId>org.springframework.cloud</groupId>
26-
<version>1.0.3.BUILD-SNAPSHOT</version>
26+
<version>1.0.3.RELEASE</version>
2727
</parent>
2828

2929
<groupId>org.springframework.cloud</groupId>

spring-cloud-kubernetes-examples/kubernetes-hello-world-example/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>spring-cloud-kubernetes-examples</artifactId>
77
<groupId>org.springframework.cloud</groupId>
8-
<version>1.0.3.BUILD-SNAPSHOT</version>
8+
<version>1.0.3.RELEASE</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

spring-cloud-kubernetes-examples/kubernetes-leader-election-example/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<parent>
77
<groupId>org.springframework.cloud</groupId>
88
<artifactId>spring-cloud-kubernetes-examples</artifactId>
9-
<version>1.0.3.BUILD-SNAPSHOT</version>
9+
<version>1.0.3.RELEASE</version>
1010
</parent>
1111

1212
<artifactId>kubernetes-leader-election-example</artifactId>

spring-cloud-kubernetes-examples/kubernetes-reload-example/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<parent>
2323
<artifactId>spring-cloud-kubernetes-examples</artifactId>
2424
<groupId>org.springframework.cloud</groupId>
25-
<version>1.0.3.BUILD-SNAPSHOT</version>
25+
<version>1.0.3.RELEASE</version>
2626
</parent>
2727
<modelVersion>4.0.0</modelVersion>
2828

spring-cloud-kubernetes-examples/kubernetes-zipkin-example/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<parent>
2323
<artifactId>spring-cloud-kubernetes-examples</artifactId>
2424
<groupId>org.springframework.cloud</groupId>
25-
<version>1.0.3.BUILD-SNAPSHOT</version>
25+
<version>1.0.3.RELEASE</version>
2626
</parent>
2727
<modelVersion>4.0.0</modelVersion>
2828

spring-cloud-kubernetes-examples/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
<parent>
2424
<artifactId>spring-cloud-kubernetes</artifactId>
2525
<groupId>org.springframework.cloud</groupId>
26-
<version>1.0.3.BUILD-SNAPSHOT</version>
26+
<version>1.0.3.RELEASE</version>
2727
</parent>
2828

2929
<artifactId>spring-cloud-kubernetes-examples</artifactId>

spring-cloud-kubernetes-integration-tests/discovery/discovery-client/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<parent>
88
<groupId>org.springframework.cloud</groupId>
99
<artifactId>discovery-parent</artifactId>
10-
<version>1.0.3.BUILD-SNAPSHOT</version>
10+
<version>1.0.3.RELEASE</version>
1111
</parent>
1212

1313
<artifactId>discovery-client</artifactId>

spring-cloud-kubernetes-integration-tests/discovery/discovery-service-a/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<parent>
88
<groupId>org.springframework.cloud</groupId>
99
<artifactId>discovery-parent</artifactId>
10-
<version>1.0.3.BUILD-SNAPSHOT</version>
10+
<version>1.0.3.RELEASE</version>
1111
</parent>
1212

1313
<artifactId>discovery-service-a</artifactId>

spring-cloud-kubernetes-integration-tests/discovery/discovery-service-b/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<parent>
88
<groupId>org.springframework.cloud</groupId>
99
<artifactId>discovery-parent</artifactId>
10-
<version>1.0.3.BUILD-SNAPSHOT</version>
10+
<version>1.0.3.RELEASE</version>
1111
</parent>
1212

1313
<artifactId>discovery-service-b</artifactId>

spring-cloud-kubernetes-integration-tests/discovery/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<parent>
88
<groupId>org.springframework.cloud</groupId>
99
<artifactId>spring-cloud-kubernetes-integration-tests</artifactId>
10-
<version>1.0.3.BUILD-SNAPSHOT</version>
10+
<version>1.0.3.RELEASE</version>
1111
</parent>
1212

1313
<name>Spring Cloud Kubernetes :: Integration Tests :: Discovery Parent</name>

spring-cloud-kubernetes-integration-tests/discovery/tests/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<parent>
88
<groupId>org.springframework.cloud</groupId>
99
<artifactId>discovery-parent</artifactId>
10-
<version>1.0.3.BUILD-SNAPSHOT</version>
10+
<version>1.0.3.RELEASE</version>
1111
</parent>
1212

1313
<artifactId>tests</artifactId>

spring-cloud-kubernetes-integration-tests/istio/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<parent>
88
<groupId>org.springframework.cloud</groupId>
99
<artifactId>spring-cloud-kubernetes-integration-tests</artifactId>
10-
<version>1.0.3.BUILD-SNAPSHOT</version>
10+
<version>1.0.3.RELEASE</version>
1111
</parent>
1212

1313
<name>Spring Cloud Kubernetes :: Integration Tests :: Istio</name>

spring-cloud-kubernetes-integration-tests/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<parent>
77
<groupId>org.springframework.cloud</groupId>
88
<artifactId>spring-cloud-kubernetes</artifactId>
9-
<version>1.0.3.BUILD-SNAPSHOT</version>
9+
<version>1.0.3.RELEASE</version>
1010
</parent>
1111

1212
<artifactId>spring-cloud-kubernetes-integration-tests</artifactId>

spring-cloud-kubernetes-integration-tests/simple-configmap/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<parent>
88
<groupId>org.springframework.cloud</groupId>
99
<artifactId>spring-cloud-kubernetes-integration-tests</artifactId>
10-
<version>1.0.3.BUILD-SNAPSHOT</version>
10+
<version>1.0.3.RELEASE</version>
1111
</parent>
1212

1313
<name>Spring Cloud Kubernetes :: Integration Tests :: Simple Configmap</name>

spring-cloud-kubernetes-integration-tests/simple-core/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<parent>
88
<groupId>org.springframework.cloud</groupId>
99
<artifactId>spring-cloud-kubernetes-integration-tests</artifactId>
10-
<version>1.0.3.BUILD-SNAPSHOT</version>
10+
<version>1.0.3.RELEASE</version>
1111
</parent>
1212

1313
<name>Spring Cloud Kubernetes :: Integration Tests :: Simple Core</name>

spring-cloud-kubernetes-istio/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>spring-cloud-kubernetes</artifactId>
77
<groupId>org.springframework.cloud</groupId>
8-
<version>1.0.3.BUILD-SNAPSHOT</version>
8+
<version>1.0.3.RELEASE</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

spring-cloud-kubernetes-leader/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<parent>
2323
<groupId>org.springframework.cloud</groupId>
2424
<artifactId>spring-cloud-kubernetes</artifactId>
25-
<version>1.0.3.BUILD-SNAPSHOT</version>
25+
<version>1.0.3.RELEASE</version>
2626
</parent>
2727

2828
<artifactId>spring-cloud-kubernetes-leader</artifactId>

spring-cloud-kubernetes-ribbon/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<parent>
2323
<artifactId>spring-cloud-kubernetes</artifactId>
2424
<groupId>org.springframework.cloud</groupId>
25-
<version>1.0.3.BUILD-SNAPSHOT</version>
25+
<version>1.0.3.RELEASE</version>
2626
</parent>
2727
<modelVersion>4.0.0</modelVersion>
2828

spring-cloud-starter-kubernetes-all/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<parent>
2323
<artifactId>spring-cloud-kubernetes</artifactId>
2424
<groupId>org.springframework.cloud</groupId>
25-
<version>1.0.3.BUILD-SNAPSHOT</version>
25+
<version>1.0.3.RELEASE</version>
2626
</parent>
2727
<modelVersion>4.0.0</modelVersion>
2828

0 commit comments

Comments
 (0)