From 7dadabf52b2be5208b960390c44065eca56b9dc7 Mon Sep 17 00:00:00 2001 From: Juan Antonio Osorio Robles Date: Tue, 24 Oct 2017 15:24:24 +0300 Subject: [PATCH] Add rsyslog image This adds a basic rsyslog image with TLS support. For CentOS, we need to specify the addition of the log normalizer and json parsing modules; this is not necessary for debian based systems as they're part of the base rsyslog package. Change-Id: Ic40cbdaa182fa664c2329e0336259566307165d4 --- docker/rsyslog/Dockerfile.j2 | 25 +++++++++++++++++++ kolla/common/config.py | 1 + .../notes/rsyslog-13d5798163953322.yaml | 4 +++ 3 files changed, 30 insertions(+) create mode 100644 docker/rsyslog/Dockerfile.j2 create mode 100644 releasenotes/notes/rsyslog-13d5798163953322.yaml diff --git a/docker/rsyslog/Dockerfile.j2 b/docker/rsyslog/Dockerfile.j2 new file mode 100644 index 0000000000..60d489b1e3 --- /dev/null +++ b/docker/rsyslog/Dockerfile.j2 @@ -0,0 +1,25 @@ +FROM {{ namespace }}/{{ image_prefix }}base:{{ tag }} +LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build_date }}" + +{% block rsyslog_header %}{% endblock %} + +{% import "macros.j2" as macros with context %} + +{% if base_distro in ['centos', 'oraclelinux', 'rhel'] %} + {% set rsyslog_packages = [ + 'rsyslog', + 'rsyslog-gnutls', + 'rsyslog-mmjsonparse', + 'rsyslog-mmnormalize', + ] %} +{% elif base_distro in ['debian', 'ubuntu'] %} + {% set rsyslog_packages = [ + 'rsyslog', + 'rsyslog-gnutls', + ] %} +{% endif %} + +{{ macros.install_packages(rsyslog_packages | customizable("packages")) }} + +{% block rsyslog_footer %}{% endblock %} +{% block footer %}{% endblock %} diff --git a/kolla/common/config.py b/kolla/common/config.py index e12a7ad08b..3b650ca1ce 100755 --- a/kolla/common/config.py +++ b/kolla/common/config.py @@ -74,6 +74,7 @@ _PROFILE_OPTS = [ 'qdrouterd', 'rabbitmq', 'redis', + 'rsyslog', 'skydive', 'tgtd', ], diff --git a/releasenotes/notes/rsyslog-13d5798163953322.yaml b/releasenotes/notes/rsyslog-13d5798163953322.yaml new file mode 100644 index 0000000000..48128ada79 --- /dev/null +++ b/releasenotes/notes/rsyslog-13d5798163953322.yaml @@ -0,0 +1,4 @@ +--- +features: + - | + Add Rsyslog image.