Introduction

What are Targets?

This feature provides users with a centralized and automated control over deployment targets. This allows to store FTP/FTPS/SFTP or SSH server details in a single place to be used across multiple projects, pipelines or actions.

Currently Buddy supports two types of targets:

  • FTP
  • SFTP & SSH

That can be used in the following actions:

  • SFTP/FTP - sending files to FTP/FTPS/SFTP servers.
  • SSH - running commands on servers using the SSH protocol.
  • Download FTP, SFTP - downloading files from the servers and saving them locally in the filesystem.

Image loading...Actions supporting targets

Selecting targets

There are two ways of selecting a target:

  • Specific targets - select targets manually, without applying additional filters.
  • Filters - select based on specific filters like tags (e.g. all servers tagged as production), ID (using their full names or simple wildcards like *, *stage*, *stage ) or scope.

You can access multiple targets within a single action. The number of consecutive transfers depends on the number of runners available in your current plan.

Image loading...Transfer action with multipe targets

Managing action and pipeline targets with YAML

Action and pipeline targets can be defined in YAML files, allowing for easy and automated management. Here is an example of a YAML file with three targets set-up within a single action, one of which is inline.

yaml
- action: "Execute ls" type: "SSH_COMMAND" commands: - "ls -al" targets: - type: "SSH" id: "myTarget1" host: "domain.com" auth: username: "$login_ssh" password: "secure!dJyAQBqXzJHQvPMglTZT5Q==.6SmXCn3OHzNur6SHUwdjDA==" - "myTarget2" - "myTarget3" retry_count: 1 run_as_script: true

Targets in REST API

Thanks to our REST API, you can not only add targets to actions like SFTP & FTP, SSH and Download FTP, SFTP but also manage them.

You can find out more regarding targets in REST API in the following articles:

Hint
Currently workspace and pipeline targets cannot be managed via the REST API

Last modified on Dec 19, 2024