Using a key to connect to a TWSC container in Windows 10

Classification: BLOG, Compute

1. Open PowerShell

2. Inputssh-keygenEnter the Enter key three times to create a gold key.

ssh-keygen
PS C:\Users\user> ssh-keygen Generating public/private rsa key pair. Enter file in which to save the key (C:\Users\user/.ssh/id_rsa): Enter passphrase (empty for no passphrase): Enter same passphrase again: Your identification has been saved in C:\Users\user/.ssh/id_rsa. Your public key has been saved in C:\Users\user/.ssh/id_rsa.pub. The key fingerprint is: SHA256:O█████████████████████████████████s happybuffet@hellobuffet The key's randomart image is: +---[RSA 3072]----+ | +B= | |████████████████ | | ███████████████| +----[SHA256]-----+

3. Start TWSC, create any container, and enter...Detailed information on development containersGet SSH connection information

4. InPowerShellEnter the command below, then enter the host password, and upload the key to log in to the container.

type $env:USERPROFILE\.ssh\id_rsa.pub | ssh {IP-ADDRESS-OR-FQDN} "cat >> .ssh/authorized_keys""

Demonstration Instructions
type $env:USERPROFILE.ssh\id_rsa.pub | ssh testaccount@203.145.219.158 -p 50725 "cat >> .ssh/authorized_keys"“

5. Test login by entering "ssh" in PowerShell to connect.

Demonstration Instructions
ssh testaccount@203.145.219.158 -p 50725
Are you sure you want to continue connecting (yes/no/[fingerprint])?Enter yes

6. Use Mobaxterm to connect.

Refer to the image below and enter the IP address, host account, and port number.
The key path refers to the location of the RSA key established in step two.
Reference path:C:\Users\user\.ssh\id_rsa

7. Delete the created container.

On the TWSC development container management page, delete the container you created.
Since the key has already been uploaded to the HFS space, the newly added development container and the xdata1 node for uploading data will be used subsequently.
You can log in directly using the newly added key.

8. Use FILEZILLA for connection.

Refer to the image and parameters below.
Agreement: SFTP
Host:xdata1.twcc.ai
Port number: 22
Login type: Key file
User: Host Account
Location of the key file (for reference):C:\Users\user\.ssh\id_rsa

EDM Subscription

EDM Subscription

On-Demand AI Cloud Consulting

Sales Contact
Sales Contact Form