- Fix prometheus files path
- Fix sciprt allowing to execute w/out username param
- Add oh-my-zsh installation
- Fix typo un ssh authorized_keys file
- Fix PermitRootLogin disabling
This commit is contained in:
2025-01-23 23:47:10 -03:00
parent c08b6d393e
commit 21515daef1
6 changed files with 34 additions and 9 deletions

View File

@@ -2,8 +2,13 @@
function install_zsh() {
username=$1
echo "[ UTILS ]: Installing zsh"
echo "[ UTILS ]: Installing Zsh"
sudo apt-get install -y zsh
# Set Zsh as the default shell for the user
sudo chsh -s /usr/bin/zsh "$username"
echo "[ UTILS ]: Zsh installed succesfully and set as default shell for $username"
echo "[ UTILS ]: Installing Oh My Zsh for $username"
# Install Oh My Zsh
sudo -u "$username" sh -c "$(wget https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh -O -)"
echo "[ UTILS ]: Zsh and Oh My Zsh installed successfully and set as the default shell for $username"
}