Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Latest commit

 

History

History
39 lines (30 loc) · 1 KB

File metadata and controls

39 lines (30 loc) · 1 KB

Export of kubernetes audit logs to s3/object storage

image

Prerequisites:

  • ✅ Cluster of Managed K8s.
  • ✅ Terraform
  • ✅ Ask cloud support or your architect for an alpha flag "TRIGGERS_CLOUD_LOGS_ALPHA"

  1. If you doing this from Russia just create the file and fill it out like this to use yandex network mirror:
cat ~/.terraformrc
provider_installation {
  network_mirror {
    url = "https://terraform-network-mirror.storage.yandexcloud.net/"
  }
}
  1. Fill out the fields in the provider.tf file.
  2. Fill out the fields in the terraform.tfvars.example file. (example below)
  3. Run:
terraform init
terraform apply

Example of terraform.tfvars.example file:

folder_id                      = "b1gvnphpkgt8oechmpo02"
cloud_id                       = "b1g3o4minpkuh10pd2rj2"
cluster_name                   = "k8s-for-export"
log_bucket_name                = "k8s-audit-logs-example"