Fix broken PPA repositories will cause SSHd installation to fail

This commit is contained in:
allegroai 2022-05-08 23:42:30 +03:00
parent 0dc094c03d
commit 8c9174e760

View File

@ -468,7 +468,7 @@ def setup_ssh_server(hostname, hostnames, param, task):
# noinspection SpellCheckingInspection
os.system(
"export PYTHONPATH=\"\" && "
"([ ! -z $(which sshd) ] || (apt-get update && apt-get install -y openssh-server)) && "
"([ ! -z $(which sshd) ] || (apt-get update ; apt-get install -y openssh-server)) && "
"mkdir -p /var/run/sshd && "
"echo 'root:{password}' | chpasswd && "
"echo 'PermitRootLogin yes' >> /etc/ssh/sshd_config && "