-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbitbucket-pipelines.yml
63 lines (62 loc) · 2.49 KB
/
bitbucket-pipelines.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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
# This is a sample build configuration for JavaScript.
# Check our guides at https://confluence.atlassian.com/x/14UWN for more examples.
# Only use spaces to indent your .yml configuration.
# -----
# You can specify a custom docker image from Docker Hub as your build environment.
image: node:10.15.3
pipelines:
branches:
staging:
- step:
name: Deploy
deployment: staging
script:
- apt-get update
- apt-get install -y zip
- npm install
- npm run build
- cp -r scripts/* build/
- cp appspec.yml build/appspec.yml
- zip -rq gl-management-portal.zip *
- echo REACT_APP_API_URL = $REACT_APP_API_URL_ST
- echo REACT_APP_LOGO_URL = $REACT_APP_LOGO_URL
- pipe: atlassian/aws-code-deploy:0.5.2
variables:
COMMAND: 'upload'
APPLICATION_NAME: 'portal.staging.gerberlabs.com'
DEPLOYMENT_GROUP: 'portal.staging.gerberlabs.com'
S3_BUCKET: 'portal.staging.gerberlabs.com'
ZIP_FILE: 'gl-management-portal.zip'
- pipe: atlassian/aws-code-deploy:0.5.2
variables:
COMMAND: 'deploy'
APPLICATION_NAME: 'portal.staging.gerberlabs.com'
DEPLOYMENT_GROUP: 'portal.staging.gerberlabs.com'
S3_BUCKET: 'portal.staging.gerberlabs.com'
master:
- step:
name: Deploy
deployment: production
script:
- apt-get update
- apt-get install -y zip
- npm install
- npm run build
- cp -r scripts/* build/
- cp appspec.yml build/appspec.yml
- zip -rq prod-gl-management-portal.zip *
- echo REACT_APP_API_URL = $REACT_APP_API_URL_PD
- echo REACT_APP_LOGO_URL = $REACT_APP_LOGO_URL
- pipe: atlassian/aws-code-deploy:0.5.2
variables:
COMMAND: 'upload'
APPLICATION_NAME: 'portal.gerberlabs.com'
DEPLOYMENT_GROUP: 'portal.gerberlabs.com'
S3_BUCKET: 'portal.gerberlabs.com'
ZIP_FILE: 'prod-gl-management-portal.zip'
- pipe: atlassian/aws-code-deploy:0.5.2
variables:
COMMAND: 'deploy'
APPLICATION_NAME: 'portal.gerberlabs.com'
DEPLOYMENT_GROUP: 'portal.gerberlabs.com'
S3_BUCKET: 'portal.gerberlabs.com'