Commit 5c064d4e authored by Gabriel Mazetto's avatar Gabriel Mazetto

Fix EE to CE downgrade instructions

parent 9310e6ea
...@@ -24,14 +24,14 @@ repositories to use Git LFS before downgrading to the Community Edition. ...@@ -24,14 +24,14 @@ repositories to use Git LFS before downgrading to the Community Edition.
### Remove Jenkins CI Service entries from the database ### Remove Jenkins CI Service entries from the database
The `JenkinsService` class is only available on the Enterprise Edition codebase, The `JenkinsService` and `JenkinsDeprecatedService` classes are only available on the
so if you downgrade to the Community Edition, you'll come across the following Enterprise Edition codebase, so if you downgrade to the Community Edition, you'll come
error: across an error similar to the following:
``` ```
Completed 500 Internal Server Error in 497ms (ActiveRecord: 32.2ms) Completed 500 Internal Server Error in 497ms (ActiveRecord: 32.2ms)
ActionView::Template::Error (The single-table inheritance mechanism failed to locate the subclass: 'JenkinsService'. This ActionView::Template::Error (The single-table inheritance mechanism failed to locate the subclass: 'JenkinsDeprecatedService'. This
error is raised because the column 'type' is reserved for storing the class in case of inheritance. Please rename this error is raised because the column 'type' is reserved for storing the class in case of inheritance. Please rename this
column if you didn't intend it to be used for storing the inheritance class or overwrite Service.inheritance_column to column if you didn't intend it to be used for storing the inheritance class or overwrite Service.inheritance_column to
use another column for that information.) use another column for that information.)
...@@ -39,18 +39,20 @@ use another column for that information.) ...@@ -39,18 +39,20 @@ use another column for that information.)
All services are created automatically for every project you have, so in order All services are created automatically for every project you have, so in order
to avoid getting this error, you need to remove all instances of the to avoid getting this error, you need to remove all instances of the
`JenkinsService` from your database: `JenkinsService` and `JenkinsDeprecatedService` from your database:
**Omnibus Installation** **Omnibus Installation**
``` ```
$ sudo gitlab-rails runner "Service.where(type: 'JenkinsService').delete_all" $ sudo gitlab-rails runner "Service.where(type: 'JenkinsService').delete_all"
$ sudo gitlab-rails runner "Service.where(type: 'JenkinsDeprecatedService').delete_all"
``` ```
**Source Installation** **Source Installation**
``` ```
$ bundle exec rails runner "Service.where(type: 'JenkinsService').delete_all" production $ RAILS_ENV=production bundle exec rails runner "Service.where(type: 'JenkinsService').delete_all"
$ RAILS_ENV=production bundle exec rails runner "Service.where(type: 'JenkinsDeprecatedService').delete_all"
``` ```
## Downgrade to CE ## Downgrade to CE
......
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