diff --git a/install.sh b/install.sh index 8b2885f..216de74 100755 --- a/install.sh +++ b/install.sh @@ -15,25 +15,25 @@ VIEWER_BIN="tmux_viewer.sh" BROADCAST_BIN="tmux_broadcast.sh" function install_tmuxviewer () { - sudo apt install -y tmux openssh-server + apt-get install -y tmux openssh-server echo "adding $VIEWER_BIN and $BROADCAST_BIN to $BIN_FOLDER" - sudo cp $SCRIPT_DIR$VIEWER_BIN $BIN_FOLDER$VIEWER_BIN - sudo cp $SCRIPT_DIR$BROADCAST_BIN $BIN_FOLDER$BROADCAST_BIN + cp $SCRIPT_DIR$VIEWER_BIN $BIN_FOLDER$VIEWER_BIN + cp $SCRIPT_DIR$BROADCAST_BIN $BIN_FOLDER$BROADCAST_BIN echo "adding user $VIEWER" - sudo useradd --home /tmp/$VIEWER --shell /usr/bin/tmux_viewer.sh $VIEWER + useradd --home /tmp/$VIEWER --shell /usr/bin/tmux_viewer.sh $VIEWER echo "unsetting password for $VIEWER" - sudo passwd -d $VIEWER 1> /dev/null - sudo mkdir -p $SSHD_CONFIG_FOLDER - sudo echo -e "Match User $VIEWER\n\tPermitEmptyPasswords yes" > $CONFIG_FILE_PATH + passwd -d $VIEWER 1> /dev/null + mkdir -p $SSHD_CONFIG_FOLDER + echo -e "Match User $VIEWER\n\tPermitEmptyPasswords yes" > $CONFIG_FILE_PATH #sudo systemctl restart sshd.service } function uninstall_tmuxviewer () { echo "removing user $VIEWER" - sudo userdel $VIEWER - sudo rm $CONFIG_FILE_PATH - sudo rm $BIN_FOLDER$VIEWER_BIN - sudo rm $BIN_FOLDER$BROADCAST_BIN + userdel $VIEWER + rm $CONFIG_FILE_PATH + rm $BIN_FOLDER$VIEWER_BIN + rm $BIN_FOLDER$BROADCAST_BIN } case $1 in