mirror of
https://github.com/MacRimi/ProxMenux.git
synced 2025-06-27 20:06:52 +00:00
Update customizable_post_install.sh
This commit is contained in:
parent
f26572294f
commit
a076dc5a58
@ -1574,25 +1574,26 @@ install_lynis_() {
|
||||
install_lynis() {
|
||||
msg_info2 "$(translate "Installing latest Lynis security scan tool...")"
|
||||
|
||||
|
||||
# Instalar Git si no está presente
|
||||
if ! command -v git >/dev/null 2>&1; then
|
||||
msg_info "$(translate "Installing Git as a prerequisite...")"
|
||||
apt-get update
|
||||
apt-get install -y git
|
||||
apt-get update -qq >/dev/null 2>&1
|
||||
apt-get install -y git >/dev/null 2>&1
|
||||
msg_ok "$(translate "Git installed")"
|
||||
fi
|
||||
|
||||
|
||||
# Clonar Lynis desde GitHub (oculto)
|
||||
msg_info "$(translate "Cloning Lynis from GitHub...")"
|
||||
if git clone https://github.com/CISOfy/lynis.git /opt/lynis 2>/dev/null; then
|
||||
ln -sf /opt/lynis/lynis /usr/local/bin/lynis
|
||||
chmod +x /usr/local/bin/lynis
|
||||
if git clone --quiet https://github.com/CISOfy/lynis.git /opt/lynis >/dev/null 2>&1; then
|
||||
ln -sf /opt/lynis/lynis /usr/local/bin/lynis >/dev/null 2>&1
|
||||
chmod +x /usr/local/bin/lynis >/dev/null 2>&1
|
||||
msg_ok "$(translate "Lynis installed successfully from GitHub")"
|
||||
else
|
||||
msg_warn "$(translate "Failed to clone Lynis from GitHub")"
|
||||
return 1
|
||||
fi
|
||||
|
||||
|
||||
# Verificación
|
||||
if command -v lynis >/dev/null 2>&1; then
|
||||
msg_success "$(translate "Lynis is ready to use")"
|
||||
else
|
||||
@ -1604,6 +1605,7 @@ install_lynis() {
|
||||
|
||||
|
||||
|
||||
|
||||
# ==========================================================
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user