Diadem Technologies Support Knowledgebase

SSH Access to a Diadem Express Cloud Account

Article ID: 963
Last updated: 04 Jan, 2023

1. Open the Diadem EC dashboard and navigate the toolbar options of perticular Instance.


2. Click the Settings button from Instance.

From Instance -> Settings


OR
From Accounts Settings

In the opened Account settings tab, navigate to the SSH Keychain -> Public -> Add Public Key option.

3. Click the link in the note to open your SSH gate.  As a result, you’ll access Shell Handler via console automatically. Or, just copy the given command line and run it via your console (SSH client).

SSH Connectivity from client end
We can use Linux, MacOS, FreeBSD servers for SSH connectivity from client end. Also if the clients are tryed to connect SSH from local window system they need some SSH third party software as Putty or MobaXterm.
MobaXterm Software download link: http://download.mobatek.net/10220170312132617/MobaXterm_Installer_v10.2.zip


4. Please open the MobaXterm software and start the local terminal.

NOTE: To establish the SSH connection for Windows OS, you need to have a private key on your local machine which corresponds to the public one, previously added to the Diadem EC dashboard. Therefore, perform the following steps:


5. Run the below given command at local terminal on MobaXterm softeware.
# ssh-keygen -t rsa
Enter passphrase (empty for no passphrase): press enter
Enter same passphrase again:press enter
The key fingerprint is:press enter

6. Yoy can find the public key from id_rsa.pub file on below location.
# cat /home/mobaxterm/.ssh/id_rsa.pub

7. To establish the SSH connection for Windows OS, you need to have a private key on your local machine which corresponds to the public one, previously added to the Diadem EC dashboard.


8. Now you can run the ssh command shown on Diadem EC Panel.
# ssh [email protected] -p 3022

9. After that, you’ll see a full list of containers provisioned for the chosen environment.

10. Beside each container its node ID and Public IP address are stated.

11. To access the container, enter its list number.


Direct Access to the Container

You can also "jump" directly to the necessary container, skipping the steps of choosing appropriate environment and node.


To perform this, you need to know the required container ID. It can be retrieved using the previously described method of SSH access with interactive menu. There, you can see a list of all available containers and their ID numbers (the nodeid value).


Use the nodeid value of the required container in the command of the following type:

# ssh {nodeid}-{uid}@{SSH_gate} -p 3022

Example:
For apache node:
# ssh [email protected] -p 3022

For MySQL node:
# ssh [email protected] -p 3022


SSH port change from 22 to 2043 for a Express Cloud VPS

1. Change the port in /etc/ssh/sshd_config
Port 2243

2. Modify iptables rules
*nat
iptables -t nat -A PREROUTING -p tcp -m tcp --dport 22 -j REDIRECT --to-ports 2243

*filter
iptables -t filter -A INPUT -p tcp -m tcp --dport 2243 -m state --state NEW -j ACCEPT

Article ID: 963
Last updated: 04 Jan, 2023
Revision: 6
Views: 731