updated sp.sh

This commit is contained in:
naturallaw77 2023-07-16 19:40:26 -07:00
parent 726dd66cbe
commit 48ee6e6164

View File

@ -217,6 +217,7 @@ chown vaultwarden:vaultwarden /var/lib/secrets/vaultwarden -R
chown onlyoffice:onlyoffice /var/lib/secrets/onlyofficejwtSecretFile chown onlyoffice:onlyoffice /var/lib/secrets/onlyofficejwtSecretFile
chmod 770 /var/lib/secrets/ -R chmod 770 /var/lib/secrets/ -R
# #
@ -343,6 +344,14 @@ popd
# #
pushd /home/free/Downloads
sudo -u free wget https://git.sovransystems.com/Sovran_Systems/Sovran_SystemsOS/raw/branch/main/for_new_sovran_pros/Sovran_SystemsOS-Desktop
popd
#
wp=$(cat /var/lib/secrets/wordpressdb) wp=$(cat /var/lib/secrets/wordpressdb)
sudo mysql -u root -e "SET PASSWORD FOR wpusr@localhost = PASSWORD('${wp}')"; sudo mysql -u root -e "SET PASSWORD FOR wpusr@localhost = PASSWORD('${wp}')";
@ -353,16 +362,16 @@ mkdir /root/.ssh
mkdir -p /home/free/.ssh mkdir -p /home/free/.ssh
chown free:users /home/free/.ssh -R
touch /root/.ssh/authorized_keys touch /root/.ssh/authorized_keys
sudo -u free ssh-keygen -q -N "gosovransystems" -t ed25519 -f /home/free/.ssh/factory_login sudo -u free ssh-keygen -q -N "gosovransystems" -t ed25519 -f /home/free/.ssh/factory_login
echo "$(cat /home/free/.ssh/factory_login.pub)" >> /root/.ssh/authorized_keys
chown free:users /home/free/.ssh -R
chmod 700 /home/free/.ssh -R chmod 700 /home/free/.ssh -R
echo "$(cat /home/free/.ssh/factory_login.pub)" >> /root/.ssh/authorized_keys
# #
sudo matrix-synapse-register_new_matrix_user -u admin -p a -a sudo matrix-synapse-register_new_matrix_user -u admin -p a -a
@ -386,6 +395,31 @@ echo -e "$(pwgen -s 17 -1) \n"
# #
DOMAIN=$(cat /var/lib/domains/matrix)
cp -n /var/lib/caddy/.local/share/caddy/certificates/acme.zerossl.com-v2-dv90/${DOMAIN}/${DOMAIN}.crt /var/lib/coturn/${DOMAIN}.crt.pem
cp -n /var/lib/caddy/.local/share/caddy/certificates/acme.zerossl.com-v2-dv90/${DOMAIN}/${DOMAIN}.key /var/lib/coturn/${DOMAIN}.key.pem
bash /var/lib/external_ip/external_ip.sh
chown turnserver:turnserver /var/lib/coturn -R
chmod 770 /var/lib/coturn -R
#
pushd /etc/nixos
nix flake update
nixos-rebuild switch --impure
popd
#
echo -e "${LIGHTBLUE}One last thing, you need to put the Njalla DDNS info from Njalla into njalla.sh.${ENDCOLOR} \n" echo -e "${LIGHTBLUE}One last thing, you need to put the Njalla DDNS info from Njalla into njalla.sh.${ENDCOLOR} \n"
echo -e "${GREEN}All Finished! Please Reboot then Enjoy your New Sovran Pro!${ENDCOLOR} \n" echo -e "${GREEN}All Finished! Please Reboot then Enjoy your New Sovran Pro!${ENDCOLOR} \n"