aboutsummaryrefslogtreecommitdiffstats
path: root/.gitlab-ci.yml
diff options
context:
space:
mode:
Diffstat (limited to '.gitlab-ci.yml')
-rw-r--r--.gitlab-ci.yml30
1 files changed, 16 insertions, 14 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index d8724581..f64e864c 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -1,10 +1,21 @@
+cache:
+ key: "${CI_COMMIT_REF_SLUG}"
+ paths:
+ - python/.venv/
+ - rust/target/
+ - rust/.cargo_cache/
+
+variables:
+ LC_ALL: "C.UTF-8"
+ LANG: "C.UTF-8"
+ PIPENV_VENV_IN_PROJECT: "true"
+ CARGO_HOME: ".cargo_cache"
+
+image: "rust:1.32-stretch"
+
unified_test:
- image: "rust:1.32-stretch"
variables:
- LC_ALL: "C.UTF-8"
- LANG: "C.UTF-8"
- PIPENV_VENV_IN_PROJECT: "true"
POSTGRES_DB: "fatcat_test"
POSTGRES_USER: "fatcat_user"
POSTGRES_PASSWORD: "fatcat_pw"
@@ -13,9 +24,9 @@ unified_test:
services:
- "postgres:11"
before_script:
- - cargo install diesel_cli --version 1.3.1
- apt update -qy
- apt install -y python3-dev python3-pip python3-wheel python3-requests python3-six python3-pytest libsnappy-dev libsodium-dev
+ - cargo install diesel_cli --version 1.3.1
- pip3 install pipenv
- pipenv --version
script:
@@ -39,10 +50,6 @@ unified_test:
rust_build_release:
stage: build
when: manual
- image: "rust:1.32-stretch"
- variables:
- LC_ALL: "C.UTF-8"
- LANG: "C.UTF-8"
before_script:
- apt update -qy
- apt install -y python3-dev python3-pip python3-wheel python3-requests python3-six python3-pytest libsnappy-dev libsodium-dev
@@ -58,11 +65,6 @@ rust_build_release:
python_build_release:
stage: build
when: manual
- image: "rust:1.32-stretch"
- variables:
- LC_ALL: "C.UTF-8"
- LANG: "C.UTF-8"
- PIPENV_VENV_IN_PROJECT: "true"
before_script:
- apt update -qy
- apt install -y python3-dev python3-pip python3-wheel python3-requests python3-six python3-pytest libsnappy-dev libsodium-dev