Only install git and libpq when needed

This commit is contained in:
Jake Howard 2022-09-13 20:18:39 +01:00
parent 93ecd380f5
commit afcadbf1ef
Signed by: jake
GPG key ID: 57AFB45680EDD477

View file

@ -53,7 +53,6 @@ poetry:
dependencies: dependencies:
- poetry - poetry
before_script: before_script:
- apt-get update && apt-get install --yes git libpq-dev
- source env/bin/activate - source env/bin/activate
variables: variables:
SECRET_KEY: super-secret SECRET_KEY: super-secret
@ -65,6 +64,8 @@ test_python:
variables: variables:
POSTGRES_HOST_AUTH_METHOD: trust POSTGRES_HOST_AUTH_METHOD: trust
DATABASE_URL: postgres://postgres@postgres/postgres DATABASE_URL: postgres://postgres@postgres/postgres
before_script:
- apt-get update && apt-get install --yes git libpq-dev
script: script:
- ./manage.py collectstatic --noinput --clear - ./manage.py collectstatic --noinput --clear
- coverage run ./manage.py test - coverage run ./manage.py test
@ -119,7 +120,7 @@ gunicorn_check:
djhtml: djhtml:
extends: .python_test_template extends: .python_test_template
script: script:
- git ls-files '*.html' | xargs djhtml --check --tabwidth 2 - find website/ -name '*.html' | xargs djhtml --check --tabwidth 2
npm_lint: npm_lint:
image: node:18-slim image: node:18-slim