|
|
|
@ -1,25 +1,46 @@ |
|
|
|
|
--- |
|
|
|
|
kind: pipeline |
|
|
|
|
type: docker |
|
|
|
|
name: Test |
|
|
|
|
name: Building |
|
|
|
|
|
|
|
|
|
clone: |
|
|
|
|
disable: true |
|
|
|
|
|
|
|
|
|
# server: |
|
|
|
|
# host: 11.1.1.21 |
|
|
|
|
# user: tox |
|
|
|
|
# ssh_key: |
|
|
|
|
# from_secret: rsa_key |
|
|
|
|
|
|
|
|
|
steps: |
|
|
|
|
# - name: Show Environment |
|
|
|
|
# commands: |
|
|
|
|
# - whoami |
|
|
|
|
# - pwd |
|
|
|
|
# - hostname |
|
|
|
|
# - ls |
|
|
|
|
# - ls -lta ~/ |
|
|
|
|
- name: clone |
|
|
|
|
image: alpine/git |
|
|
|
|
extra_hosts: |
|
|
|
|
- "git.santic-zombie.ru:11.1.1.20" |
|
|
|
|
commands: |
|
|
|
|
- ping -c 1 git.santic-zombie.ru |
|
|
|
|
- git clone https://git.santic-zombie.ru/santic/tox-bot.git . |
|
|
|
|
- git checkout $DRONE_COMMIT |
|
|
|
|
- tar -czpf tox.tar.gz * |
|
|
|
|
|
|
|
|
|
- name: ssh |
|
|
|
|
image: appleboy/drone-ssh |
|
|
|
|
settings: |
|
|
|
|
host: |
|
|
|
|
- 11.1.1.21 |
|
|
|
|
username: tox |
|
|
|
|
key: |
|
|
|
|
from_secret: rsa_key |
|
|
|
|
port: 22 |
|
|
|
|
command_timeout: 2m |
|
|
|
|
script: |
|
|
|
|
- mkdir ~/tox_source |
|
|
|
|
|
|
|
|
|
- name: scp files |
|
|
|
|
image: appleboy/drone-scp |
|
|
|
|
settings: |
|
|
|
|
host: |
|
|
|
|
- 11.1.1.21 |
|
|
|
|
username: tox |
|
|
|
|
key: |
|
|
|
|
from_secret: rsa_key |
|
|
|
|
port: 22 |
|
|
|
|
target: ~/ |
|
|
|
|
source: tox.tar.gz |
|
|
|
|
|
|
|
|
|
- name: ssh |
|
|
|
|
image: appleboy/drone-ssh |
|
|
|
@ -35,6 +56,13 @@ steps: |
|
|
|
|
- echo "Hello World" |
|
|
|
|
- mkdir ~/test |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# server: |
|
|
|
|
# host: 11.1.1.21 |
|
|
|
|
# user: tox |
|
|
|
|
# ssh_key: |
|
|
|
|
# from_secret: rsa_key |
|
|
|
|
|
|
|
|
|
# - name: build |
|
|
|
|
# commands: |
|
|
|
|
# - cd src/ |
|
|
|
|