Nội dung
1. Overview
If you are administering a DirectAdmin hosting server with many different users, you may have a situation where a customer needs to enable SSH for a DirectAdmin user to perform some of their needs as follows:
- Download files, compress and decompress quickly with the command.
- Use the WordPress CLI.
- Deploy applications quickly, especially for customers using Laravel source code.
These are just a few typical examples, but customers’ needs are many. So in this article, I will show you how to enable SSH for DirectAdmin users the fastest way.
2. Enable SSH for DirectAdmin user
To enable SSH for DirectAdmin users, we will have the following 2 cases:
- Case 1: The user belongs to admin.
- Case 2: The user is in any reseller.
Case 1: The user belongs to admin
In this case, everything is very simple. You just need to choose the Reseller level, as shown below:
After you have selected the Reseller level, go to the Account Manager feature list => select List Users.
Next, you select the user’s details who needs to enable the SSH feature. For example, I will choose the User named demo2.
When entering the modified interface, scroll down and you will see that the SSH Access option is not enabled, you just need to tick and save it, this user will be able to SSH. In some cases, you have SSH Access enabled but cannot SSH because the Login Keys option is not enabled.
After saving, let’s try SSH with the demo2 user.
Here I have SSH successfully with user demo2. Remember to SSH with the SSH port of your server; my VPS SSH port is 22385, so I will add -p 22385 after the SSH information.
Case 2: User is in any reseller
If you receive a request to open SSH from a reseller on your VPS/Server, then you have two methods:
Method 1: Enable SSH separately for users belonging to any reseller
In this method, you must stand at the Access Level as Admin.
Continue to hover over the Account Manager feature and select List Users .
In this section, you select the details of the user who needs to enable the SSH feature. For example, I will choose a User named demo3 of a reseller named rsh.
Select this user details and select modify to enable SSH permissions.
When entering the modified interface, scroll down and you will see that the SSH Access option is not enabled, you just need to tick and save it, this user will be able to SSH. In some cases, you have SSH Access enabled but cannot SSH because the Login Keys option is not enabled.
After saving, let’s try SSH with user demo3.
So I have SSH successfully with user demo3. Remember to SSH with the SSH port of your server; my VPS SSH port is 22385, so I will add -p 22385 after the SSH information.
Method 2: Enable SSH Access for resellers so that resellers actively enable them for users
If you want the reseller to enable users actively, you need to adjust the reseller’s permissions. The steps are as follows:
In this method, you must stand at the Access Level as Admin.
After you have selected the Admin level, hover your mouse over the Account Manager feature list and select List Resellers.
Next, you select the Resellers’ details to which you want to grant SSH permissions and manage SSH permissions of the users of these Resellers. Then select Modify as shown below:
When entering the modified interface, scroll down and see that the SSH Access option, as well as SSH Access for Users, is not enabled. Note:
- SSH Access: allows SSH-authorized reseller accounts.
- SSH Access for Users: allows reseller accounts to enable SSH for those who belong to that reseller.
So you need to enable both of these options if you want the reseller to manage which users have SSH permissions actively.
Save and this reseller has the right to manipulate its users.
Summary
Above, AZDIGI showed you how to enable SSH for DirectAdmin users in the most detail, with many cases set out for you to understand. Hope this article is helpful to you.
Wishing you success.