Comparing version 4.1.0 to 4.1.1
@@ -87,3 +87,3 @@ { | ||
}, | ||
"version": "4.1.0" | ||
"version": "4.1.1" | ||
} |
@@ -14,2 +14,3 @@ <a name="lightship"></a> | ||
* [Behaviour](#lightship-behaviour) | ||
* [Local-mode](#lightship-behaviour-local-mode) | ||
* [`/health`](#lightship-behaviour-health) | ||
@@ -38,2 +39,7 @@ * [`/live`](#lightship-behaviour-live) | ||
<a name="lightship-behaviour-local-mode"></a> | ||
### Local-mode | ||
If Lightship detects that it is running in a non-Kubernetes environment (e.g. your local machine) then it starts the HTTP service on any available HTTP port. This is done to avoid port collision when multiple services using Lightship are being developed on the same machine. This behaviour can be changed using `detectKubernetes` and `port` configuration. | ||
<a name="lightship-behaviour-health"></a> | ||
@@ -97,2 +103,3 @@ ### <code>/health</code> | ||
/** | ||
* @property detectKubernetes Run Lightship in local mode when Kubernetes is not detected. Default: true. | ||
* @property port The port on which the Lightship service listens. This port must be different than your main service port, if any. The default port is 9000. | ||
@@ -103,2 +110,3 @@ * @property signals An a array of [signal events]{@link https://nodejs.org/api/process.html#process_signal_events}. Default: [SIGTERM]. | ||
export type LightshipConfigurationType = {| | ||
+detectKubernetes?: boolean, | ||
+port?: number, | ||
@@ -116,2 +124,3 @@ +signals?: $ReadOnlyArray<string>, | ||
type LightshipType = {| | ||
+server: http$Server, | ||
+isServerReady: () => boolean, | ||
@@ -137,6 +146,7 @@ +isServerShuttingDown: () => boolean, | ||
port: 9000 | ||
failureThreshold: 1 | ||
initialDelaySeconds: 5 | ||
periodSeconds: 5 | ||
failureThreshold: 1 | ||
successThreshold: 1 | ||
timeoutSeconds: 5 | ||
livenessProbe: | ||
@@ -146,2 +156,3 @@ httpGet: | ||
port: 9000 | ||
failureThreshold: 3 | ||
initialDelaySeconds: 10 | ||
@@ -151,4 +162,6 @@ # Allow sufficient amount of time (180 seconds = periodSeconds * failureThreshold) | ||
periodSeconds: 30 | ||
failureThreshold: 3 | ||
successThreshold: 1 | ||
# Setting a very low timeout value (e.g. 1 second) can cause false-positive | ||
# checks and service interruption. | ||
timeoutSeconds: 5 | ||
@@ -155,0 +168,0 @@ ``` |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
51067
341