Skip to content

Commit

Permalink
view service status added to tunnel management
Browse files Browse the repository at this point in the history
  • Loading branch information
Musixal authored Aug 3, 2024
1 parent 5570444 commit b9734eb
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion rathole_v2.sh
Original file line number Diff line number Diff line change
Expand Up @@ -806,7 +806,8 @@ tunnel_management() {
colorize green "3) Add a new config for this tunnel"
colorize reset "4) Add a cronjob for this tunnel"
colorize reset "5) Remove existing cronjob for this tunnel"
colorize reset "6) View logs"
colorize reset "6) View service logs"
colorize reset "7) View service status"
echo
read -p "Enter your choice (0 to return): " choice

Expand All @@ -817,6 +818,7 @@ tunnel_management() {
4) add_cron_job_menu "$service_name";;
5) delete_cron_job "$service_name";;
6) view_service_logs "$service_name" ;;
7) view_service_status "$service_name" ;;
0) return 1 ;;
*) echo -e "${RED}Invalid option!${NC}" && sleep 1 && return 1;;
esac
Expand Down Expand Up @@ -1115,6 +1117,13 @@ view_service_logs (){
journalctl -eu "$1"

}

view_service_status (){
clear
systemctl status "$1"

}

update_script(){
# Define the destination path
DEST_DIR="/usr/bin/"
Expand Down

0 comments on commit b9734eb

Please sign in to comment.