You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on May 25, 2023. It is now read-only.
Copy file name to clipboardExpand all lines: src/main/paradox/features/secrets.md
+3-10Lines changed: 3 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,6 @@
1
1
## Secrets
2
2
3
-
A non-blocking secrets API is available for Kubernetes. The secrets must be declared in the `build.sbt` file, and then they can be accessed at runtime using the provided libraries. This feature will be made available for DC/OS at a later date.
4
-
3
+
A non-blocking secrets API is available for Kubernetes. The secrets must be declared in the `build.sbt` file, and then they can be accessed at runtime using the provided libraries.
5
4
#### Project
6
5
7
6
For example, given the following `build.sbt` setting:
@@ -10,14 +9,8 @@ For example, given the following `build.sbt` setting:
| deployMinikubeReactiveSandboxExternalServices<br/><br/> `Map[String, String]` | A map of service names to service lookup addresses. This will be provided as an argument to rp for resources that are generated when running deploy minikube. Note that this map will only be added if reactive sandbox is enabled.
67
-
| deployMinikubeAdditionalExternalServices <br/><br/> `Map[String, String]` | An additional map of service names to service lookup addresses. These will always be provided to rp and take precedence over the Reactive Sandbox addresses.
68
-
| deployMinikubeAkkaClusterBootstrapContactPoints <br/><br/> `Int` | When deploying applications with Akka Cluster Bootstrap enabled, the services will initially be started with this many contact points / replicas. Defaults to 1
69
-
| deployMinikubeEnableReactiveSandbox <br/><br/> `Boolean` | If enabled, Reactive Sandbox (a Docker image containing Cassandra, Kafka, ZooKeeper, Elasticsearch) will be deployed with this app.
70
-
| deployMinikubePlayHostAllowedProperty <br/><br/> `String` | If deploying a Play application, this property will be set to the Minikube IP.
71
-
| deployMinikubePlayHttpSecretKeyProperty <br/><br/> `String` | If deploying a Play application, this property will be set to the value specified below.
72
-
| deployMinikubePlayHttpSecretKeyValue <br/><br/> `String` | If deploying a Play application, this property will be set to the value specified above.
73
-
| deployMinikubeReactiveSandboxCqlStatements <br/><br/> `Seq[String]` | Set this setting (build-wide, i.e. `deployMinikubeReactiveSandboxCqlStatements in ThisBuild` := ...) to a sequence of CQL statements that should be executed against Cassandra when the Reactive Sandbox is installed.
74
-
| deployMinikubeRpArguments <br/><br/> `Seq[String]` | Additional arguments to invoke rp with for this app.
66
+
| rpDeployMinikubeReactiveSandboxExternalServices<br/><br/> `Map[String, String]` | A map of service names to service lookup addresses. This will be provided as an argument to rp for resources that are generated when running deploy minikube. Note that this map will only be added if reactive sandbox is enabled.
67
+
| rpDeployMinikubeAdditionalExternalServices <br/><br/> `Map[String, String]` | An additional map of service names to service lookup addresses. These will always be provided to rp and take precedence over the Reactive Sandbox addresses.
68
+
| rpDeployMinikubeAkkaClusterBootstrapContactPoints <br/><br/> `Int` | When deploying applications with Akka Cluster Bootstrap enabled, the services will initially be started with this many contact points / replicas. Defaults to 1
69
+
| rpDeployMinikubeEnableReactiveSandbox <br/><br/> `Boolean` | If enabled, Reactive Sandbox (a Docker image containing Cassandra, Kafka, ZooKeeper, Elasticsearch) will be deployed with this app.
70
+
| rpDeployMinikubePlayHostAllowedProperty <br/><br/> `String` | If deploying a Play application, this property will be set to the Minikube IP.
71
+
| rpDeployMinikubePlayHttpSecretKeyProperty <br/><br/> `String` | If deploying a Play application, this property will be set to the value specified below.
72
+
| rpDeployMinikubePlayHttpSecretKeyValue <br/><br/> `String` | If deploying a Play application, this property will be set to the value specified above.
73
+
| rpDeployMinikubeReactiveSandboxCqlStatements <br/><br/> `Seq[String]` | Set this setting (build-wide, i.e. `deployMinikubeReactiveSandboxCqlStatements in ThisBuild` := ...) to a sequence of CQL statements that should be executed against Cassandra when the Reactive Sandbox is installed.
74
+
| rpDeployMinikubeRpArguments <br/><br/> `Seq[String]` | Additional arguments to invoke rp with for this app.
In general, the theme of Lightbend Orchestration 1.7.0 is to remove unnecessary features to make the deployment leaner and more manageable. 1.7.0 runtime is based on Akka 2.5.20 and Akka Management 0.20.0. The following illustrations show the pieces included in Orchestration’s build and runtime.
20
+
21
+
### Secure Docker image building with sbt-native-packager 1.3.17
22
+
23
+
For building Docker images, Lightbend Orchestration depends on sbt-native-packager, an sbt plugin maintained by Nepomuk "Muki" Seiler. To improve the security around file permissions and Red Hat OpenShift compatibility, Lightbend Tooling team has contributed a few enhancements to sbt-native-packager.
24
+
25
+
First, `dockerPermissionStrategy` was added to decide how file permissions are set for the working directory inside the Docker image. The default `DockerPermissionStrategy.MultiStage` strategy uses multi-stage Docker build to call chmod ahead of time. This avoids extra Docker layer overhead.
26
+
27
+
Next, `dockerChmodType` setting was added to specify what file permissions are set for the working directory. By default, it uses `DockerChmodType.UserGroupReadExecute`, which prevents the working directory to be writable. If you want your application to write a file, the following setting can be used to opt-in:
See [sbt-native-packager 1.3.16](https://github.com/sbt/sbt-native-packager/releases/tag/v1.3.16) release note for more details.
35
+
36
+
### YAML file generation for Akka Cluster Bootstrapping using Kubernetes API
37
+
38
+
The main feature of Lightbend Orchestration is the automatic generation of Kubernetes configuration (YAML) files.
39
+
40
+
For Akka Cluster Bootstrapping, Lightbend Orchestration generates YAML files using Kubernetes API as the discovery method. Starting with Lightbend Orchestration 1.7.0, we will use a specialized label `akka.lightbend.com/service-name`, which denotes the Akka Cluster to join when a pod comes up.
41
+
42
+
- The value of the this label will default to either the app name or the app name + version depending on the deployment type.
43
+
- Deployment pods are labeled with `"akka.lightbend.com/service-name": "friendimpl"` etc.
44
+
- You can override the label selector as follows: `-Dakka.discovery.kubernetes-api.pod-label-selector=akka.lightbend.com/service-name=%s` (as opposed to using `app=%s`).
45
+
- You can override the effective name as follows: `-Dakka.management.cluster.bootstrap.contact-point-discovery.effective-name=friendimpl` etc.
46
+
47
+
### YAML file generation: Removal of automatic port assignment
48
+
49
+
Previous releases of Lightbend Orchestration automatically assigned various port numbers from port 10000 in part by overriding your `application.config` file. Lightbend Orchestration 1.7.0 removes this feature, and respects the port number declared in your your `application.config`. Otherwise, default port numbers will be used such as port 9000 for Play. This also allows us to remove `RP_ENDPOINT_*` environment variables, generally simplifying the generated YAML file.
50
+
51
+
**Note**: This also means that your deployed service will expose different port number (for example 9000) instead of 10000.
52
+
53
+
### YAML file generation for Akka Cluster Bootstrapping using DNS
54
+
55
+
Optionally, Lightbend Orchestration 1.7.0 adds **experimental** support to generate Kubernetes configuration for Akka Cluster Bootstrapping using DNS as the discovery method.
56
+
57
+
If you want to use DNS, pass `--discovery-method=akka-dns` to the `rp` command line. [cli#195][cli195]
58
+
59
+
### Rename of sbt-reactive-app key names
60
+
61
+
All key names are renamed to prefix with `rp` and camel cased to comply with [Plugins Best Practices][best-practice]. For instance, `endpoints` setting will now be `rpEndpoints`, and `deploy` task will be `rpDeploy`. The old key names are deprecated and will be removed in the future. [sbt-reactive-app#145][sbt-reactive-app145]
62
+
63
+
### Deprecation of SecretReader
64
+
65
+
In the effort to reduce runtime dependencies, SecretReader was deprecated. Read from the file `/rp/secrets/%name%/%key%` where `%name%` is transformed to lowercase, and `-` for non-alphanum instead. [lib#118][lib118]
66
+
67
+
### Other bug fix
68
+
69
+
- Fixes missing `protocol` when UDP endpoint is selected. [cli#196][cli196]
- Fixes binary compatibility issue with sbt-native-packager 1.3.15 adopted by Play 2.6.20+ and Lagom 1.4.10. [#169][sbt-reactive-app169] by [@ignasi35][@ignasi35]
| appName <br/><br/> `String` |Specifies the service name. Defaults to the sbt project's name for regular projects. Defaults to the Lagom service name forLagom projects |
86
-
| annotations <br/><br/> `Map[String, String]` |Key/value pairs to exportasannotations. |
87
-
| enableAkkaClusterBootstrap <br/><br/> `Boolean` |Specifies whether AkkaClusterBootstrapping should be enabled. When enabled, an Akka extension will be enabled that will automatically form your cluster using service discovery. |
88
-
| enableCommon <br/><br/> `Boolean` |Specifies whether basic features like Platform detection should be enabled |
89
-
| enablePlayHttpBinding <br/><br/> `Boolean` |Specifies whether automatic HTTP port binding forPlay&Lagom should be enabled|
90
-
| enableSecrets <br/><br/> `Boolean` |Specifies whether secrets library should be enabled |
91
-
| endpoints <br/><br/> `Seq[Endpoint]` |Declare the endpoints that should be made available for your service |
92
-
| environmentVariables <br/><br/> `Map[String, EnvironmentVariable]` |Declare values that should be bound to environment variables (application runtime). Note that additional environment variables can also be set during deploy time using the `rp` command. |
93
-
| httpIngressHosts <br/><br/> `Seq[String]` |For automatic HTTP ingress declarations, specifies the host used for ingress. |
94
-
| httpIngressPorts <br/><br/> `Seq[Int]` |For automatic HTTP ingress declarations, specifies the port used for ingress. |
95
-
| prependRpConf <br/><br/> `String` |All configuration files on the classpathwiththis name will be prepended to the applications `application.conf`. This is the mechanism used to automatically configure various dependencies. To disable this, set this setting to `None` |
96
-
| startScriptLocation <br/><br/> `String` |A custom start-script is provided and bundles with the application. Change its location withthis setting. |
85
+
| rpAppName <br/><br/> `String` |Specifies the service name. Defaults to the sbt project's name for regular projects. Defaults to the Lagom service name forLagom projects |
86
+
| rpAnnotations <br/><br/> `Map[String, String]` |Key/value pairs to exportasannotations. |
87
+
| rpEnableAkkaClusterBootstrap <br/><br/> `Boolean` |Specifies whether AkkaClusterBootstrapping should be enabled. When enabled, an Akka extension will be enabled that will automatically form your cluster using service discovery. |
88
+
| rpEnableCommon <br/><br/> `Boolean` |Specifies whether basic features like Platform detection should be enabled |
89
+
| rpEnableSecrets <br/><br/> `Boolean` |Specifies whether secrets library should be enabled |
90
+
| rpEndpoints <br/><br/> `Seq[Endpoint]` |Declare the endpoints that should be made available for your service |
91
+
| rpEnvironmentVariables <br/><br/> `Map[String, EnvironmentVariable]` |Declare values that should be bound to environment variables (application runtime). Note that additional environment variables can also be set during deploy time using the `rp` command. |
92
+
| rpHttpIngressHosts <br/><br/> `Seq[String]` |For automatic HTTP ingress declarations, specifies the host used for ingress. |
93
+
| rpHttpIngressPorts <br/><br/> `Seq[Int]` |For automatic HTTP ingress declarations, specifies the port used for ingress. |
0 commit comments