diff options
author | Douwe Maan <douwe@gitlab.com> | 2016-12-27 15:00:49 +0000 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2016-12-27 15:00:49 +0000 |
commit | 20afb4c69ee91a91094eed2bffd566c5bca1ce0d (patch) | |
tree | 632bbb3e3e8978a8d7bb2e26dd91edf9b83ecd4d /db | |
parent | cdb29c2fb00a873e8f8f646b06c7b000cc13e610 (diff) | |
parent | c1d11bf57c3091aa4695e302e21c39b9ec723f54 (diff) | |
download | gitlab-ce-20afb4c69ee91a91094eed2bffd566c5bca1ce0d.tar.gz |
Merge branch 'feature/1376-allow-write-access-deploy-keys' into 'master'
Allow to add deploy keys with write-access
Closes #1376
See merge request !7383
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/20160811172945_add_can_push_to_keys.rb | 14 | ||||
-rw-r--r-- | db/schema.rb | 1 |
2 files changed, 15 insertions, 0 deletions
diff --git a/db/migrate/20160811172945_add_can_push_to_keys.rb b/db/migrate/20160811172945_add_can_push_to_keys.rb new file mode 100644 index 00000000000..5fd303fe8fb --- /dev/null +++ b/db/migrate/20160811172945_add_can_push_to_keys.rb @@ -0,0 +1,14 @@ +class AddCanPushToKeys < ActiveRecord::Migration + include Gitlab::Database::MigrationHelpers + disable_ddl_transaction! + + DOWNTIME = false + + def up + add_column_with_default(:keys, :can_push, :boolean, default: false, allow_null: false) + end + + def down + remove_column(:keys, :can_push) + end +end diff --git a/db/schema.rb b/db/schema.rb index 6337ce2eaac..2198dcee2cd 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -527,6 +527,7 @@ ActiveRecord::Schema.define(version: 20161226122833) do t.string "type" t.string "fingerprint" t.boolean "public", default: false, null: false + t.boolean "can_push", default: false, null: false end add_index "keys", ["fingerprint"], name: "index_keys_on_fingerprint", unique: true, using: :btree |