'Copy build over SSH in Azure Pipelines

There is a generic description about achieving the goal , to copy build artifacts over ssh. I am able to sort out other things (build, config, folders, etc..) however, the only thing I couldn't find any example anywhere, was how to set the sshEndpoint property:

...
- task: CopyFilesOverSSH@0
  inputs:
    sshEndpoint:     <--- what to input here? i.e. myUsername:[email protected] ?
...

Can anyone provide step-by-step, how can we fill-out that with our credentials (please describe two cases of authorization through ssh: [A] password based [b] key-based



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source