diff options
author | Jacob Vosmaer <contact@jacobvosmaer.nl> | 2014-04-15 16:26:15 +0200 |
---|---|---|
committer | Jacob Vosmaer <contact@jacobvosmaer.nl> | 2014-04-23 11:07:36 +0200 |
commit | 43e77099d86960401013a45f56e29bfb83368d2c (patch) | |
tree | 66d93910c92b2019c7b49cf74139e8f14feb42ec /db | |
parent | 7fab63b41f1a28cc5efa6b9afef30170e41c94ea (diff) | |
download | gitlab-ce-43e77099d86960401013a45f56e29bfb83368d2c.tar.gz |
Adjust MySQL limits for existing installations
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/20140415124820_limits_to_mysql.rb | 1 | ||||
-rw-r--r-- | db/migrate/limits_to_mysql.rb | 10 |
2 files changed, 11 insertions, 0 deletions
diff --git a/db/migrate/20140415124820_limits_to_mysql.rb b/db/migrate/20140415124820_limits_to_mysql.rb new file mode 100644 index 00000000000..3f6e62617c5 --- /dev/null +++ b/db/migrate/20140415124820_limits_to_mysql.rb @@ -0,0 +1 @@ +require_relative 'limits_to_mysql' diff --git a/db/migrate/limits_to_mysql.rb b/db/migrate/limits_to_mysql.rb new file mode 100644 index 00000000000..4dc3b830bc6 --- /dev/null +++ b/db/migrate/limits_to_mysql.rb @@ -0,0 +1,10 @@ +class LimitsToMysql < ActiveRecord::Migration + def up + return unless ActiveRecord::Base.configurations[Rails.env]['adapter'] == 'mysql2' + + change_column :merge_request_diffs, :st_commits, :text, limit: 2147483647 + change_column :merge_request_diffs, :st_diffs, :text, limit: 2147483647 + change_column :snippets, :content, :text, limit: 2147483647 + change_column :notes, :st_diff, :text, limit: 2147483647 + end +end |