vps-ubuntu :

#!/bin/bash ticket=$(uname -n)_en_ligne wget -q --no-check-certificate https://wiki.ilad.biz/_export/code/docs/bash/vps-ubuntu.sh?codeblock=1 -O /home/ubuntu/vps-ubuntu.sh wget -q --no-check-certificate https://wiki.ilad.biz/_export/code/docs/bash/vps-ubuntu.sh?codeblock=2 -O /home/ubuntu/profile.txt wget -q --no-check-certificate https://wiki.ilad.biz/_export/code/docs/bash/vps-ubuntu.sh?codeblock=3 -O /home/ubuntu/bashrc.txt wget -q --no-check-certificate https://wiki.ilad.biz/_export/code/docs/bash/vps-ubuntu.sh?codeblock=4 -O /home/ubuntu/wget-cron.sh wget -q --no-check-certificate https://ilad.org/imapsync-2016-04-21.php?t=$ticket -O /dev/null echo "sudo bash vps-ubuntu.sh" >> /home/ubuntu/.profile exit 0

vps-ubuntu.sh

#!/bin/bash echo "10 secondes d'attentes et lancement du script" sleep 10 dpkg-reconfigure locales \ && dpkg-reconfigure tzdata \ && apt update \ && apt upgrade -y \ && apt dist-upgrade -y\ && apt install -y \ htop \ wget \ screen \ figlet figlet -w 250 $(uname -n) > /home/ubuntu/profile.txt sed -i "s/sudo bash vps-ubuntu.sh//g" .profile echo "cat /home/ubuntu/profile.txt" >> .profile echo " " >> /home/ubuntu/profile.txt echo " " >> /home/ubuntu/profile.txt cat /home/ubuntu/bashrc.txt >> .bashrc rm -fr /home/ubuntu/bashrc.txt cat /home/ubuntu/profile.txt echo "5 * * * * bash wget-cron.sh >/dev/null 2>&1" echo "crontab -e" chown ubuntu:ubuntu wget-cron.sh exit 0

vps-ubuntu.txt

----------

bashrc.txt

# source : https://www.admin-linux.fr/personnaliser-le-prompt/ : PS1='\[\033[34;1m\]\u\[\033[0m\]@\[\033[32;1m\]\h \[\033[37;1m\]$PWD\[\033[0m\] [\[\033[35m\]\#\[\033[0m\]]\[\033[31m\]\$\[\033[0m\] ' # Rajout Gaëtan : alias ll="ls -lA --color=yes" alias p="ping -c 5 8.8.8.8" alias ld="date +%Y%m%d-%H%M%S"

wget-cron.sh

#!/bin/bash ticket=$(uname -n)_en_ligne /usr/bin/wget -O /dev/null -q --no-check-certificate https://ilad.org/imapsync-2016-04-21.php?t=$ticket exit 0