SSH

The SSH data source in UI Bakery allows you to securely connect to remote servers and retrieve data for use in your UI Bakery applications. With this data source, you can seamlessly integrate data from various SSH-enabled sources, such as Linux servers, cloud instances, or network-attached storage (NAS) systems.

Connecting to an SSH server

Below are the steps to connect to a Linux-based server from UI Bakery.

Host server configuration

On your host server, you need to make sure that:

  • sshd service is started and port 22 is open for inbound connections

  • the server is accepting inbound connections from UI Bakery instance. If it's not possible to connect to the server from UI Bakery instance, it's still possible to connect to it through SSH tunnel and Bastion host

  • We suggest creating an additional user with restricted permissions for SSH connections

  • You might also want to disable password authentication by editing /etc/ssh/sshd_config file and adding PasswordAuthentication no instruction. Afterwards, you will need to restart sshd service, for instance, sudo service sshd restart

Generate a key for ssh

For key-based authentication, you must generate a key for UI Bakery to connect to your host server. You can use the following command to achieve that:

ssh-keygen -t ecdsa -m PEM -f ./private_key.pem

Enter the passphrase for the key, or leave it empty.

Add key to your server's authorized keys list

In order to allow UI Bakery to connect to your Host machine as a specific user, login as that user and add your public key to the list of authorized keys. Usually, you will need to modify ~/.ssh/authorized_keys file and add your public key as a separate line there.

If you generated ssh key using the command in the section above, you can get your public key using the following command:

ssh-keygen -y -f ./private_key.pem

Connecting SSH data source in UI Bakery

To connect to your server via SSH and be able to execute BASH scripts there, you will need to fill in the SSH connection credentials based on your server authentication configuration:

Please note, that your key must be in PEM format, which means that it should include -----BEGIN EC PRIVATE KEY----- and -----END PRIVATE KEY----- lines.

SSH command

Last updated