Skip to content

Commit

Permalink
Update CircleCI to use new build image
Browse files Browse the repository at this point in the history
  • Loading branch information
sfc-gh-afedorov committed Oct 22, 2018
1 parent 51644f8 commit 8f21eaa
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 7 deletions.
15 changes: 8 additions & 7 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ version: 2
jobs:
build:
docker:
- image: snowsec/snowalert
- image: snowsec/snowalert-builder

working_directory: ~/project

Expand All @@ -13,20 +13,21 @@ jobs:

- restore_cache:
keys:
- snowalert-venv-{{ checksum "requirements.txt" }}
- snowalert-venv- # fallback to using the latest cache if no exact match is found
- app-venv-{{ checksum "requirements.txt" }}
- app-venv- # fallback to using the latest cache if no exact match is found

- run:
name: install_snowalert_dependencies
command: |
python3 -m venv ./.venv
source ./.venv/bin/activate
python -m venv .venv
ls -al . ; ls -al .venv ; ls -al .venv/bin
source .venv/bin/activate
pip install -r requirements.txt
- save_cache:
paths:
- ./.venv
key: snowalert-venv-{{ checksum "requirements.txt" }}
key: app-venv-{{ checksum "requirements.txt" }}

- run:
name: run tests
Expand Down Expand Up @@ -61,7 +62,7 @@ jobs:
name: Install or Update Docs Dependencies
command: |
cd docs
python3 -m venv .venv
python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
Expand Down
4 changes: 4 additions & 0 deletions builder/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
FROM python:3.7-slim-stretch

RUN pip install --upgrade pip virtualenv pyflakes
RUN apt update -y && apt install -y git

0 comments on commit 8f21eaa

Please sign in to comment.