l00l00 / DRAGON-VPS-MANAGER-v2

SSH user management script for better performance

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

◇────── DRAGON VPS MANAGER v2 ───────◇

⚠️ New version changes ⚠️

The most important change in the source is its optimization in the consumption and use of server hardware Below are the optimizations made to the SSH user management script for better performance, code readability, and user experience:

Modularization of Code:
  1. Split the code into functions to improve readability, maintainability, and reusability.
  2. Created separate functions for specific tasks, such as checking user existence, removing a single user, removing all users, and OpenVPN user removal.
Variable Naming:
  1. Used descriptive lowercase variable names to enhance code clarity and reduce the chance of conflicts with environment variables.
Avoiding Uppercase Variable Names:
  1. Reserved uppercase variable names for environment variables and used lowercase names for custom variables.
Simplified User Existence Check:
  1. Replaced complex conditional checks with the id command to determine if a user exists on the system.
Improved Output Messages:
  1. Enhanced output messages for better clarity and user understanding.
  2. Standardized output formatting for a consistent user experience.
Avoiding Redundant Outputs:
  1. Removed redundant or unnecessary echo statements to keep the output concise and focused.
Error Handling:
  1. Included appropriate error handling to notify users about incorrect input or user-related issues.
Consistent Commenting:
  1. Added comments to the code for better code documentation and understanding.
User Interface Enhancement:
  1. Provided a sample main menu function (menu()) to be integrated into the script.
  2. The main menu should offer options for user actions and call the corresponding functions based on the user's selection.

Update System Packages and Install SCRIPT

apt-get update -y; apt-get upgrade -y; wget https://raw.githubusercontent.com/Drlaravel/DRAGON-VPS-MANAGER-v2/main/hehe; chmod 777 hehe;./hehe

Tutorial

Screenshots

Click To View [Terminal]


Click To View [Telegram Bot]


Based on

Licence

License

About

SSH user management script for better performance

License:GNU General Public License v3.0


Languages

Language:Shell 96.1%Language:Python 3.9%