-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuildspec.yml
46 lines (41 loc) · 1.24 KB
/
buildspec.yml
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
35
36
37
38
39
40
41
42
43
44
45
46
version: 0.2
phases:
install:
commands:
- "which ssh-agent"
pre_build:
commands:
- aws --version
- git --version
# Base parameters - for debugging purposes and env vars use in scripts and config.
- bash build_parameters
# Lock npm to v6
- npm install -g [email protected]
- npm install -g semver
# A weird issue that appears in CodeBuild is that there is no mkdirp, whereas this is
# fine on local development. So it is included here rather than the package.json
- npm install [email protected]
- npm install --ignore-scripts --only=development
- npm install --ignore-scripts --only=production
# Sets up the product site scripts and styles
- composer install
build:
commands:
- mv config/robots.${CORONAFRIEND_ENVIRONMENT}.txt config/robots.txt
- mv config/site-nginx.${CORONAFRIEND_ENVIRONMENT}.conf config/00-${CORONAFRIEND_DOMAIN}.conf
- mv config/site-index.html config/${CORONAFRIEND_DOMAIN}.html
post_build:
commands:
- echo Build completed on `date`
artifacts:
files:
- appspec.yml
- src/**/*
- public/**/*
- logs/**/*
- config/**/*
- scripts/**/*
- vendor/**/*
cache:
paths:
- "/root/.npm/**/*"