From b9d7d6f31bef4e42ce314a135bbbd3feb8b7027d Mon Sep 17 00:00:00 2001 From: Edward Evans Date: Fri, 15 May 2020 15:07:33 +1000 Subject: [PATCH] Inlcude BESU_ENV_OPTS only when we have a valid setting Signed-off-by: Edward Evans --- templates/besu.service.j2 | 2 ++ 1 file changed, 2 insertions(+) diff --git a/templates/besu.service.j2 b/templates/besu.service.j2 index 9dd5d23..af91627 100644 --- a/templates/besu.service.j2 +++ b/templates/besu.service.j2 @@ -9,7 +9,9 @@ Environment=HOME=/home/{{ besu_user }} {% if besu_log4j_config_file %} Environment=LOG4J_CONFIGURATION_FILE={{ besu_log4j_config_file }} {% endif %} +{% if besu_env_opts|bool %} Environment='BESU_OPTS={{ besu_env_opts|besu_opts_format }}' +{% endif %} Type=simple {% if besu_cmdline_args %} ExecStart=/bin/sh -c "{{ besu_current_dir }}/bin/besu --config-file={{ besu_config_dir }}/config.toml {{ besu_cmdline_args|quote }} >> {{besu_log_dir}}/besu.log 2>&1"