Skip to content

Commit 5b5ab24

Browse files
committed
Merge remote-tracking branch 'upstream/dev' into pr/acusti/11854
2 parents af8b5fa + a25ec17 commit 5b5ab24

File tree

1,036 files changed

+33113
-27418
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,036 files changed

+33113
-27418
lines changed

.circleci/config.base.yml

Lines changed: 60 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ parameters:
1616
executors:
1717
w_medium: &windows-e2e-executor-medium
1818
machine:
19-
image: 'windows-server-2019-vs2019:stable'
19+
image: 'windows-server-2022-gui:current'
2020
resource_class: 'windows.medium'
2121
shell: bash.exe
2222
working_directory: ~/repo
@@ -26,7 +26,7 @@ executors:
2626

2727
w_xlarge: &windows-e2e-executor-xlarge
2828
machine:
29-
image: 'windows-server-2019-vs2019:stable'
29+
image: 'windows-server-2022-gui:current'
3030
resource_class: 'windows.xlarge'
3131
shell: bash.exe
3232
working_directory: ~/repo
@@ -35,7 +35,7 @@ executors:
3535
AMPLIFY_PATH: C:/home/circleci/repo/out/amplify.exe
3636
l_xlarge: &linux-e2e-executor-xlarge
3737
docker:
38-
- image: public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:latest
38+
- image: public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:node18
3939
working_directory: ~/repo
4040
resource_class: xlarge
4141
environment:
@@ -44,7 +44,7 @@ executors:
4444
# If you update this name, make sure to update it in split-e2e-tests.ts as well
4545
l_large: &linux-e2e-executor-large
4646
docker:
47-
- image: public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:latest
47+
- image: public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:node18
4848
working_directory: ~/repo
4949
resource_class: large
5050
environment:
@@ -53,7 +53,7 @@ executors:
5353
# If you update this name, make sure to update it in split-e2e-tests.ts as well
5454
l_medium: &linux-e2e-executor-medium
5555
docker:
56-
- image: public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:latest
56+
- image: public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:node18
5757
working_directory: ~/repo
5858
resource_class: medium
5959
environment:
@@ -135,7 +135,7 @@ jobs:
135135
- checkout
136136
- run: yarn config set registry https://registry.npmjs.org
137137
- run: yarn config set script-shell $(which bash)
138-
- run: yarn install
138+
- run: yarn install --network-concurrency 1
139139
- run:
140140
name: Build tests
141141
command: yarn build-tests
@@ -150,7 +150,7 @@ jobs:
150150
condition:
151151
equal: [*windows-e2e-executor-xlarge, << parameters.os >>]
152152
steps:
153-
- install_node14_windows
153+
- install_node_windows
154154
- checkout
155155
- run: yarn config set script-shell $(which bash)
156156
- run: yarn run production-build
@@ -177,7 +177,7 @@ jobs:
177177
name: Collect code coverage
178178
command: yarn coverage
179179
environment:
180-
NODE_OPTIONS: --max-old-space-size=4096
180+
NODE_OPTIONS: --max-old-space-size=5120
181181

182182
validate_cdk_version:
183183
<<: *linux-e2e-executor-medium
@@ -201,6 +201,8 @@ jobs:
201201
- run: yarn lint-check
202202
- run: yarn lint-check-package-json
203203
- run: yarn prettier-check
204+
environment:
205+
NODE_OPTIONS: --max-old-space-size=5120
204206

205207
verify-api-extract:
206208
<<: *linux-e2e-executor-xlarge
@@ -347,6 +349,8 @@ jobs:
347349
key: amplify-pkg-binaries-linux-{{ .Branch }}-{{ .Revision }}
348350
paths:
349351
- ~/repo/out
352+
- store_artifacts:
353+
path: ~/repo/out
350354

351355
build_pkg_binaries_macos:
352356
<<: *linux-e2e-executor-large
@@ -370,6 +374,8 @@ jobs:
370374
key: amplify-pkg-binaries-macos-{{ .Branch }}-{{ .Revision }}
371375
paths:
372376
- ~/repo/out
377+
- store_artifacts:
378+
path: ~/repo/out
373379

374380
build_pkg_binaries_win:
375381
<<: *linux-e2e-executor-large
@@ -393,6 +399,8 @@ jobs:
393399
key: amplify-pkg-binaries-win-{{ .Branch }}-{{ .Revision }}
394400
paths:
395401
- ~/repo/out
402+
- store_artifacts:
403+
path: ~/repo/out
396404

397405
build_pkg_binaries_arm:
398406
<<: *linux-e2e-executor-large
@@ -416,6 +424,8 @@ jobs:
416424
key: amplify-pkg-binaries-arm-{{ .Branch }}-{{ .Revision }}
417425
paths:
418426
- ~/repo/out
427+
- store_artifacts:
428+
path: ~/repo/out
419429

420430
verify_pkg_binaries:
421431
<<: *linux-e2e-executor-large
@@ -445,9 +455,6 @@ jobs:
445455
key: amplify-verdaccio-cache-{{ .Branch }}-{{ .Revision }}
446456
- restore_cache:
447457
key: amplify-pkg-binaries-{{ .Branch }}-{{ .Revision }}
448-
- run:
449-
name: Update OS Packages
450-
command: sudo apt-get update
451458
- run:
452459
name: Start verdaccio and Install Amplify CLI as sudo
453460
command: |
@@ -459,6 +466,30 @@ jobs:
459466
unsetSudoNpmRegistryUrl
460467
amplify version
461468
469+
amplify_install_test:
470+
<<: *defaults
471+
steps:
472+
- restore_cache:
473+
key: amplify-cli-repo-{{ .Branch }}-{{ .Revision }}
474+
- restore_cache:
475+
key: amplify-verdaccio-cache-{{ .Branch }}-{{ .Revision }}
476+
- restore_cache:
477+
key: amplify-pkg-binaries-{{ .Branch }}-{{ .Revision }}
478+
- run:
479+
name: Start verdaccio and Install Amplify CLI
480+
command: |
481+
source .circleci/local_publish_helpers.sh
482+
startLocalRegistry "$(pwd)/.circleci/verdaccio.yaml"
483+
setNpmRegistryUrlToLocal
484+
changeNpmGlobalPath
485+
# limit memory for new processes to 1GB
486+
# this is to make sure that install can work on small VMs
487+
# i.e. not buffer content in memory while installing binary
488+
ulimit -Sv 1000000
489+
npm install -g @aws-amplify/cli
490+
unsetNpmRegistryUrl
491+
amplify version
492+
462493
amplify_e2e_tests_pkg:
463494
parameters:
464495
os:
@@ -471,7 +502,7 @@ jobs:
471502
condition:
472503
equal: [*windows-e2e-executor-medium, << parameters.os >>]
473504
steps:
474-
- install_node14_windows
505+
- install_node_windows
475506
- attach_workspace:
476507
at: ~/.
477508
- run:
@@ -989,7 +1020,6 @@ workflows:
9891020
- beta
9901021
- release
9911022
- /release_rc\/.*/
992-
- /tagged-release-without-e2e-tests\/.*/
9931023
- /run-e2e\/.*/
9941024
- verify-api-extract:
9951025
requires:
@@ -1093,6 +1123,17 @@ workflows:
10931123
- /run-e2e-with-rc\/.*/
10941124
- /tagged-release\/.*/
10951125
- /run-e2e\/.*/
1126+
- amplify_install_test:
1127+
context: amplify-ecr-image-pull
1128+
requires:
1129+
- upload_pkg_binaries
1130+
filters:
1131+
branches:
1132+
only:
1133+
- dev
1134+
- /run-e2e-with-rc\/.*/
1135+
- /tagged-release\/.*/
1136+
- /run-e2e\/.*/
10961137
- cleanup_resources:
10971138
context:
10981139
- cleanup-resources
@@ -1271,6 +1312,7 @@ workflows:
12711312
- integration_test
12721313
- amplify_e2e_tests_pkg
12731314
- amplify_sudo_install_test
1315+
- amplify_install_test
12741316
- amplify_console_integration_tests
12751317
- amplify_migration_tests_v10
12761318
- amplify_migration_tests_v6
@@ -1413,15 +1455,15 @@ commands:
14131455
exit 1
14141456
fi
14151457
when: always
1416-
install_node14_windows:
1417-
description: Install Node 14 on Windows
1458+
install_node_windows:
1459+
description: Install Node 18 on Windows
14181460
steps:
14191461
- run:
1420-
name: Install Node 14
1462+
name: Install Node 18
14211463
command: |
14221464
nvm version
1423-
nvm install 14.18
1424-
nvm use 14.18
1465+
nvm install 18.15.0
1466+
nvm use 18.15.0
14251467
nvm ls
14261468
- run:
14271469
name: Check Node, install yarn

.circleci/config.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,15 +27,15 @@ parameters:
2727
executors:
2828
l_large: &linux-e2e-executor-large
2929
docker:
30-
- image: public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:latest
30+
- image: public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:node18
3131
working_directory: ~/repo
3232
resource_class: large
3333
environment:
3434
AMPLIFY_DIR: /home/circleci/repo/out
3535
AMPLIFY_PATH: /home/circleci/repo/out/amplify-pkg-linux-x64
3636
l_xlarge: &linux-e2e-executor-xlarge
3737
docker:
38-
- image: public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:latest
38+
- image: public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:node18
3939
working_directory: ~/repo
4040
resource_class: xlarge
4141
environment:
@@ -82,7 +82,7 @@ jobs:
8282
equal:
8383
- docker:
8484
- image: >-
85-
public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:latest
85+
public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:node18
8686
working_directory: ~/repo
8787
resource_class: xlarge
8888
environment:
@@ -95,7 +95,7 @@ jobs:
9595
paths: .
9696
publish_to_local_registry:
9797
docker:
98-
- image: public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:latest
98+
- image: public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:node18
9999
working_directory: ~/repo
100100
resource_class: large
101101
environment:
@@ -186,7 +186,7 @@ jobs:
186186
~/repo/packages/amplify-console-integration-tests/console-integration-reports
187187
cleanup_resources:
188188
docker:
189-
- image: public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:latest
189+
- image: public.ecr.aws/j4f5f3h7/amplify-cli-e2e-base-image-repo-public:node18
190190
working_directory: ~/repo
191191
resource_class: large
192192
environment:

.circleci/local_publish_helpers.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -80,22 +80,22 @@ function generatePkgCli {
8080
cp package.json ../build/node_modules/package.json
8181

8282
if [[ "$@" =~ 'arm' ]]; then
83-
npx pkg --no-bytecode --public-packages "*" --public -t node14-linux-arm64 ../build/node_modules -o ../out/amplify-pkg-linux-arm64
83+
npx pkg --no-bytecode --public-packages "*" --public -t node18-linux-arm64 ../build/node_modules -o ../out/amplify-pkg-linux-arm64
8484
tar -czvf ../out/amplify-pkg-linux-arm64.tgz ../out/amplify-pkg-linux-arm64
8585
fi
8686

8787
if [[ "$@" =~ 'linux' ]]; then
88-
npx pkg -t node14-linux-x64 ../build/node_modules -o ../out/amplify-pkg-linux-x64
88+
npx pkg -t node18-linux-x64 ../build/node_modules -o ../out/amplify-pkg-linux-x64
8989
tar -czvf ../out/amplify-pkg-linux-x64.tgz ../out/amplify-pkg-linux-x64
9090
fi
9191

9292
if [[ "$@" =~ 'macos' ]]; then
93-
npx pkg -t node14-macos-x64 ../build/node_modules -o ../out/amplify-pkg-macos-x64
93+
npx pkg -t node18-macos-x64 ../build/node_modules -o ../out/amplify-pkg-macos-x64
9494
tar -czvf ../out/amplify-pkg-macos-x64.tgz ../out/amplify-pkg-macos-x64
9595
fi
9696

9797
if [[ "$@" =~ 'win' ]]; then
98-
npx pkg -t node14-win-x64 ../build/node_modules -o ../out/amplify-pkg-win-x64.exe
98+
npx pkg -t node18-win-x64 ../build/node_modules -o ../out/amplify-pkg-win-x64.exe
9999
tar -czvf ../out/amplify-pkg-win-x64.tgz ../out/amplify-pkg-win-x64.exe
100100
fi
101101

.eslint-dictionary.json

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -124,8 +124,6 @@
124124
"doctype",
125125
"dotenv",
126126
"dotnet",
127-
"dotnetcore3",
128-
"dotnetcore31",
129127
"durations",
130128
"dynamodb",
131129
"ecluster",

.eslintrc.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ module.exports = {
3838
},
3939
},
4040
rules: {
41+
'@typescript-eslint/switch-exhaustiveness-check': 'error',
4142
'@typescript-eslint/no-var-requires': 'off',
4243
'@typescript-eslint/no-floating-promises': 'error',
4344
'@typescript-eslint/no-misused-promises': 'error',

.vscode/settings.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,6 @@
1515
},
1616
"prettier.requireConfig": true,
1717
"prettier.configPath": "./.prettierrc",
18-
"prettier.prettierPath": "../node_modules/prettier"
18+
"prettier.prettierPath": "../node_modules/prettier",
19+
"jest.jestCommandLine": "./node_modules/.bin/jest"
1920
}

0 commit comments

Comments
 (0)