From 78ecfede06ed7630f9847b850180936771e9f846 Mon Sep 17 00:00:00 2001 From: Zakhar Bessarab Date: Wed, 4 Sep 2024 17:23:23 +0400 Subject: [PATCH] license: add ability to reload keys (#775) * lib/license: add support of license key hot-reload * docs: add info about license key hot reload --------- Signed-off-by: Zakhar Bessarab --- docs/enterprise.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/enterprise.md b/docs/enterprise.md index 43490e1f8..dc2911b32 100644 --- a/docs/enterprise.md +++ b/docs/enterprise.md @@ -92,6 +92,7 @@ All the VictoriaMetrics Enterprise components require specifying the following c * `-license` - this flag accepts VictoriaMetrics Enterprise license key, which can be obtained at [this page](https://victoriametrics.com/products/enterprise/trial/) * `-licenseFile` - this flag accepts a path to file with VictoriaMetrics Enterprise license key, which can be obtained at [this page](https://victoriametrics.com/products/enterprise/trial/) . Use either `-license` or `-licenseFile`, but not both. +* `-licenseFile.reloadInterval` - specifies the interval for checking the license file for updates. The default value is 1 hour. If the license file is updated, the new license key is read from the file. * `-license.forceOffline` - enables offline verification of VictoriaMetrics Enterprise license key. Contact us via [this page](https://victoriametrics.com/products/enterprise/) if you need license key, which can be verified offline without the need to connect to VictoriaMetrics license server. @@ -208,6 +209,8 @@ Or create secret via `kubectl`: kubectl create secret generic vm-license --from-literal=license={BASE64_ENCODED_LICENSE_KEY} ``` +Note that license key provided by using secret is mounted in a file. This allows to perform updates of the license without the need to restart the pod. + ### Kubernetes operator It is allowed to run VictoriaMetrics Enterprise components in [cases listed here](#valid-cases-for-victoriametrics-enterprise). @@ -267,6 +270,7 @@ Or create secret via `kubectl`: kubectl create secret generic vm-license --from-literal=license={BASE64_ENCODED_LICENSE_KEY} ``` +Note that license key provided by using secret is mounted in a file. This allows to perform updates of the license without the need to restart the pod. See full list of CRD specifications [here](https://docs.victoriametrics.com/operator/api.html). ## Monitoring license expiration