Use similar interface to access gitolite
Simplified gitolite handle logic Stubn over monkeypatch Stub only specific methods in Gitlab:Gitolite Moved grach auth to lib added specs for keys observer removes SshKey role
This commit is contained in:
parent
aded7056fd
commit
7cdc5b9e04
20 changed files with 155 additions and 88 deletions
|
@ -1,7 +1,6 @@
|
|||
require 'digest/md5'
|
||||
|
||||
class Key < ActiveRecord::Base
|
||||
include SshKey
|
||||
belongs_to :user
|
||||
belongs_to :project
|
||||
|
||||
|
@ -50,6 +49,10 @@ class Key < ActiveRecord::Base
|
|||
user.projects
|
||||
end
|
||||
end
|
||||
|
||||
def last_deploy?
|
||||
Key.where(identifier: identifier).count == 0
|
||||
end
|
||||
end
|
||||
# == Schema Information
|
||||
#
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue