merge brice branch

This commit is contained in:
Grégory Lebreton 2025-10-29 12:57:04 +01:00
parent 228ddaf5e1
commit be04f0a515
5 changed files with 95 additions and 95 deletions

0
_change-icons.sh Normal file → Executable file
View File

0
firefox.sh Normal file → Executable file
View File

0
gnome.sh Normal file → Executable file
View File

0
install_apps.sh Normal file → Executable file
View File

190
post_install_trixie.sh Normal file → Executable file
View File

@ -1,111 +1,111 @@
#!/bin/bash #!/bin/bash
source ./install_apps.sh
######################## LOGFILE="$HOME/postinstall.log"
## APT CONFIGURATION ## > "$LOGFILE"
# Note : passage au format deb822 >> debian.sources
########################
sudo cp files/debian.sources /etc/apt/sources.list.d/ run_step() {
sudo rm /etc/apt/sources.list local description="$1"
sudo apt update local command="$2"
echo -n "$description... "
eval "$command" > /dev/null 2>>"$LOGFILE"
if [ $? -eq 0 ]; then
echo "✅"
else
echo "❌ (voir $LOGFILE)"
fi
}
#################################
# 🎯 POST-INSTALL DEBIAN 13 #
#################################
run_step '📦 Configuration des sources APT' "
sudo cp files/debian.sources /etc/apt/sources.list.d/ &&
if [ -f /etc/apt/sources.list ]; then
sudo cp /etc/apt/sources.list /etc/apt/sources.list.backup
sudo rm /etc/apt/sources.list
fi
"
run_step "🆙 Mise à jour du système" "
sudo apt update &&
sudo apt upgrade -y sudo apt upgrade -y
"
################### # 🧰 BASE TOOLS
## BASE PACKAGES ## run_step "🔧 Installation des outils de base" "
################### sudo apt install -y libgettextpo-dev gettext git wget curl build-essential linux-image-amd64 make ttf-mscorefonts-installer rsyslog unzip bash-completion flatpak libxdo3 extrepo
sudo apt install libgettextpo-dev gettext git wget curl build-essential linux-image-amd64 make ttf-mscorefonts-installer rsyslog unzip bash-completion flatpak libxdo3 extrepo -y "
run_step "🛒 Ajout du dépôt Flathub" "
flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
"
#sudo cp files/extrepo.config.yaml /etc/extrepo/config.yaml # 🌐 DNS
#sudo extrepo enable google_chrome run_step "🌐 Configuration DNS Cloudflare" "
#sudo apt update echo -e '[main]\ndns=none' | sudo tee /etc/NetworkManager/conf.d/90-dns-none.conf &&
#sudo apt install google-chrome-stable sudo systemctl reload NetworkManager &&
#sudo extrepo enable firefox sudo sed -i '1,4 s/^/#/' /etc/resolv.conf &&
#sudo apt install firefox sudo sed -i -e '\$anameserver 1.1.1.2\nameserver 2606:4700:4700::1112' /etc/resolv.conf &&
sudo systemctl reload NetworkManager
"
### # 🎨 LIBREOFFICE
## LANG >> FR run_step "🎨 Icônes LibreOffice (Colibre)" "
sudo chown $USER:$USER files/registrymodifications.xcu &&
mkdir -p \$HOME/.config/libreoffice/4/user/ &&
# Installation de Freetube cp files/registrymodifications.xcu \$HOME/.config/libreoffice/4/user/ &&
# sudo mkdir -p /etc/skel/.config/libreoffice/4/user/ &&
# sudo cp files/registrymodifications.xcu /etc/skel/.config/libreoffice/4/user/
# "
## Firefox via dépôt Mozilla
#
#
#
## Install de Chrome
#
#
#
## Install de Zoom
#
#
#
## Install d'Element
#
#
#
## Install de VSCodium
#
#
#
## WebAppManager >> CAF
## Prise en main à distance
#############################
## INTERNET ACCESS CONTROL ##
#############################
echo $'[main]\ndns=none' | tee /etc/NetworkManager/conf.d/90-dns-none.conf &>/dev/null
systemctl reload NetworkManager
sudo sed -i '1,4 s/^/#/' /etc/resolv.conf && sed -i -e '$anameserver 1.1.1.2\nnameserver 2606:4700:4700::1112' /etc/resolv.conf
systemctl reload NetworkManager
#cloudflare DNS Anti Malware
#####################
# LIBREOFFICE ICONS #
#####################
# On active 'Colibre' comme jeu d'icônes par défaut
sudo chown $USERNAME:$USERNAME files/registrymodifications.xcu
mkdir -p $HOME/.config/libreoffice/4/user/ && cp files/registrymodifications.xcu $_
# On ajoute un modèle dans /etc/skel afin que tout nouvel utilisateur ait Colibre activé par défaut
sudo mkdir -p /etc/skel/.config/libreoffice/4/user/ && sudo cp files/registrymodifications.xcu $_
############
# FIREFOX #
############
# 🦊 FIREFOX
run_step "🦊 Installation de Firefox (script)" "
bash firefox.sh bash firefox.sh
"
# 🖥️ GNOME
############
# GNOME #
############
if whiptail --title "Configuration GNOME" --yesno "Souhaitez-vous configurer GNOME maintenant ?" 10 60; then if whiptail --title "Configuration GNOME" --yesno "Souhaitez-vous configurer GNOME maintenant ?" 10 60; then
echo "🔧 Lancement de gnome.sh..." run_step "🖥️ Configuration de GNOME (script)" "
bash ./gnome.sh bash gnome.sh
"
else else
echo "⏭️ Configuration GNOME ignorée." echo "⏭️ Configuration GNOME ignorée."
fi fi
##############################
## SELECTION DES LOGICIELS ##
##############################
CHOIX=$(whiptail --title "Installation de logiciels" --checklist \
"Choisissez les logiciels à installer :" 20 78 10 \
"freetube" "FreeTube (YouTube sans pub)" ON \
"zoom" "Zoom (visioconférence)" OFF \
"element" "Element (messagerie Matrix)" OFF \
"chrome" "Google Chrome (navigateur)" OFF \
"vscodium" "VSCodium (éditeur de code)" ON \
3>&1 1>&2 2>&3)
# Nettoyage des guillemets doubles de la sortie de whiptail
CHOIX=$(echo $CHOIX | tr -d '"')
for APP in $CHOIX; do
case $APP in
freetube) install_freetube ;;
zoom) install_zoom ;;
element) install_element ;;
chrome) install_chrome ;;
vscodium) install_vscodium ;;
*) echo "❓ Logiciel inconnu : $APP" ;;
esac
done
echo -e "\n🎉 Post-installation terminée."
echo "📄 Rapport des erreurs (s'il y en a) : $LOGFILE"