Server

Use the server section to configure the remote ssh server. The runner connects to this server and executes pipeline commands using the ssh protocol.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
kind: pipeline
type: ssh
name: default

server:
  host: 1.2.3.4
  user: root
  password: correct-horse-battery-staple

steps:
- name: build
  commands:
  - go build
  - go test

Secrets

In the above example we hard-coded the server address and login credentials. For security reasons you should source these values from secrets.

 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
server:
  host:
    from_secret: host
  user:
    from_secret: username
  password:
    from_secret: password

steps:
- name: build
  commands:
  - go build
  - go test

SSH Keys

5
6
7
8
9
10
11
server:
  host:
    from_secret: host
  user:
    from_secret: username
  ssh_key:
    from_secret: ssh_key