diff --git a/src/journal-remote/journal-remote.conf.in b/src/journal-remote/journal-remote.conf.in index 4c1b78ebc1..648aa1ba11 100644 --- a/src/journal-remote/journal-remote.conf.in +++ b/src/journal-remote/journal-remote.conf.in @@ -15,6 +15,6 @@ [Remote] # Seal=false # SplitMode=host -# ServerKeyFile=@CERTIFICATEROOT@/private/journal-remote.pem -# ServerCertificateFile=@CERTIFICATEROOT@/certs/journal-remote.pem -# TrustedCertificateFile=@CERTIFICATEROOT@/ca/trusted.pem +# ServerKeyFile={{CERTIFICATE_ROOT}}/private/journal-remote.pem +# ServerCertificateFile={{CERTIFICATE_ROOT}}/certs/journal-remote.pem +# TrustedCertificateFile={{CERTIFICATE_ROOT}}/ca/trusted.pem diff --git a/src/journal-remote/journal-upload.conf.in b/src/journal-remote/journal-upload.conf.in index 29b623bdfa..94471e4a00 100644 --- a/src/journal-remote/journal-upload.conf.in +++ b/src/journal-remote/journal-upload.conf.in @@ -14,6 +14,6 @@ [Upload] # URL= -# ServerKeyFile=@CERTIFICATEROOT@/private/journal-upload.pem -# ServerCertificateFile=@CERTIFICATEROOT@/certs/journal-upload.pem -# TrustedCertificateFile=@CERTIFICATEROOT@/ca/trusted.pem +# ServerKeyFile={{CERTIFICATE_ROOT}}/private/journal-upload.pem +# ServerCertificateFile={{CERTIFICATE_ROOT}}/certs/journal-upload.pem +# TrustedCertificateFile={{CERTIFICATE_ROOT}}/ca/trusted.pem diff --git a/src/journal-remote/meson.build b/src/journal-remote/meson.build index c42d85bc4b..d516fbabf7 100644 --- a/src/journal-remote/meson.build +++ b/src/journal-remote/meson.build @@ -42,27 +42,25 @@ systemd_journal_gatewayd_sources = files(''' microhttpd-util.c '''.split()) -if conf.get('ENABLE_REMOTE') ==1 and conf.get('HAVE_LIBCURL') == 1 - journal_upload_conf = configure_file( - input : 'journal-upload.conf.in', - output : 'journal-upload.conf', - configuration : substs) - if install_sysconfdir - install_data(journal_upload_conf, - install_dir : pkgsysconfdir) - endif -endif +in_files = [ + ['journal-upload.conf', + conf.get('ENABLE_REMOTE') == 1 and conf.get('HAVE_LIBCURL') == 1 and install_sysconfdir_samples], + ['journal-remote.conf', + conf.get('ENABLE_REMOTE') == 1 and conf.get('HAVE_MICROHTTPD') == 1 and install_sysconfdir_samples]] + +foreach tuple : in_files + file = tuple[0] + custom_target( + file, + input : file + '.in', + output: file, + command : [meson_render_jinja2, config_h, '@INPUT@'], + capture : true, + install : tuple[1], + install_dir : pkgsysconfdir) +endforeach if conf.get('ENABLE_REMOTE') == 1 and conf.get('HAVE_MICROHTTPD') == 1 - journal_remote_conf = configure_file( - input : 'journal-remote.conf.in', - output : 'journal-remote.conf', - configuration : substs) - if install_sysconfdir_samples - install_data(journal_remote_conf, - install_dir : pkgsysconfdir) - endif - install_data('browse.html', install_dir : join_paths(pkgdatadir, 'gatewayd'))