diff options
author | James Moger <james.moger@gitblit.com> | 2014-06-05 08:38:35 -0400 |
---|---|---|
committer | James Moger <james.moger@gitblit.com> | 2014-06-05 08:38:35 -0400 |
commit | 05f229883c4e15e044c5c103acf69265cfb8806e (patch) | |
tree | be1261dd88c8a8b29b2f31ce5b5e591b9eedd182 /src/main/java/com/gitblit/manager/RuntimeManager.java | |
parent | c9921bd3b0b7bf90b6e5e2a52141c3fdf0f31f89 (diff) | |
download | gitblit-05f229883c4e15e044c5c103acf69265cfb8806e.tar.gz gitblit-05f229883c4e15e044c5c103acf69265cfb8806e.zip |
Add a basic SSH public key management UI
Diffstat (limited to 'src/main/java/com/gitblit/manager/RuntimeManager.java')
-rw-r--r-- | src/main/java/com/gitblit/manager/RuntimeManager.java | 39 |
1 files changed, 36 insertions, 3 deletions
diff --git a/src/main/java/com/gitblit/manager/RuntimeManager.java b/src/main/java/com/gitblit/manager/RuntimeManager.java index 52f4d67b..9cdc64eb 100644 --- a/src/main/java/com/gitblit/manager/RuntimeManager.java +++ b/src/main/java/com/gitblit/manager/RuntimeManager.java @@ -119,9 +119,42 @@ public class RuntimeManager implements IRuntimeManager { */ @Override public boolean isServingRepositories() { - return settings.getBoolean(Keys.git.enableGitServlet, true) - || (settings.getInteger(Keys.git.daemonPort, 0) > 0) - || (settings.getInteger(Keys.git.sshPort, 0) > 0); + return isServingHTTP() + || isServingGIT() + || isServingSSH(); + } + + /** + * Determine if this Gitblit instance is actively serving git repositories + * over the HTTP protocol. + * + * @return true if Gitblit is serving repositories over the HTTP protocol + */ + @Override + public boolean isServingHTTP() { + return settings.getBoolean(Keys.git.enableGitServlet, true); + } + + /** + * Determine if this Gitblit instance is actively serving git repositories + * over the Git Daemon protocol. + * + * @return true if Gitblit is serving repositories over the Git Daemon protocol + */ + @Override + public boolean isServingGIT() { + return settings.getInteger(Keys.git.daemonPort, 0) > 0; + } + + /** + * Determine if this Gitblit instance is actively serving git repositories + * over the SSH protocol. + * + * @return true if Gitblit is serving repositories over the SSH protocol + */ + @Override + public boolean isServingSSH() { + return settings.getInteger(Keys.git.sshPort, 0) > 0; } /** |