-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathbuildspec.yml
More file actions
30 lines (30 loc) · 788 Bytes
/
buildspec.yml
File metadata and controls
30 lines (30 loc) · 788 Bytes
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
version: 0.2
env:
variables:
S3_BUCKET: "mynoddu"
phases:
install:
runtime-versions:
nodejs: 18
pre_build:
commands:
- echo Installing source NPM dependencies...
- npm install
#- npm install --legacy-peer-deps
- npm install -g @angular/cli
build:
commands:
- echo Build started on date
- ng build
#- ng build --configuration production --aot
post_build:
commands:
- aws s3 sync dist/angular-hello-world/ s3://${S3_BUCKET}
- echo "Build completed on date"
- aws s3 website s3://${S3_BUCKET} --index-document index.html
- aws cloudfront create-invalidation --distribution-id E3GJ5I5L4TT6GM --paths '/*'
artifacts:
files:
- '**/*'
base-directory: 'dist*'
discard-paths: yes