diff options
author | Kamil TrzciĆski <ayufan@ayufan.eu> | 2018-09-18 22:20:43 +0300 |
---|---|---|
committer | Bob Van Landuyt <bob@vanlanduyt.co> | 2018-09-19 14:15:19 +0300 |
commit | 6a22ef876abfc4c3314df8fd987bd1a92a08771c (patch) | |
tree | b387611d3c8a22066f3981afb52e2f8f256a5358 /db | |
parent | e950a59c5be85dac37b2fbdaccca1713f6ab374e (diff) |
Merge branch '41729-enable-auto-devops-instance-wide-for-everyone' into 'master'
Resolve "Enable Auto DevOps by default for self managed instances of GitLab"
Closes #41729
See merge request gitlab-org/gitlab-ce!21157
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/20180813101999_change_default_of_auto_devops_instance_wide.rb | 15 | ||||
-rw-r--r-- | db/migrate/20180813102000_enable_auto_devops_instance_wide_for_everyone.rb | 15 | ||||
-rw-r--r-- | db/schema.rb | 2 |
3 files changed, 31 insertions, 1 deletions
diff --git a/db/migrate/20180813101999_change_default_of_auto_devops_instance_wide.rb b/db/migrate/20180813101999_change_default_of_auto_devops_instance_wide.rb new file mode 100644 index 00000000000..05d1124f5c4 --- /dev/null +++ b/db/migrate/20180813101999_change_default_of_auto_devops_instance_wide.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +class ChangeDefaultOfAutoDevopsInstanceWide < ActiveRecord::Migration + include Gitlab::Database::MigrationHelpers + + DOWNTIME = false + + def up + change_column_default :application_settings, :auto_devops_enabled, true + end + + def down + change_column_default :application_settings, :auto_devops_enabled, false + end +end diff --git a/db/migrate/20180813102000_enable_auto_devops_instance_wide_for_everyone.rb b/db/migrate/20180813102000_enable_auto_devops_instance_wide_for_everyone.rb new file mode 100644 index 00000000000..21fb62806b3 --- /dev/null +++ b/db/migrate/20180813102000_enable_auto_devops_instance_wide_for_everyone.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +class EnableAutoDevopsInstanceWideForEveryone < ActiveRecord::Migration + include Gitlab::Database::MigrationHelpers + + DOWNTIME = false + + def up + execute "UPDATE application_settings SET auto_devops_enabled = true" + end + + def down + # No way to know here what their previous setting was... + end +end diff --git a/db/schema.rb b/db/schema.rb index 13814dd569e..f54ef805ae7 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -141,7 +141,7 @@ ActiveRecord::Schema.define(version: 20180906101639) do t.integer "performance_bar_allowed_group_id" t.boolean "hashed_storage_enabled", default: false, null: false t.boolean "project_export_enabled", default: true, null: false - t.boolean "auto_devops_enabled", default: false, null: false + t.boolean "auto_devops_enabled", default: true, null: false t.integer "circuitbreaker_failure_count_threshold", default: 3 t.integer "circuitbreaker_failure_reset_time", default: 1800 t.integer "circuitbreaker_storage_timeout", default: 15 |