1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-31 05:41:08 +00:00

create ssh_config-dist and sshd_config-dist

make sure that package install and deinstall
don't temper existing configuration files.
install sshd.sh now as sample.

Package changed, but no need to update
if you have PORTREVISION=2
This commit is contained in:
Dirk Meyer 2002-03-12 17:50:42 +00:00
parent c44867d8ea
commit 0bb6535e08
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=55940
2 changed files with 13 additions and 9 deletions

View File

@ -7,7 +7,7 @@
PORTNAME= openssh
PORTVERSION= 3.1
PORTREVISION= 2
PORTREVISION= 3
CATEGORIES= security
MASTER_SITES= ftp://ftp.openbsd.org/pub/OpenBSD/OpenSSH/ \
ftp://ftp.usa.openbsd.org/pub/OpenBSD/OpenSSH/ \
@ -119,12 +119,12 @@ post-install:
@${ECHO_MSG} ">> Installing moduli."
${INSTALL_DATA} -c ${FILESDIR}/moduli ${PREFIX}/etc/moduli
.endif
.if !exists(${PREFIX}/etc/rc.d/sshd.sh)
@${INSTALL_SCRIPT} ${WRKSRC}/sshd.sh ${PREFIX}/etc/rc.d/
.endif
${INSTALL_SCRIPT} ${WRKSRC}/sshd.sh ${PREFIX}/etc/rc.d/sshd.sh.sample
${INSTALL_DATA} -c ${WRKSRC}/ssh_config ${PREFIX}/etc/ssh_config-dist
${INSTALL_DATA} -c ${WRKSRC}/sshd_config ${PREFIX}/etc/sshd_config-dist
.if !exists(${PREFIX}/etc/ssh_config) && !exists(${PREFIX}/etc/sshd_config)
@cd ${WRKSRC}; \
${MAKE} DESTDIR=${PREFIX} distribution
${INSTALL_DATA} -c ${WRKSRC}/ssh_config ${PREFIX}/etc/ssh_config
${INSTALL_DATA} -c ${WRKSRC}/sshd_config ${PREFIX}/etc/sshd_config
.else
@${ECHO_MSG} ">> ${PREFIX}/etc/ssh{,d}_config exists, not being replaced!"
@${ECHO_MSG} ">> If this is left over from another version of SSH, you will"

View File

@ -6,10 +6,14 @@ bin/ssh-add
bin/ssh-agent
bin/ssh-keygen
bin/ssh-keyscan
etc/rc.d/sshd.sh
etc/ssh_config
etc/sshd_config
etc/rc.d/sshd.sh.sample
etc/moduli
@unexec if cmp -s %D/etc/ssh_config %D/etc/ssh_config-dist; then rm -f %D/etc/ssh_config; fi
@unexec if cmp -s %D/etc/sshd_config %D/etc/sshd_config-dist; then rm -f %D/etc/sshd_config; fi
etc/ssh_config-dist
etc/sshd_config-dist
@exec [ ! -f %D/etc/ssh_config ] && cp %D/etc/ssh_config-dist %D/etc/ssh_config
@exec [ ! -f %D/etc/sshd_config ] && cp %D/etc/sshd_config-dist %D/etc/sshd_config
sbin/sshd
libexec/sftp-server
libdata/ssh/Ssh.bin