Skip to content

Commit 77c66bc

Browse files
committed
Merge branch 'staging' into features/identify-capgemini-volunteers
2 parents c74a552 + ef1e417 commit 77c66bc

File tree

3 files changed

+39
-3
lines changed

3 files changed

+39
-3
lines changed

.circleci/config.yml

Lines changed: 36 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@ jobs:
4343
- run:
4444
name: Set env variables
4545
command: echo 'export VERSION=$(echo $CIRCLE_SHA1 | cut -c -7)' >> $BASH_ENV
46+
- run:
47+
name: build qa
48+
command: REACT_APP_NODE_ENV=QA yarn build:qa
4649
- run:
4750
name: build staging
4851
command: REACT_APP_NODE_ENV=STAGING yarn build:staging
@@ -52,15 +55,37 @@ jobs:
5255
- persist_to_workspace:
5356
root: .
5457
paths:
58+
- qa
5559
- staging
5660
- production
5761

62+
deploy_qa:
63+
docker:
64+
- image: circleci/python:3.6-jessie
65+
working_directory: ~/deploy
66+
environment:
67+
PUBLIC_URL: https://forms.qa.codeyourfuture.io
68+
steps:
69+
- attach_workspace:
70+
at: .
71+
- run:
72+
name: Set env variables
73+
command: echo 'export VERSION=$(echo $CIRCLE_SHA1 | cut -c -7)' >> $BASH_ENV
74+
- run:
75+
name: Install awscli
76+
command: sudo pip install awscli
77+
- s3deploy:
78+
dir: qa
79+
to: 'forms.qa.codeyourfuture.io'
80+
cf_distribution_id: E2VFUDC8YCDBKS
81+
82+
5883
deploy_staging:
5984
docker:
6085
- image: circleci/python:3.6-jessie
6186
working_directory: ~/deploy
6287
environment:
63-
PUBLIC_URL: https://staging.forms.codeyourfuture.io
88+
PUBLIC_URL: https://forms.staging.codeyourfuture.io
6489
steps:
6590
- attach_workspace:
6691
at: .
@@ -72,8 +97,8 @@ jobs:
7297
command: sudo pip install awscli
7398
- s3deploy:
7499
dir: staging
75-
to: 'staging.forms.codeyourfuture.io'
76-
cf_distribution_id: E3MJAA9E60TZUB
100+
to: 'forms.staging.codeyourfuture.io'
101+
cf_distribution_id: E1SJFMKKCNFUGI
77102

78103
deploy_production:
79104
docker:
@@ -101,6 +126,14 @@ workflows:
101126
jobs:
102127
- build:
103128
context: build
129+
- deploy_qa:
130+
context: deployments_qa
131+
requires:
132+
- build
133+
filters:
134+
branches:
135+
only:
136+
- qa
104137
- deploy_staging:
105138
context: deployments_staging
106139
requires:

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
"scripts": {
3535
"start": "REACT_APP_NODE_ENV=LOCAL react-scripts start",
3636
"build": "react-scripts build && yarn run delete-maps",
37+
"build:qa": "REACT_APP_NODE_ENV=QA react-scripts build && yarn run delete-maps && mv build qa",
3738
"build:staging": "REACT_APP_NODE_ENV=STAGING react-scripts build && yarn run delete-maps && mv build staging",
3839
"build:production": "REACT_APP_NODE_ENV=PRODUCTION react-scripts build && yarn run delete-maps && mv build production",
3940
"delete-maps": "yarn run delete-map-files && yarn run delete-references-to-map-files",

src/config.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ export const domain = () => {
55
switch (env) {
66
case 'LOCAL':
77
return 'http://localhost:3001'
8+
case 'QA':
9+
return 'https://cyf-api.qa.codeyourfuture.io'
810
case 'STAGING':
911
return 'https://cyf-api.staging.codeyourfuture.io'
1012
case 'PRODUCTION':

0 commit comments

Comments
 (0)