-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.drone.yml
102 lines (90 loc) · 2.77 KB
/
.drone.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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
pipeline:
fetch_tags:
when:
event: [push]
image: registry.usw.co/cloud/node-12-puppeteer:03228dd2d438979e8973ec16351c4d7bc88f552e
commands:
- git fetch --tags
publish-icons:
when:
event: push
branch: master
image: quay.io/uswitch/aws-cli:1.15.72
secrets: [ AWS_SECRET_ACCESS_KEY, AWS_ACCESS_KEY_ID ]
commands:
- "aws s3 cp --region eu-west-1 --recursive ./static/icons s3://trustyle-icons --cache-control max-age=604800 --metadata '{\"x-amz-meta-surrogate-control\": \"max-age=604800\"}' --acl=public-read"
install:
when:
event: [push]
image: registry.usw.co/cloud/node-12-puppeteer:03228dd2d438979e8973ec16351c4d7bc88f552e
commands:
- npm ci
- npx lerna bootstrap --no-ci
build-storybook:
when:
event: [push]
image: registry.usw.co/cloud/node-12-puppeteer:03228dd2d438979e8973ec16351c4d7bc88f552e
commands:
- npm run build-storybook
eslint:
when:
event: [push]
image: registry.usw.co/cloud/node-12-puppeteer:03228dd2d438979e8973ec16351c4d7bc88f552e
group: build-checks
commands:
- npm run eslint:check
prettier:
when:
event: [push]
image: registry.usw.co/cloud/node-12-puppeteer:03228dd2d438979e8973ec16351c4d7bc88f552e
group: build-checks
commands:
- npm run prettier:check
a11y:
when:
event: [push]
image: registry.usw.co/cloud/node-12-puppeteer:03228dd2d438979e8973ec16351c4d7bc88f552e
group: build-checks
commands:
- USE_STATIC_STORYBOOK=true npm run a11y
build:
when:
event: [push]
image: registry.usw.co/cloud/node-12-puppeteer:03228dd2d438979e8973ec16351c4d7bc88f552e
group: build-checks
commands:
- NODE_ENV=production npm run build
publish:
when:
branch: master
event: [push]
image: registry.usw.co/cloud/node-12-puppeteer:03228dd2d438979e8973ec16351c4d7bc88f552e
secrets: ['npm_token']
commands:
- npm config set '//registry.npmjs.org/:_authToken' $NPM_TOKEN
- npx lerna publish from-package --yes
send-percy-changed:
when:
event: [push]
branch:
exclude: master
image: registry.usw.co/cloud/node-12-puppeteer:03228dd2d438979e8973ec16351c4d7bc88f552e
secrets: [percy_token]
commands:
- npm run snapshot:changed
send-percy-all:
when:
event: [push]
branch: master
image: registry.usw.co/cloud/node-12-puppeteer:03228dd2d438979e8973ec16351c4d7bc88f552e
secrets: [percy_token]
commands:
- npm run snapshot
check-unpublished:
when:
event: [push]
branch: master
image: registry.usw.co/cloud/node-12-puppeteer:03228dd2d438979e8973ec16351c4d7bc88f552e
secrets: [slack_webhook]
commands:
- node ./scripts/slack-unpublished.js