On this page
SSH Support
As an option, DRD support SSH on a per host basis and that will offer you extra functionality that otherwise wouldn't be possible.
Pre-requisites
Of course, you need to be able to login to the remote hosts from your DRD host via SSH from the console. If that's possible, then you can make that available to DRD as well.
What's needed - and that's only on the DRD host - is the SSH2 extension for PHP. To find out if that's already available, just go to https://www.example.com/admin/reports/status/php on your DRD site and search for SSH2. If you find something similar to this, you're lucky and all is perfect and ready to go:
If it's not available yet, you have to install the extension yourselves. How to do that depends on the operating system and PHP version you're using, so you should search the web for instructions on how to do it. Just as an example, on Ubuntu with PHP 7 this could be as simple as using this command:
sudo apt-get install php-ssh2
Note that after adding a new PHP extension you may have to restart your webserver.
Configuration
If SSH support for PHP is available on your DRD host, you will find a new checkbox in the host edit form:
If you enable that you will be prompted with a range of additional settings:
This is what they mean:
- Hostname or IP
- The name or ip address on how that host is identified from the DRD host.
- Port
- The port that's been used to connect to the remote host via SSH.
- User name
- The user name for which SSH access is being configured and that will be used with its permissions to operate on the remote host.
- Auth mode
- The mode on how to authenticate a session for the given user on the remote host. Your choice depends on what's configured on the remote host, the options are:
- Username and password
- This is not recommended for security reasons but still the default for a lot of hosts out there on the net. If this is what's available to you, simply provide the password for the user defined above.
- Public Key
- Identifying a a user for an SSH session with a private key for a pre-configured public key on the remote host is much more secure and the method being used more and more often. In this case you have to provide a few more settings:
- Public Key filename
- The fully qualified path and filename for the public key file, e.g.
/home/username/.ssh/id_rsa.pub
- Private Key filename
- The fully qualified path and filename for the private key file, e.g.
/home/username/.ssh/id_rsa
- Passphrase for encrypted private key
- If your private key file is encrypted and protected by a passphrase, which is highly recommended, then you need to provide that passphrase here in order to be able to esatblish SSH connections with the remote host automatically
- Agent
- With this option PHP will use the SSH configuration of the operating system and you don't have to provide any more details in here.
Utilizing SSH connections
If a host is configured with SSH, then this can be used for all cores on that host and of course for all domains on all those cores.
The functionality that requires SSH is not yet implemented in version 3.0 but is top on the roadmap:
Help improve this page
You can:
- Log in, click Edit, and edit this page
- Log in, click Discuss, update the Page status value, and suggest an improvement
- Log in and create a Documentation issue with your suggestion