Skip to content

Commit a4a1a31

Browse files
Switch deployment location (#359)
1 parent 0033426 commit a4a1a31

File tree

2 files changed

+25
-27
lines changed

2 files changed

+25
-27
lines changed

.github/workflows/pr-url.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: 'pr-url'
1+
name: "pr-url"
22
on:
33
pull_request:
44
types: [opened]
@@ -8,5 +8,5 @@ jobs:
88
steps:
99
- uses: microbit-foundation/action-pr-url-template@v0.1.2
1010
with:
11-
uri-template: 'https://review-ml.microbit.org/{branch}'
11+
uri-template: "https://review-createai.microbit.org/{branch}/"
1212
repo-token: ${{ secrets.GITHUB_TOKEN }}

deployment.cjs

Lines changed: 23 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,53 +1,51 @@
11
const {
22
createDeploymentDetailsFromOptions,
3-
} = require('@microbit-foundation/website-deploy-aws-config');
4-
const posixPath = require('path/posix');
3+
} = require("@microbit-foundation/website-deploy-aws-config");
54

65
const { s3Config } = createDeploymentDetailsFromOptions({
76
production: {
8-
bucket: 'ml.microbit.org',
9-
mode: 'root',
7+
bucket: "createai.microbit.org",
8+
mode: "root",
109
allowPrerelease: false,
1110
},
1211
staging: {
13-
bucket: 'stage-ml.microbit.org',
12+
bucket: "stage-createai.microbit.org",
1413
},
1514
review: {
16-
bucket: 'review-ml.microbit.org',
17-
mode: 'branch-prefix',
15+
bucket: "review-createai.microbit.org",
16+
mode: "branch-prefix",
1817
},
1918
});
2019

2120
module.exports = {
22-
deploymentDir: './dist',
21+
deploymentDir: "./dist",
2322
...s3Config,
24-
// For non-review versions deploy to the prototype URL
25-
bucketPrefix: s3Config.bucketPrefix ?? 'v/prototype',
26-
region: 'eu-west-1',
23+
region: "eu-west-1",
2724
removeNonexistentObjects: true,
2825
enableS3StaticWebsiteHosting: true,
29-
errorDocumentKey: 'index.html',
26+
errorDocumentKey: "index.html",
3027
redirects: [],
3128
params: {
32-
'**/**.html': {
33-
CacheControl: 'public, max-age=0, must-revalidate',
29+
"**/**.html": {
30+
CacheControl: "public, max-age=0, must-revalidate",
3431
},
35-
'**/assets/**': { CacheControl: 'public, max-age=31536000, immutable' },
32+
"**/assets/**": { CacheControl: "public, max-age=31536000, immutable" },
3633
// There's lots in public/ that we'd ideally use the bundler for to improve caching
37-
'css/**': {
38-
CacheControl: 'public, max-age=0, must-revalidate',
34+
// TODO: this might no longer be true, or at least be an easy fix
35+
"css/**": {
36+
CacheControl: "public, max-age=0, must-revalidate",
3937
},
40-
'firmware/**': {
41-
CacheControl: 'public, max-age=0, must-revalidate',
38+
"firmware/**": {
39+
CacheControl: "public, max-age=0, must-revalidate",
4240
},
43-
'imgs/**': {
44-
CacheControl: 'public, max-age=0, must-revalidate',
41+
"imgs/**": {
42+
CacheControl: "public, max-age=0, must-revalidate",
4543
},
46-
'sounds/**': {
47-
CacheControl: 'public, max-age=0, must-revalidate',
44+
"sounds/**": {
45+
CacheControl: "public, max-age=0, must-revalidate",
4846
},
49-
'webfonts/**': {
50-
CacheControl: 'public, max-age=0, must-revalidate',
47+
"webfonts/**": {
48+
CacheControl: "public, max-age=0, must-revalidate",
5149
},
5250
},
5351
};

0 commit comments

Comments
 (0)