curl -X POST "https://api.buddy.works/workspaces/:domain/projects/:project_name/pipelines/:pipeline_id/actions" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "Content-Type: application/json" \
-d '{
"name": "Execute commands on 5.75.234.250",
"type": "SSH_COMMAND",
"trigger_time": "ON_EVERY_EXECUTION",
"working_directory": "tests/SSH_Tests/",
"commands": [
"date >> tmp.log"
],
"targets": [
{
"type": "SSH",
"id": "vlatncuatc",
"host": "5.75.234.250",
"port": "22",
"auth": {
"method": "PASSWORD",
"username": "buddy",
"password": "$MyPassword"
}
}
],
"run_as_script": true,
"shell": "BASH",
"execute_every_command": false
}'
{
"url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/175688/actions/196743",
"html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/175688/action/196743/edit",
"id": 196743,
"name": "Execute commands on 5.75.234.250",
"type": "SSH_COMMAND",
"trigger_time": "ON_EVERY_EXECUTION",
"last_execution_status": "INITIAL",
"disabled": false,
"working_directory": "tests/SSH_Tests/",
"commands": [
"date >> tmp.log"
],
"targets": [
{
"type": "SSH",
"id": "vlatncuatc",
"host": "5.75.234.250",
"port": "22",
"auth": {
"method": "PASSWORD",
"username": "buddy",
"password": "secure!Fa+KZiUPt454/V0I/rzVow==.NTxejOG4XOsR8a5u8PLhVw=="
}
}
],
"pipeline": {
"url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/175688",
"html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/175688",
"id": 175688,
"name": "Test Docs",
"on": "EVENT",
"definition_source": "LOCAL",
"git_config_ref": "NONE",
"events": [
{
"type": "PUSH",
"refs": [
"refs/heads/master"
]
}
],
"priority": "NORMAL",
"disabled": false,
"last_execution_status": "INITIAL",
"always_from_scratch": false,
"ignore_fail_on_project_status": false,
"no_skip_to_most_recent": false,
"terminate_stale_runs": false,
"auto_clear_cache": false,
"fetch_all_refs": false,
"fail_on_prepare_env_warning": true,
"concurrent_pipeline_runs": false,
"do_not_create_commit_status": false,
"stale": false,
"waiting_for_push": false,
"resources": "DEFAULT",
"git_changeset_base": "LATEST_RUN",
"filesystem_changeset_base": "DATE_MODIFIED",
"cpu": "X86",
"description_required": false
},
"ignore_errors": false,
"run_as_script": true,
"shell": "BASH",
"run_next": "WAIT_ON_SUCCESS",
"execute_every_command": false
}