This commit is contained in:
Marc Beninca 2023-05-19 20:14:13 +02:00
parent 755e938876
commit 275b8bdf2c

View file

@ -1,4 +1,5 @@
function ovh-rescue-configure {
local host="${1}"
local packages=(
'byobu' 'mosh'
)
@ -24,7 +25,7 @@ deb https://deb.debian.org/debian-security buster/updates main contrib non-free
# bash / rc
main_link_bashrc
# host name
hostname 'ovh'
hostname "${host}"
# locales
echo -n "\
en_US.UTF-8 UTF-8
@ -100,7 +101,7 @@ if [ "${host}" ] ; then
rsync --delete --recursive "${MAIN_BASH_ROOT}/" "${user_host}:/etc/bash/"
# call setup
# TODO variable
ssh "${user_host}" -- "source '/etc/bash/main.sh' ; ovh-rescue-configure"
ssh "${user_host}" -- "source '/etc/bash/main.sh' ; ovh-rescue-configure '${host}'"
# create session
ssh "${user_host}" -- byobu new-session -d
# send keys