-
Notifications
You must be signed in to change notification settings - Fork 0
/
circle.yml
54 lines (46 loc) · 1.79 KB
/
circle.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
machine:
environment:
# Setup the appengine path.
APPENGINE: ${HOME}/google_appengine
# Add app engine sdk to pythonpath for local unit tests.
PYTHONPATH: ${PYTHONPATH}:${HOME}/google_appengine
# Replace this with your project ID
GCLOUD_PROJECT: "continuous-deployment-circle"
dependencies:
cache_directories:
- "default/node_modules"
pre:
# Download App Engine SDK
# This is not necessary to deploy, its only necessary to run local tests importing the App Engine SDK
- curl -o $HOME/google_appengine_1.9.40.zip https://storage.googleapis.com/appengine-sdks/featured/google_appengine_1.9.40.zip
- unzip -q -d $HOME $HOME/google_appengine_1.9.40.zip
# This is required by gcloud so that it can create the staging directory.
- sudo chown ubuntu:ubuntu /opt/
# Update app-engine-python here so we're not asked to when we start the server.
- gcloud --quiet components update app-engine-python
# Install ahoy
- go get github.com/DevinciHQ/ahoy && go install github.com/DevinciHQ/ahoy
- ahoy deps-backend
- ahoy deps-frontend
# Retrieve our secrets from the CircleCI environment
#- echo $CLIENT_SECRET | base64 --decode > ${HOME}/client-secret.json
#- sed s/YOUR-API-KEY/$API_KEY/ api_key.py.sample > api_key.py
# authenticate gcloud
#- gcloud auth activate-service-account --key-file ${HOME}/client-secret.json
# Replace <your-project-id>
#- gcloud config set project $GCLOUD_PROJECT
test:
pre:
- ahoy up:
background: true
override:
# run local unit tests
- ahoy test
#deployment:
#staging:
# branch: master
# commands:
# # deploy to AppEngine
# - gcloud -q preview app deploy app.yaml --promote --version=1
# Run our E2E Test
# - python e2e_test.py