diff options
author | Rubén Dávila <ruben@gitlab.com> | 2017-09-27 20:27:39 +0300 |
---|---|---|
committer | Rubén Dávila <ruben@gitlab.com> | 2017-10-05 16:25:27 +0300 |
commit | 328f4a505bcd2e7b38f907a24df437f8c35bc3af (patch) | |
tree | 7b1f8ae20ef5bd9e57fe0dc0848b358dad2a5403 /db/migrate/20170927161718_create_gpg_key_subkeys.rb | |
parent | 37dcfb6e31a65d487424c0bf73874aabb2e69020 (diff) |
Use a separate model to handle GPG subkeys
Diffstat (limited to 'db/migrate/20170927161718_create_gpg_key_subkeys.rb')
-rw-r--r-- | db/migrate/20170927161718_create_gpg_key_subkeys.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/db/migrate/20170927161718_create_gpg_key_subkeys.rb b/db/migrate/20170927161718_create_gpg_key_subkeys.rb new file mode 100644 index 00000000000..d61b669f517 --- /dev/null +++ b/db/migrate/20170927161718_create_gpg_key_subkeys.rb @@ -0,0 +1,9 @@ +class CreateGpgKeySubkeys < ActiveRecord::Migration + def change + create_table :gpg_key_subkeys do |t| + t.binary :keyid + t.binary :fingerprint + t.references :gpg_key, null: false, index: true, foreign_key: { on_delete: :cascade } + end + end +end |