feat(installer): integrate full HA Keepalived setup, sysctl, sudoers and cluster helper into install.sh
This commit is contained in:
1 parent
3edcabff7c
commit
4c49cf8e1c
1 file changed
+10
+10
@@ -66,6 +66,8 @@ apt-get install -y --no-install-recommends \
|
|||||||
|
|
||||||
# Composants optionnels Haute Disponibilité (Cluster HA)
|
# Composants optionnels Haute Disponibilité (Cluster HA)
|
||||||
apt-get install -y --no-install-recommends keepalived 2>/dev/null || true
|
apt-get install -y --no-install-recommends keepalived 2>/dev/null || true
|
||||||
|
systemctl stop keepalived >/dev/null 2>&1 || true
|
||||||
|
systemctl disable keepalived >/dev/null 2>&1 || true
|
||||||
|
|
||||||
# Vérification et installation d'Asterisk
|
# Vérification et installation d'Asterisk
|
||||||
echo -e "${C_GREEN} -> Installation du moteur Asterisk PBX...${C_RESET}"
|
echo -e "${C_GREEN} -> Installation du moteur Asterisk PBX...${C_RESET}"
|
||||||
@@ -494,6 +496,14 @@ ln -sf "$TARGET_DIR/scripts/nexus-banner.sh" /usr/local/bin/nexus-banner
|
|||||||
ln -sf "$TARGET_DIR/scripts/update.sh" /usr/local/bin/nexus-update
|
ln -sf "$TARGET_DIR/scripts/update.sh" /usr/local/bin/nexus-update
|
||||||
ln -sf "$TARGET_DIR/scripts/nexus-cluster" /usr/local/bin/nexus-cluster
|
ln -sf "$TARGET_DIR/scripts/nexus-cluster" /usr/local/bin/nexus-cluster
|
||||||
|
|
||||||
|
# Pré-déploiement sécurisé des scripts Keepalived
|
||||||
|
if [ -d "$TARGET_DIR/scripts/cluster" ]; then
|
||||||
|
cp -f "$TARGET_DIR/scripts/cluster/"*.sh /etc/keepalived/scripts/ 2>/dev/null || true
|
||||||
|
chown -R root:root /etc/keepalived
|
||||||
|
chmod 755 /etc/keepalived /etc/keepalived/scripts
|
||||||
|
chmod 755 /etc/keepalived/scripts/*.sh 2>/dev/null || true
|
||||||
|
fi
|
||||||
|
|
||||||
# Bannière interactive lors de chaque connexion terminal (SSH / Console)
|
# Bannière interactive lors de chaque connexion terminal (SSH / Console)
|
||||||
cat << 'EOF' > /etc/profile.d/nexus-motd.sh
|
cat << 'EOF' > /etc/profile.d/nexus-motd.sh
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|||||||
Reference in new issue
Block a user