diff --git a/Dockerfile b/Dockerfile index aec2fdc..9905963 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ FROM lscr.io/linuxserver/syslog-ng:latest -LABEL version="20240607.1.2" +LABEL version="20240607.1.3" LABEL description="syslog-ng" RUN mkdir -p /config diff --git a/Jenkinsfile b/Jenkinsfile index 19e1f74..2d06d82 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -28,6 +28,15 @@ pipeline { } } + stage('Cleanup...') { + steps { + sh 'docker --context pi502 container stop syslog-ng' + sh 'docker --context pi502 container prune -f' + sh 'docker --context pi502 volume prune -f' + sh 'docker --context pi502 image prune -f' + } + } + stage('Start container') { steps { script { diff --git a/config/syslog-ng.conf b/config/syslog-ng.conf index a0fc6b7..5b87322 100644 --- a/config/syslog-ng.conf +++ b/config/syslog-ng.conf @@ -103,6 +103,17 @@ destination d_unifi_wlan { ); }; +destination d_syslog_ng_es { + elasticsearch-http( + index("syslog-ng") + type("") + user("elastic") + password("forty6and2") + url("http://pi501.in.thelinuxpro.net:9200/_bulk") + persist-name("persist") + ); +}; + log { source(s_network_udp); filter(f_unifi_fw_lan); @@ -170,6 +181,6 @@ log { source(s_local); source(s_network_tcp); source(s_network_udp); - destination(d_local); + destination(d_syslog_ng_es); }; diff --git a/docker-compose.yml b/docker-compose.yml index f836d40..79e5cbf 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -10,12 +10,12 @@ services: syslog-ng: build: dockerfile: Dockerfile - image: docker-registry1.in.thelinuxpro.net:5000/tlp/syslog-ng:240607.1.2 + image: docker-registry1.in.thelinuxpro.net:5000/tlp/syslog-ng:240607.1.3 container_name: syslog-ng environment: - PUID=0 - PGID=0 - - TZ=Etc/UTC + - TZ=America/Indianapolis volumes: - syslog-ng_logs:/var/log ports: