forked from codefresh-contrib/telegram-notifier
-
Notifications
You must be signed in to change notification settings - Fork 0
/
example.yml
36 lines (34 loc) · 1.37 KB
/
example.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
version: '1.0'
#...
steps:
#...
sendMessage:
image: codefreshplugins/telegramnotifier
environment:
- TELEGRAM_TOKEN=${{TOKEN}}
- TELEGRAM_TO=99999999
- TELEGRAM_MESSAGE=Hello {{{userLink}}}, how are you
- TELEGRAM_IMAGES=https://codefresh.io/docs/assets/brand/codefresh-social.png
# An example of a more advanced notification message:
#...
environment:
- "TELEGRAM_MESSAGE=buildTrigger: {{buildTrigger}}\nbuildInitiator: {{buildInitiator}}\nbuildId: {{buildId}}\nbuildTimestamp: {{buildTimestamp}}\nbuildUrl: {{buildUrl}}\nrepoOwner: {{repoOwner}}\nrepoName: {{repoName}}\nbranch: {{branch}}\nrevision: {{revision}}\ncommitAuthor: {{commitAuthor}}\ncommitUrl: {{commitUrl}}\ncommitMessage: {{commitMessage}}\nuserID: {{userID}}\nuserLink: {{{userLink}}}"
# or you could write it in a YAML literal block:
#...
environment:
- |-
TELEGRAM_MESSAGE=
buildTrigger: {{buildTrigger}}
buildInitiator: {{buildInitiator}}
buildId: {{buildId}}
buildTimestamp: {{buildTimestamp}}
buildUrl: {{buildUrl}}
repoOwner: {{repoOwner}}
repoName: {{repoName}}
branch: {{branch}}
revision: {{revision}}
commitAuthor: {{commitAuthor}}
commitUrl: {{commitUrl}}
commitMessage: {{commitMessage}}
userID: {{userID}}
userLink: {{{userLink}}}