Build Process
To build the Azure reference architecture:
Create a .tfvars
file or modify the providedexample.tfvars
to specify configurations for the environment. Refer to the section Terraform Modules for a full list of configuration values.Configure the environment variable TFVAR_FILE
to the newly created configuration file:shellexport TFVAR_FILE=/path/to/myfile.tfvars
Login with the Azure Command Line: shellaz login
(Optional) Create a backend.tf
definition suitable to your environment. For example, to store state in an Azure blob storage container (created separately):initerraform { backend "azurerm" { resource_group_name = "my-resource-group-name" storage_account_name = "mystorageaccount" container_name = "mycontainer" key = "logscale-terraform.tfstate" } }
Create a main.tf
with the modules necessary to build LogScale in the target environment or leverage a provided quickstart example. By default, this repository links toexamples/full-no-bastion.tf
:shellln -s repository-path/examples/full-no-bastion.tf repository-path/main.tf
Initialize terraform: shellterraform init -upgrade
Build the Azure infrastructure. This instruction assumes the use of the quickstart template examples/full-no-bastion.tf
and targets need to be updated accordingly when using a different example or self-built modules:shellterraform apply -target module.azure-core -target module.azure-keyvault -target module.azure-kubernetes -target module.logscale-storage-account -var-file $TFVAR_FILE
Configure kubectl. The previous command output will show a value for k8s_configuration_command. This value represents a command you can run to configure kubctl
, as shown in the following example:shellaz aks get-credentials --resource-group ${var.name_prefix}-rg --name aks-${var.name_prefix}
Apply custom resource definitions to Kubernetes: shellterraform apply -target module.crds -var-file $TFVAR_FILE
Run the LogScale prerequisites module to prepare the environment for __ls_shortname: shellterraform apply -target module.logscale-prereqs -var-file $TFVAR_FILE
Install Strimzi: shellterraform apply -target module.kafka -var-file $TFVAR_FILE
Install the Humio Operator and __ls_shortname cluster definitions: shellterraform apply -target module.logscale -var-file $TFVAR_FILE
To confirm the procedure was successful, you can monitor the created pods using the following command: shellkubectl get pods -n log
You can check that the pods are all running and there are no errors.
You can also point your web browser at the endpoint for the ingress node, for example:
https://<host>.<azure_region>.cloudapp.azure.com