A
u
Belaid Youba Hadj Arab, Etienne Deneuve
Aug 20, 2023 · 2 min read

Kibana Backup System with Cronjob (Prerequisites)

Side view worker wearing gloves

Prerequisites

  1. AN AKS
  2. Elasticsearch & Kibana
  3. Azure CLI
  4. An Azure Storage Account
  5. An Azure Container Registry
  6. Docker

Note that I assume you already have an AKS with Elasticsearch and Kibana deployed on it.

Alternatively, you can wait for my next article, which will demonstrate how to deploy an AKS.

Storage Account

  1. Log in to Azure using the command :

Terminal window
az login
  1. Create the resource group :

Terminal window
az group create \
--name <resource-group-name> \
--location <resource-group-region>
  1. Next, create the storage account, which will contain our future backups:

Terminal window
az storage account create \
--name <account-name> \
--resource-group <resource-group-name> \
--location <resource-group-region> \
--sku Standard_RAGRS \
--kind StorageV2
  1. If you prefer creating the storage account via the portal, check here

Azure Container Registry(acr)

  1. Create the resource group :

Terminal window
az group create \
--name <acr-resource-group-name> \
--location <resource-group-region>
  1. Then create the ACR, which will contain the Docker image used by the cronjob: :

Terminal window
az acr create --resource-group <acr-resource-group-name> \
--name <acr-name> --sku Basic
  1. Finally, log in to it :

Terminal window
az acr login --name <acr-name>
  1. For doing this via the portal, refer here.

Image build

  1. Download the repository content in zip format.

  2. Unzip the file and navigate to the root of the folder.

  3. Run the following command to build the Docker image :

Terminal window
docker build --platform linux/amd64 -t <acr-name>.azurecr.io/<image-name>:<version> --push .
  1. You can check the portal to verify if the image has been successfully pushed.
  • Now, we have our image created and our storage account; all that’s left is to put everything together to create the cronjob !
Backup Kibana Tutorial

Related articles