-
Notifications
You must be signed in to change notification settings - Fork 23
90 lines (84 loc) · 3.35 KB
/
release.yaml
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
name: Release Build
on:
push:
branches:
- "release/**"
env:
# Creates and uploads sourcemaps to Rollbar, and save the built extension as an artifact
PUBLIC_RELEASE: true
jobs:
build-for-store:
runs-on: ubuntu-latest
env:
SOURCE_MAP_URL_BASE: https://pixiebrix-extension-source-maps.s3.amazonaws.com
SOURCE_MAP_PATH: sourcemaps/${{ github.job }}/${{ github.sha }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
with:
node-version-file: ".nvmrc"
cache: npm
- run: npm ci
- run: npm run build
env:
GOOGLE_APP_ID: ${{ secrets.GOOGLE_APP_ID }}
GOOGLE_API_KEY: ${{ secrets.GOOGLE_API_KEY }}
GOOGLE_OAUTH_CLIENT_ID: ${{ secrets.GOOGLE_OAUTH_CLIENT_ID }}
ROLLBAR_BROWSER_ACCESS_TOKEN: ${{ secrets.ROLLBAR_BROWSER_ACCESS_TOKEN }}
ROLLBAR_POST_SERVER_ITEM_TOKEN: ${{ secrets.ROLLBAR_POST_SERVER_ITEM_TOKEN }}
DATADOG_APPLICATION_ID: ${{ secrets.DATADOG_APPLICATION_ID }}
DATADOG_CLIENT_TOKEN: ${{ secrets.DATADOG_CLIENT_TOKEN }}
- run: bash scripts/upload-sourcemaps.sh
env:
AWS_ACCESS_KEY_ID: ${{ secrets.SOURCEMAP_USER_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.SOURCEMAP_USER_KEY }}
AWS_DEFAULT_REGION: "us-east-2"
ROLLBAR_POST_SERVER_ITEM_TOKEN: ${{ secrets.ROLLBAR_POST_SERVER_ITEM_TOKEN }}
- name: Save extension
uses: ./.github/actions/upload-zipped-artifact
with:
name: build-for-store
directory: dist
exclusions: "*.map"
retention-days: 5
build:
runs-on: ubuntu-latest
env:
SOURCE_MAP_URL_BASE: https://pixiebrix-extension-source-maps.s3.amazonaws.com
SOURCE_MAP_PATH: sourcemaps/${{ github.job }}/${{ github.sha }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
with:
node-version-file: ".nvmrc"
cache: npm
- run: npm ci
- run: npm run build
env:
GOOGLE_APP_ID: ${{ secrets.GOOGLE_APP_ID }}
GOOGLE_API_KEY: ${{ secrets.GOOGLE_API_KEY }}
GOOGLE_OAUTH_CLIENT_ID: ${{ secrets.GOOGLE_OAUTH_CLIENT_ID }}
ROLLBAR_BROWSER_ACCESS_TOKEN: ${{ secrets.ROLLBAR_BROWSER_ACCESS_TOKEN }}
ROLLBAR_POST_SERVER_ITEM_TOKEN: ${{ secrets.ROLLBAR_POST_SERVER_ITEM_TOKEN }}
CHROME_MANIFEST_KEY: ${{ secrets.CHROME_MANIFEST_PROD_PUBLIC_KEY }}
DATADOG_APPLICATION_ID: ${{ secrets.DATADOG_APPLICATION_ID }}
DATADOG_CLIENT_TOKEN: ${{ secrets.DATADOG_CLIENT_TOKEN }}
- run: bash scripts/upload-sourcemaps.sh
env:
AWS_ACCESS_KEY_ID: ${{ secrets.SOURCEMAP_USER_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.SOURCEMAP_USER_KEY }}
AWS_DEFAULT_REGION: "us-east-2"
ROLLBAR_POST_SERVER_ITEM_TOKEN: ${{ secrets.ROLLBAR_POST_SERVER_ITEM_TOKEN }}
- name: Save extension
uses: ./.github/actions/upload-zipped-artifact
with:
name: build-production
directory: dist
exclusions: "*.map"
retention-days: 5
- name: Slack Notification
uses: rtCamp/action-slack-notify@v2
env:
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
SLACK_CHANNEL: "release-notifications"
SLACK_MESSAGE: "Chrome release build succeeded :rocket:"