mirror of
https://github.com/systemd/systemd
synced 2024-09-30 05:15:19 +00:00
meson: don't put a symlink pointing to '20-systemd-ssh-proxy.conf' in /etc in all cases
On distros like SUSE where ssh config dropins in /usr are supported, there's no need for a symlink in /etc/ssh/ssh_config.d/ that points to the dropin installed somewhere in /usr (that is not reachable by ssh).
This commit is contained in:
parent
e67129e5e4
commit
de0f11d790
|
@ -204,6 +204,7 @@ sshconfdir = get_option('sshconfdir')
|
|||
if sshconfdir == ''
|
||||
sshconfdir = sysconfdir / 'ssh/ssh_config.d'
|
||||
endif
|
||||
conf.set10('LINK_SSH_PROXY_DROPIN', sshconfdir != 'no' and not sshconfdir.startswith('/usr/'))
|
||||
|
||||
sshdconfdir = get_option('sshdconfdir')
|
||||
if sshdconfdir == ''
|
||||
|
|
|
@ -18,10 +18,12 @@ if conf.get('ENABLE_SSH_PROXY_CONFIG') == 1
|
|||
output : '20-systemd-ssh-proxy.conf',
|
||||
command : [jinja2_cmdline, '@INPUT@', '@OUTPUT@'],
|
||||
install : true,
|
||||
install_dir : libexecdir / 'ssh_config.d')
|
||||
install_dir : sshconfdir.startswith('/usr/') ? sshconfdir : libexecdir / 'ssh_config.d')
|
||||
|
||||
install_emptydir(sshconfdir)
|
||||
if not sshconfdir.startswith('/usr/')
|
||||
install_emptydir(sshconfdir)
|
||||
|
||||
meson.add_install_script(sh, '-c',
|
||||
ln_s.format(libexecdir / 'ssh_config.d' / '20-systemd-ssh-proxy.conf', sshconfdir / '20-systemd-ssh-proxy.conf'))
|
||||
meson.add_install_script(sh, '-c',
|
||||
ln_s.format(libexecdir / 'ssh_config.d' / '20-systemd-ssh-proxy.conf', sshconfdir / '20-systemd-ssh-proxy.conf'))
|
||||
endif
|
||||
endif
|
||||
|
|
|
@ -7,7 +7,9 @@
|
|||
|
||||
# See tmpfiles.d(5) for details
|
||||
|
||||
{% if LINK_SSH_PROXY_DROPIN %}
|
||||
L {{SSHCONFDIR}}/20-systemd-ssh-proxy.conf - - - - {{LIBEXECDIR}}/ssh_config.d/20-systemd-ssh-proxy.conf
|
||||
{% endif %}
|
||||
{% if CREATE_SSHDPRIVSEPDIR %}
|
||||
d {{SSHDPRIVSEPDIR}} 0755
|
||||
{% endif %}
|
||||
|
|
Loading…
Reference in a new issue