drone-ci-testing/.drone.yml
2019-04-18 22:15:19 +02:00

58 lines
1.5 KiB
YAML

kind: pipeline
name: default
steps:
- name: test
image: alpine
environment:
MYUSERNAME:
from_secret: myusername
commands:
- echo "run env command"
- env
- name: publish
image: plugins/docker
settings:
repo: ruanbekker/dronetest
auto_tag: false
auto_tag_suffix: alpine
tags:
- ${DRONE_COMMIT}
- latest
username:
from_secret: dockerhub_username
password:
from_secret: dockerhub_password
- name: slack
image: plugins/slack
settings:
webhook:
from_secret: slack_webhook
channel: system_events
icon_url: https://www.pngkit.com/png/full/92-920674_drone-logo-png-transparent-drone-ci-logo.png
template: >
{{#success build.status}}
build {{build.number}} status: *{{build.status}}*
build link: {{build.link}}
build author: {{build.author}}
build ref: {{build.ref}}
build event: {{build.event}}
build commit: {{build.commit}}
build branch: {{build.branch}}
build deploy: {{build.deployTo}}
{{else}}
build {{build.number}} failed. Fix me please.
{{/success}}
- name: telegram
image: appleboy/drone-telegram
token: 387532308:AAExYuqjr5hjs4KdxeZQzoABU7tc1Nje7tc
to: 142714999
message: >
{{#success build.status}}
build {{build.number}} succeeded. Good job.
{{else}}
build {{build.number}} failed. Fix me please.
{{/success}}