From e8fe27de8acfe9012beb8ed5080a6c68c040e1d1 Mon Sep 17 00:00:00 2001 From: Straw-Etiam Date: Wed, 13 Jan 2021 11:50:51 +0100 Subject: [PATCH] :construction_worker: update1 de la CI --- .circleci/config.yml | 41 ++++++++++++++++++++++++++++------------- 1 file changed, 28 insertions(+), 13 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 12a4918..d0fa70d 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -1,21 +1,36 @@ -version: 2.1 - -orbs: - python: circleci/python@0.2.1 +version: 2 jobs: - build-and-test: - executor: python/default + build: + docker: + - image: circleci/python:latest + environment: + FLASK_CONFIG: testing + TEST_DATABASE_URL: postgresql://root@localhost/circle_test?sslmode=disable + + - image: circleci/postgres:9.6.5-alpine-ram + auth: + username: mydockerhub-user + password: $DOCKERHUB_PASSWORD # context / project UI env-var reference + environment: + POSTGRES_USER: root + POSTGRES_DB: circle_test + POSTGRES_PASSWORD: "" + steps: - checkout - - python/load-cache - - python/install-deps - - python/save-cache - run: - command: ./manage.py test - name: Test + name: Install Python deps in a venv + command: | + python3 -m venv venv + . venv/bin/activate + pip install -r requirements/dev.txt + + + workflows: - main: + version: 2 + build-deploy: jobs: - - build-and-test + - build \ No newline at end of file