diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 5ccfe272173..d6aba6f0cbc 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -751,17 +751,27 @@ publish_er_diagram: stage: .post needs: - job: build-ci-image + variables: + DOCKER_DB_HOST: db-postgres + POSTGRES_DB: identity_idp_test + POSTGRES_USER: postgres_user + POSTGRES_PASSWORD: postgres_password + POSTGRES_HOST_AUTH_METHOD: trust + RAILS_ENV: test + services: + - name: public.ecr.aws/docker/library/postgres:16.4 + alias: db-postgres + command: ['--fsync=false', '--synchronous_commit=false', '--full_page_writes=false'] cache: - <<: *ruby_cache rules: - if: $CI_COMMIT_BRANCH == "main" - if: $CI_COMMIT_BRANCH == "vm-reinstate-erd" image: "${ECR_REGISTRY}/idp/ci:${CI_COMMIT_SHA}" - variables: - RAILS_ENV: test script: - echo "Publishing ER diagram" - *bundle_install + - bundle exec rake db:create db:migrate --trace - bundle exec rails erd artifacts: paths: