Skip to content

Commit

Permalink
Publish ERD at the end of CI
Browse files Browse the repository at this point in the history
  • Loading branch information
vrajmohan committed Dec 11, 2024
1 parent afd3baf commit 5f88c70
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 10 deletions.
3 changes: 1 addition & 2 deletions .erdconfig
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
title: login.gov IdP entity-relationship diagram
notation: bachman
filename: docs/erd
filename: idp_erd
filetype: svg
attributes:
- primary_keys
- foreign_keys
- content
sort: false

15 changes: 15 additions & 0 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -746,3 +746,18 @@ deploy_eks:
IMAGE_TAG: $CI_COMMIT_SHA
rules:
- if: $CI_COMMIT_BRANCH == "main"

publish_er_diagram:
stage: .pre # TODO - change to .post
rules:
- if: $CI_COMMIT_BRANCH == "main"
- if: $CI_COMMIT_BRANCH == "vm-reinstate-erd"
variables:
RAILS_ENV: test
script:
- echo "Publishing ER diagram"
- *bundle_install
- bundle exec rails erd
artifacts:
paths:
- idp_erd.svg
1 change: 0 additions & 1 deletion Brewfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,4 @@ brew 'node@20'
brew 'yarn'
brew '[email protected]'
brew 'jq'
brew 'graphviz'
cask 'chromedriver'
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@ group :development do
gem 'irb'
gem 'letter_opener', '~> 1.8'
gem 'rack-mini-profiler', '>= 1.1.3', require: false
gem 'rails-erd'
end

group :development, :test do
Expand All @@ -117,6 +116,7 @@ group :development, :test do
gem 'pry-doc'
gem 'pry-rails'
gem 'psych'
gem 'rails-erd'
gem 'rspec', '~> 3.13.0'
gem 'rspec-rails', '~> 7.0'
gem 'rubocop', '~> 1.69.1', require: false
Expand Down
6 changes: 0 additions & 6 deletions lib/tasks/auto_generate_diagram.rake

This file was deleted.

0 comments on commit 5f88c70

Please sign in to comment.