diff options
author | Alexis Reigel <alexis.reigel.ext@siemens.com> | 2018-10-31 22:12:22 +0300 |
---|---|---|
committer | Alexis Reigel <alexis.reigel.ext@siemens.com> | 2018-11-29 17:04:59 +0300 |
commit | 943827b39ae1e3203736ec87724ec255505ae980 (patch) | |
tree | f889e435ea91cb51bec5ec276f3a3d23d5faa524 /db | |
parent | 5bf893952b82b4877790f5a7932b2f799393c686 (diff) |
option to make variables protected by default
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/20181031145139_add_protected_ci_variables_to_application_settings.rb | 17 | ||||
-rw-r--r-- | db/schema.rb | 1 |
2 files changed, 18 insertions, 0 deletions
diff --git a/db/migrate/20181031145139_add_protected_ci_variables_to_application_settings.rb b/db/migrate/20181031145139_add_protected_ci_variables_to_application_settings.rb new file mode 100644 index 00000000000..85ee34afe1e --- /dev/null +++ b/db/migrate/20181031145139_add_protected_ci_variables_to_application_settings.rb @@ -0,0 +1,17 @@ +# frozen_string_literal: true + +class AddProtectedCiVariablesToApplicationSettings < ActiveRecord::Migration[5.0] + include Gitlab::Database::MigrationHelpers + + DOWNTIME = false + + disable_ddl_transaction! + + def up + add_column_with_default(:application_settings, :protected_ci_variables, :boolean, default: false, allow_null: false) + end + + def down + remove_column(:application_settings, :protected_ci_variables) + end +end diff --git a/db/schema.rb b/db/schema.rb index 9c9c19aa897..a6ce749f45f 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -166,6 +166,7 @@ ActiveRecord::Schema.define(version: 20181126153547) do t.integer "diff_max_patch_bytes", default: 102400, null: false t.integer "archive_builds_in_seconds" t.string "commit_email_hostname" + t.boolean "protected_ci_variables", default: false, null: false t.index ["usage_stats_set_by_user_id"], name: "index_application_settings_on_usage_stats_set_by_user_id", using: :btree end |