Commit b08486ce authored by Albert Salim's avatar Albert Salim

Merge branch '326820-restore-db-migrate-ci-job' into 'master'

ci: Restore the 'db:migrate-from-previous-major-version' job

See merge request gitlab-org/gitlab!58903
parents d8d377c3 ef8cdc90
...@@ -348,34 +348,31 @@ db:check-migrations: ...@@ -348,34 +348,31 @@ db:check-migrations:
- scripts/validate_migration_schema - scripts/validate_migration_schema
allow_failure: true allow_failure: true
# Temporarily disabled due to failures in https://gitlab.com/gitlab-org/gitlab/-/issues/325838 db:migrate-from-previous-major-version:
extends: .db-job-base
# db:migrate-from-v12.10.0: variables:
# extends: .db-job-base USE_BUNDLE_INSTALL: "false"
# variables: SETUP_DB: "false"
# SETUP_DB: "false" PROJECT_TO_CHECKOUT: "gitlab-foss"
# script: TAG_TO_CHECKOUT: "v12.10.14"
# - export PROJECT_TO_CHECKOUT="gitlab" script:
# - export TAG_TO_CHECKOUT="v12.10.0-ee" - '[[ -d "ee/" ]] || export PROJECT_TO_CHECKOUT="gitlab"'
# - '[[ -d "ee/" ]] || export PROJECT_TO_CHECKOUT="gitlab-foss"' - '[[ -d "ee/" ]] || export TAG_TO_CHECKOUT="${TAG_TO_CHECKOUT}-ee"'
# - '[[ -d "ee/" ]] || export TAG_TO_CHECKOUT="v12.10.0"' - retry 'git fetch https://gitlab.com/gitlab-org/$PROJECT_TO_CHECKOUT.git $TAG_TO_CHECKOUT'
# - retry 'git fetch https://gitlab.com/gitlab-org/$PROJECT_TO_CHECKOUT.git $TAG_TO_CHECKOUT' - git checkout -f FETCH_HEAD
# - git checkout -f FETCH_HEAD # Patch Gemfile of the previous major version for compatibility.
# - sed -i -e "s/gem 'grpc', '~> 1.24.0'/gem 'grpc', '~> 1.30.2'/" Gemfile # Update gRPC for Ruby 2.7 - sed -i -e "s/gem 'grpc', '~> 1.24.0'/gem 'grpc', '~> 1.30.2'/" Gemfile # Update gRPC for Ruby 2.7
# - sed -i -e "s/gem 'google-protobuf', '~> 3.8.0'/gem 'google-protobuf', '~> 3.12.0'/" Gemfile - sed -i -e "s/gem 'google-protobuf', '~> 3.8.0'/gem 'google-protobuf', '~> 3.12'/" Gemfile
# - gem install bundler:1.17.3 - sed -i -e "s/gem 'nokogiri', '~> 1.10.5'/gem 'nokogiri', '~> 1.11.0'/" Gemfile
# - bundle update google-protobuf grpc bootsnap - sed -i -e "s/gem 'mimemagic', '~> 0.3.2'/gem 'ruby-magic', '~> 0.3.2'/" Gemfile
# - bundle install $BUNDLE_INSTALL_FLAGS - run_timed_command "gem install bundler:1.17.3"
# - date - run_timed_command "bundle update google-protobuf nokogiri grpc mimemagic bootsnap"
# - cp config/gitlab.yml.example config/gitlab.yml - run_timed_command "bundle install ${BUNDLE_INSTALL_FLAGS}"
# - bundle exec rake db:drop db:create db:structure:load db:seed_fu - cp config/gitlab.yml.example config/gitlab.yml
# - date - run_timed_command "bundle exec rake db:drop db:create db:structure:load db:migrate db:seed_fu"
# - git checkout -f $CI_COMMIT_SHA - git checkout -f $CI_COMMIT_SHA
# - bundle install $BUNDLE_INSTALL_FLAGS - run_timed_command "bundle install ${BUNDLE_INSTALL_FLAGS}"
# - date - run_timed_command "bundle exec rake db:migrate"
# - . scripts/prepare_build.sh
# - date
# - bundle exec rake db:migrate
db:rollback: db:rollback:
extends: .db-job-base extends: .db-job-base
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment