PostgreSQL container with Filebeat sidecar for log shipping to Elasticsearch. The PostgreSQL logs from var/log/postgresql will be saved in in a persistent volume called pg-log. The Filebeat sidecar container mount the pg-log persistent volume into his filesystem on var/log/postgresql.
In the filebeat.yml (configuration file of filebeat) an input.type = log is defined, which points to the var/log/postgresql directory on the filebeat container. This log files from the directory will be shipped to an elasticsearch container on port 9200.
kubectlinstalled- access to the K8s cluster
- running
elasticsearchon port9200and for data visualization runningkibanawith access toelasticsearch
- execute the
create-deployment.shfile
./create-deployment.sh- execute the
remove-deployment.shfile
./remove-deployment.sh- Yannic Nevado - Initial work - Github