25 lines
614 B
Bash
Executable file
25 lines
614 B
Bash
Executable file
#!/usr/bin/bash
|
|
set -euo pipefail
|
|
|
|
source /etc/os-release
|
|
export OS=$ID
|
|
|
|
# Generate OpenSSH server key pair
|
|
ssh-keygen -f /etc/ssh/ed25519 -t ed25519 -N ""
|
|
ssh-keygen -lvf /etc/ssh/ed25519 > /etc/ssh/ed25519.fp
|
|
|
|
source /install/install.sh
|
|
|
|
chown $sftpgo: /usr/local/bin/sftpgo
|
|
chmod u=rx,g=,o= /usr/local/bin/sftpgo
|
|
|
|
if [[ $OS = "arch" ]]; then
|
|
pacman-key --init
|
|
pacman-key --populate
|
|
fi
|
|
|
|
# Enable testing option
|
|
sed -i 's/local_only_check = false/local_only_check = true/' /srv/servnest/core/config.ini
|
|
|
|
chmod u=rwX,g=rX,o=rX / /etc /etc/tor/torrc
|
|
chmod -R u=rwX,g=rX,o=rX /etc/php /etc/knot-resolver
|