initial commit

This commit is contained in:
Aleksander Cynarski 2020-08-24 23:28:02 +02:00
parent 1835fb7b2d
commit 3be2bf2e0b
2 changed files with 54 additions and 0 deletions

35
.drone.yml Normal file
View File

@ -0,0 +1,35 @@
kind: pipeline
name: default
steps:
- name: docker
image: plugins/docker
settings:
username:
from_secret: hub_username
password:
from_secret: hub_password
repo:
from_secret: hub_repo
tags: latest
when:
branch:
- master
- name: notify
image: appleboy/drone-telegram
settings:
token:
from_secret: telegram_bot_token
to:
from_secret: telegram_group_id
message: >
{{#success build.status}}
build {{build.link}} triggerd by {{commit.link}} from {{commit.author}} succeeded
{{else}}
build {{build.link}} triggerd by {{commit.link}} from {{commit.author}} failed
{{/success}}
when:
status:
- success
- failure

19
DOCKER_DEPLOY.md Normal file
View File

@ -0,0 +1,19 @@
# Drone docker deploy
## Użycie
```
cat ${args[0]} |awk -F\= '{system("drone secret add --repository='${args[1]}' --name="$1 " --data="$2)}'
```
Wymagane zmienne:
```
hub_username=
hub_password=
hub_repo=
telegram_bot_token=
telegram_group_id=
```