You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .github/workflows/notify-about-deployment.yml
+232Lines changed: 232 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -4,13 +4,245 @@ name: Notify about production deployment
4
4
# **Why we have it**: So that the PR author can be informed when their merged PR is in production.
5
5
# **Who does it impact**: Writers
6
6
7
+
jobs:
8
+
test:
9
+
name: Test on node ${{ matrix.node_version }} and ${{ matrix.os }}
10
+
runs-on: ${{ matrix.os }}
11
+
strategy:
12
+
matrix:
13
+
node_version: ['18.x', '20.x']
14
+
os: [ubuntu-latest, windows-latest, macOS-latest]
15
+
16
+
steps:
17
+
- uses: actions/checkout@v4
18
+
- name: Use Node.js ${{ matrix.node_version }}
19
+
uses: actions/setup-node@v4
20
+
with:
21
+
node-version: ${{ matrix.node_version }}
22
+
23
+
- name: npm install, build and test
24
+
run: |
25
+
npm install
26
+
npm run build --if-present
27
+
npm test
28
+
29
+
- name: Setup Node.js environment
30
+
uses: actions/setup-node@v3.9.1
31
+
with:
32
+
# Set always-auth in npmrc.
33
+
always-auth: # optional, default is false
34
+
# Version Spec of the version to use. Examples: 12.x, 10.15.1, >=10.15.0.
35
+
node-version: # optional
36
+
# File containing the version Spec of the version to use. Examples: .nvmrc, .node-version, .tool-versions.
37
+
node-version-file: # optional
38
+
# Target architecture for Node to use. Examples: x86, x64. Will use system architecture by default.
39
+
architecture: # optional
40
+
# Set this option if you want the action to check for the latest available version that satisfies the version spec.
41
+
check-latest: # optional
42
+
# Optional registry to set up for auth. Will set the registry in a project level .npmrc and .yarnrc file, and set up auth to read in from env.NODE_AUTH_TOKEN.
43
+
registry-url: # optional
44
+
# Optional scope for authenticating against scoped registries. Will fall back to the repository owner when using the GitHub Packages registry (https://npm.pkg.github.com/).
45
+
scope: # optional
46
+
# Used to pull node distributions from node-versions. Since there's a default, this is typically not supplied by the user. When running this action on github.com, the default value is sufficient. When running on GHES, you can pass a personal access token for github.com if you are experiencing rate limiting.
# Used to specify a package manager for caching in the default directory. Supported values: npm, yarn, pnpm.
49
+
cache: # optional
50
+
# Used to specify the path to a dependency file: package-lock.json, yarn.lock, etc. Supports wildcards or a list of file names for caching multiple dependencies.
51
+
cache-dependency-path: # optional
52
+
53
+
7
54
on:
8
55
workflow_dispatch:
9
56
workflow_run:
10
57
workflows: ['Purge Fastly']
11
58
types:
12
59
- completed
13
60
61
+
- name: Close Stale Issues
62
+
uses: actions/stale@v9.1.0
63
+
with:
64
+
# Token for the repository. Can be passed in using `{{ secrets.GITHUB_TOKEN }}`.
65
+
repo-token: # optional, default is ${{ github.token }}
66
+
# The message to post on the issue when tagging it. If none provided, will not mark issues stale.
67
+
stale-issue-message: # optional
68
+
# The message to post on the pull request when tagging it. If none provided, will not mark pull requests stale.
69
+
stale-pr-message: # optional
70
+
# The message to post on the issue when closing it. If none provided, will not comment when closing an issue.
71
+
close-issue-message: # optional
72
+
# The message to post on the pull request when closing it. If none provided, will not comment when closing a pull requests.
73
+
close-pr-message: # optional
74
+
# The number of days old an issue or a pull request can be before marking it stale. Set to -1 to never mark issues or pull requests as stale automatically.
75
+
days-before-stale: # optional, default is 60
76
+
# The number of days old an issue can be before marking it stale. Set to -1 to never mark issues as stale automatically. Override "days-before-stale" option regarding only the issues.
77
+
days-before-issue-stale: # optional
78
+
# The number of days old a pull request can be before marking it stale. Set to -1 to never mark pull requests as stale automatically. Override "days-before-stale" option regarding only the pull requests.
79
+
days-before-pr-stale: # optional
80
+
# The number of days to wait to close an issue or a pull request after it being marked stale. Set to -1 to never close stale issues or pull requests.
81
+
days-before-close: # optional, default is 7
82
+
# The number of days to wait to close an issue after it being marked stale. Set to -1 to never close stale issues. Override "days-before-close" option regarding only the issues.
83
+
days-before-issue-close: # optional
84
+
# The number of days to wait to close a pull request after it being marked stale. Set to -1 to never close stale pull requests. Override "days-before-close" option regarding only the pull requests.
85
+
days-before-pr-close: # optional
86
+
# The label to apply when an issue is stale.
87
+
stale-issue-label: # optional, default is Stale
88
+
# The label to apply when an issue is closed.
89
+
close-issue-label: # optional
90
+
# The labels that mean an issue is exempt from being marked stale. Separate multiple labels with commas (eg. "label1,label2").
91
+
exempt-issue-labels: # optional, default is
92
+
# The reason to use when closing an issue.
93
+
close-issue-reason: # optional, default is not_planned
94
+
# The label to apply when a pull request is stale.
95
+
stale-pr-label: # optional, default is Stale
96
+
# The label to apply when a pull request is closed.
97
+
close-pr-label: # optional
98
+
# The labels that mean a pull request is exempt from being marked as stale. Separate multiple labels with commas (eg. "label1,label2").
99
+
exempt-pr-labels: # optional, default is
100
+
# The milestones that mean an issue or a pull request is exempt from being marked as stale. Separate multiple milestones with commas (eg. "milestone1,milestone2").
101
+
exempt-milestones: # optional, default is
102
+
# The milestones that mean an issue is exempt from being marked as stale. Separate multiple milestones with commas (eg. "milestone1,milestone2"). Override "exempt-milestones" option regarding only the issues.
103
+
exempt-issue-milestones: # optional, default is
104
+
# The milestones that mean a pull request is exempt from being marked as stale. Separate multiple milestones with commas (eg. "milestone1,milestone2"). Override "exempt-milestones" option regarding only the pull requests.
105
+
exempt-pr-milestones: # optional, default is
106
+
# Exempt all issues and pull requests with milestones from being marked as stale. Default to false.
107
+
exempt-all-milestones: # optional, default is false
108
+
# Exempt all issues with milestones from being marked as stale. Override "exempt-all-milestones" option regarding only the issues.
109
+
exempt-all-issue-milestones: # optional, default is
110
+
# Exempt all pull requests with milestones from being marked as stale. Override "exempt-all-milestones" option regarding only the pull requests.
111
+
exempt-all-pr-milestones: # optional, default is
112
+
# Only issues or pull requests with all of these labels are checked if stale. Defaults to `` (disabled) and can be a comma-separated list of labels.
113
+
only-labels: # optional, default is
114
+
# Only issues or pull requests with at least one of these labels are checked if stale. Defaults to `` (disabled) and can be a comma-separated list of labels.
115
+
any-of-labels: # optional, default is
116
+
# Only issues with at least one of these labels are checked if stale. Defaults to `` (disabled) and can be a comma-separated list of labels. Override "any-of-labels" option regarding only the issues.
117
+
any-of-issue-labels: # optional, default is
118
+
# Only pull requests with at least one of these labels are checked if stale. Defaults to `` (disabled) and can be a comma-separated list of labels. Override "any-of-labels" option regarding only the pull requests.
119
+
any-of-pr-labels: # optional, default is
120
+
# Only issues with all of these labels are checked if stale. Defaults to `[]` (disabled) and can be a comma-separated list of labels. Override "only-labels" option regarding only the issues.
121
+
only-issue-labels: # optional, default is
122
+
# Only pull requests with all of these labels are checked if stale. Defaults to `[]` (disabled) and can be a comma-separated list of labels. Override "only-labels" option regarding only the pull requests.
123
+
only-pr-labels: # optional, default is
124
+
# The maximum number of operations per run, used to control rate limiting (GitHub API CRUD related).
125
+
operations-per-run: # optional, default is 30
126
+
# Remove stale labels from issues and pull requests when they are updated or commented on.
127
+
remove-stale-when-updated: # optional, default is true
128
+
# Remove stale labels from issues when they are updated or commented on. Override "remove-stale-when-updated" option regarding only the issues.
129
+
remove-issue-stale-when-updated: # optional, default is
130
+
# Remove stale labels from pull requests when they are updated or commented on. Override "remove-stale-when-updated" option regarding only the pull requests.
131
+
remove-pr-stale-when-updated: # optional, default is
132
+
# Run the processor in debug mode without actually performing any operations on live issues.
133
+
debug-only: # optional, default is false
134
+
# The order to get issues or pull requests. Defaults to false, which is descending.
135
+
ascending: # optional, default is false
136
+
# Delete the git branch after closing a stale pull request.
137
+
delete-branch: # optional, default is false
138
+
# The date used to skip the stale action on issue/pull request created before it (ISO 8601 or RFC 2822).
139
+
start-date: # optional, default is
140
+
# The assignees which exempt an issue or a pull request from being marked as stale. Separate multiple assignees with commas (eg. "user1,user2").
141
+
exempt-assignees: # optional, default is
142
+
# The assignees which exempt an issue from being marked as stale. Separate multiple assignees with commas (eg. "user1,user2"). Override "exempt-assignees" option regarding only the issues.
143
+
exempt-issue-assignees: # optional, default is
144
+
# The assignees which exempt a pull request from being marked as stale. Separate multiple assignees with commas (eg. "user1,user2"). Override "exempt-assignees" option regarding only the pull requests.
145
+
exempt-pr-assignees: # optional, default is
146
+
# Exempt all issues and pull requests with assignees from being marked as stale. Default to false.
147
+
exempt-all-assignees: # optional, default is false
148
+
# Exempt all issues with assignees from being marked as stale. Override "exempt-all-assignees" option regarding only the issues.
149
+
exempt-all-issue-assignees: # optional, default is
150
+
# Exempt all pull requests with assignees from being marked as stale. Override "exempt-all-assignees" option regarding only the pull requests.
151
+
exempt-all-pr-assignees: # optional, default is
152
+
# Exempt draft pull requests from being marked as stale. Default to false.
153
+
exempt-draft-pr: # optional, default is false
154
+
# Display some statistics at the end regarding the stale workflow (only when the logs are enabled).
155
+
enable-statistics: # optional, default is true
156
+
# A comma delimited list of labels to add when an issue or pull request becomes unstale.
157
+
labels-to-add-when-unstale: # optional, default is
158
+
# A comma delimited list of labels to remove when an issue or pull request becomes stale.
159
+
labels-to-remove-when-stale: # optional, default is
160
+
# A comma delimited list of labels to remove when an issue or pull request becomes unstale.
161
+
labels-to-remove-when-unstale: # optional, default is
162
+
# Any update (update/comment) can reset the stale idle time on the issues and pull requests.
163
+
ignore-updates: # optional, default is false
164
+
# Any update (update/comment) can reset the stale idle time on the issues. Override "ignore-updates" option regarding only the issues.
165
+
ignore-issue-updates: # optional, default is
166
+
# Any update (update/comment) can reset the stale idle time on the pull requests. Override "ignore-updates" option regarding only the pull requests.
167
+
ignore-pr-updates: # optional, default is
168
+
# Only the issues or the pull requests with an assignee will be marked as stale automatically.
169
+
include-only-assigned: # optional, default is false
170
+
171
+
- name: Cache
172
+
uses: actions/cache@v4.2.3
173
+
with:
174
+
# A list of files, directories, and wildcard patterns to cache and restore
175
+
path:
176
+
# An explicit key for restoring and saving the cache
177
+
key:
178
+
# An ordered multiline string listing the prefix-matched keys, that are used for restoring stale cache if no cache hit occurred for key. Note `cache-hit` returns false in this case.
179
+
restore-keys: # optional
180
+
# The chunk size used to split up large files during upload, in bytes
181
+
upload-chunk-size: # optional
182
+
# An optional boolean when enabled, allows windows runners to save or restore caches that can be restored or saved respectively on other platforms
183
+
enableCrossOsArchive: # optional, default is false
184
+
# Fail the workflow if cache entry is not found
185
+
fail-on-cache-miss: # optional, default is false
186
+
# Check if a cache entry exists for the given input(s) (key, restore-keys) without downloading the cache
187
+
lookup-only: # optional, default is false
188
+
# Run the post step to save the cache even if another step before fails
# weight multiplier for labels (negative to exclude)
211
+
multiplier_labels: # default is example:-1 epic:0.142857 blocked:0.142857 invalid:0.142857
212
+
# largest pN-label (lowest priority)
213
+
p_label_graveyard: # default is 4
214
+
# URL to post slack payload to (requires `people.json`)
215
+
slack_webhook: # optional
216
+
217
+
218
+
- name: Upload a Build Artifact
219
+
uses: actions/upload-artifact@v4.6.2
220
+
with:
221
+
# Artifact name
222
+
name: # optional, default is artifact
223
+
# A file, directory or wildcard pattern that describes what to upload
224
+
path:
225
+
# The desired behavior if no files are found using the provided path.
226
+
Available Options:
227
+
warn: Output a warning but do not fail the action
228
+
error: Fail the action with an error message
229
+
ignore: Do not output any warnings or errors, the action does not fail
230
+
231
+
if-no-files-found: # optional, default is warn
232
+
# Duration after which artifact will expire in days. 0 means using default retention.
233
+
Minimum 1 day. Maximum 90 days unless changed from the repository settings page.
234
+
235
+
retention-days: # optional
236
+
# The level of compression for Zlib to be applied to the artifact archive. The value can range from 0 to 9: - 0: No compression - 1: Best speed - 6: Default compression (same as GNU Gzip) - 9: Best compression Higher levels will result in better compression, but will take longer to complete. For large files that are not easily compressed, a value of 0 is recommended for significantly faster uploads.
237
+
238
+
compression-level: # optional, default is 6
239
+
# If true, an artifact with a matching name will be deleted before a new one is uploaded. If false, the action will fail if an artifact for the given name already exists. Does not fail if the artifact does not exist.
240
+
241
+
overwrite: # optional, default is false
242
+
# If true, hidden files will be included in the artifact. If false, hidden files will be excluded from the artifact.
243
+
244
+
include-hidden-files: # optional, default is false
0 commit comments