forked from SPARCS-UP-Mindanao/TechTix
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathamplify.yml
More file actions
34 lines (33 loc) · 906 Bytes
/
amplify.yml
File metadata and controls
34 lines (33 loc) · 906 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
31
32
33
34
version: 1
applications:
- frontend:
phases:
preBuild:
commands:
- npm ci --cache .npm --prefer-offline
- |
if [ "$AWS_BRANCH" = "dev" ]; then
STAGE=dev
elif [ "$AWS_BRANCH" = "stage" ]; then
STAGE=staging
elif [ "$AWS_BRANCH" = "main" ]; then
STAGE=prod
else
STAGE=dev
fi
echo "Using STAGE=$STAGE (branch=$AWS_BRANCH, region=$AWS_REGION)"
npm run generate "$STAGE" --region "$AWS_REGION"
build:
commands:
- npm run build
artifacts:
baseDirectory: dist
files:
- "**/*"
cache:
paths:
- ".npm/**/*"
- node_modules/**/*
runtime-versions:
nodejs: 22.15
appRoot: frontend