Update the CI config wrt the new project name

This commit is contained in:
Martin Pépin 2021-02-07 17:19:46 +01:00
parent 726b3f55a0
commit aa3462aaee
No known key found for this signature in database
GPG key ID: E7520278B1774448

View file

@ -21,8 +21,8 @@ variables:
before_script: before_script:
- mkdir -p vendor/{pip,apt} - mkdir -p vendor/{pip,apt}
- apt-get update -q && apt-get -o dir::cache::archives="vendor/apt" install -yqq postgresql-client libldap2-dev libsasl2-dev - apt-get update -q && apt-get -o dir::cache::archives="vendor/apt" install -yqq postgresql-client libldap2-dev libsasl2-dev
- sed -E 's/^REDIS_HOST.*/REDIS_HOST = "redis"/' cof/settings/secret_example.py > cof/settings/secret.py - sed -E 's/^REDIS_HOST.*/REDIS_HOST = "redis"/' gestioasso/settings/secret_example.py > gestioasso/settings/secret.py
- sed -i.bak -E 's;^REDIS_PASSWD = .*$;REDIS_PASSWD = "";' cof/settings/secret.py - sed -i.bak -E 's;^REDIS_PASSWD = .*$;REDIS_PASSWD = "";' gestioasso/settings/secret.py
# Remove the old test database if it has not been done yet # Remove the old test database if it has not been done yet
- psql --username=$POSTGRES_USER --host=$DBHOST -c "DROP DATABASE IF EXISTS test_$POSTGRES_DB" - psql --username=$POSTGRES_USER --host=$DBHOST -c "DROP DATABASE IF EXISTS test_$POSTGRES_DB"
- pip install --upgrade -r requirements-prod.txt coverage tblib - pip install --upgrade -r requirements-prod.txt coverage tblib
@ -44,7 +44,7 @@ coftest:
stage: test stage: test
extends: .test_template extends: .test_template
variables: variables:
DJANGO_SETTINGS_MODULE: "cof.settings.cof_prod" DJANGO_SETTINGS_MODULE: "gestioasso.settings.cof_prod"
script: script:
- coverage run manage.py test gestioncof bda kfet petitscours shared --parallel - coverage run manage.py test gestioncof bda kfet petitscours shared --parallel
@ -52,7 +52,7 @@ bdstest:
stage: test stage: test
extends: .test_template extends: .test_template
variables: variables:
DJANGO_SETTINGS_MODULE: "cof.settings.bds_prod" DJANGO_SETTINGS_MODULE: "gestioasso.settings.bds_prod"
script: script:
- coverage run manage.py test bds clubs events --parallel - coverage run manage.py test bds clubs events --parallel
@ -65,7 +65,7 @@ linters:
- black --check . - black --check .
- isort --check --diff . - isort --check --diff .
# Print errors only # Print errors only
- flake8 --exit-zero bda bds clubs cof events gestioncof kfet petitscours provisioning shared - flake8 --exit-zero bda bds clubs gestioasso events gestioncof kfet petitscours provisioning shared
cache: cache:
key: linters key: linters
paths: paths:
@ -75,11 +75,11 @@ linters:
migration_checks: migration_checks:
stage: test stage: test
variables: variables:
DJANGO_SETTINGS_MODULE: "cof.settings.local" DJANGO_SETTINGS_MODULE: "gestioasso.settings.local"
before_script: before_script:
- mkdir -p vendor/{pip,apt} - mkdir -p vendor/{pip,apt}
- apt-get update -q && apt-get -o dir::cache::archives="vendor/apt" install -yqq postgresql-client libldap2-dev libsasl2-dev - apt-get update -q && apt-get -o dir::cache::archives="vendor/apt" install -yqq postgresql-client libldap2-dev libsasl2-dev
- cp cof/settings/secret_example.py cof/settings/secret.py - cp gestioasso/settings/secret_example.py gestioasso/settings/secret.py
- pip install --upgrade -r requirements-devel.txt - pip install --upgrade -r requirements-devel.txt
- python --version - python --version
script: python manage.py makemigrations --dry-run --check script: python manage.py makemigrations --dry-run --check