-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcircle.yml
More file actions
52 lines (46 loc) · 1.59 KB
/
circle.yml
File metadata and controls
52 lines (46 loc) · 1.59 KB
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
general:
branches:
only:
- master
- production
machine:
environment:
# Add app engine sdk to pythonpath for local unit tests.
PYTHONPATH: $(PYTHONPATH):$(HOME)/google_appengine
# Add app engine sdk to path
PATH: ${HOME}/go_appengine/:${HOME}/go_appengine/gopath/bin:${PATH}
# Add GOROOT
GOROOT: ${HOME}/go_appengine/goroot
# Add GOPATH
GOPATH: ${HOME}/go_appengine/gopath
# Project-IDs
GCLOUD_PROJECT_DEV: "xtern-matching-test"
GCLOUD_PROJECT_PROD: "xtern-matching-test"
dependencies:
pre:
# Download App Engine SDK
- curl -o $HOME/go_appengine_sdk_linux_amd64-1.9.40.zip https://storage.googleapis.com/appengine-sdks/featured/go_appengine_sdk_linux_amd64-1.9.40.zip
- unzip -q -d $HOME $HOME/go_appengine_sdk_linux_amd64-1.9.40.zip
# Retrieve our secrets from the CircleCI environment
- echo $TEST_SECRET | base64 --decode > ${HOME}/client-secret.json
# Make sure gcloud is up to date
- gcloud --quiet components update app
# authenticate gcloud
- gcloud auth activate-service-account --key-file ${HOME}/client-secret.json
# Set Project
- gcloud config set project $GCLOUD_PROJECT_DEV
- mkdir $HOME/go_appengine/gopath/src
- ln -s $HOME/Xtern-Matching $HOME/go_appengine/gopath/src
override:
- goapp get Xtern-Matching/core
- npm install core --prefix core
test:
override:
- npm test --prefix core
deployment:
staging:
branch: master
commands:
- goapp get -u google.golang.org/appengine/cmd/aedeploy
- cd core
- aedeploy gcloud --quiet app deploy --promote