diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-07-18 13:55:01 +0300 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-07-18 13:55:01 +0300 |
commit | 475f607a22dcf8ec16c1b51edb638fa624768061 (patch) | |
tree | 78cacd6518838dd3faa4df1de47d8765cb939650 /lib/gitlab/backend/shell.rb | |
parent | 02e39563c8e931c94a650f36d8732beecc068019 (diff) | |
download | gitlab-ce-475f607a22dcf8ec16c1b51edb638fa624768061.tar.gz |
Use gitlab-shell authorized_keys truncation. Fix issue with authorized_keys stored in different location
Diffstat (limited to 'lib/gitlab/backend/shell.rb')
-rw-r--r-- | lib/gitlab/backend/shell.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/gitlab/backend/shell.rb b/lib/gitlab/backend/shell.rb index 6c9532face8..d0b89f85ade 100644 --- a/lib/gitlab/backend/shell.rb +++ b/lib/gitlab/backend/shell.rb @@ -139,6 +139,15 @@ module Gitlab system "#{gitlab_shell_user_home}/gitlab-shell/bin/gitlab-keys", "rm-key", key_id, key_content end + # Remove all ssh keys from gitlab shell + # + # Ex. + # remmove_all_keys + # + def remove_all_keys + system "#{gitlab_shell_user_home}/gitlab-shell/bin/gitlab-keys", "clear" + end + # Add empty directory for storing repositories # # Ex. |