@@ -6,7 +6,7 @@ | |||
git.allowPushPull = true | |||
# Base folder for repositories | |||
# Use forward slashes on Windows!! | |||
# Use forward slashes even on Windows!! | |||
git.repositoriesFolder = c:/projects/git | |||
# Export all repositories | |||
@@ -14,6 +14,7 @@ git.repositoriesFolder = c:/projects/git | |||
git.exportAll = true | |||
# Search repositories folder for nested repositories | |||
# e.g. /libraries/mylibrary.git | |||
git.nestedRepositories = true | |||
# The root clone url | |||
@@ -38,6 +39,7 @@ server.realmFile = users.properties | |||
# | |||
# Git:Blit Web Settings | |||
# | |||
# If blank Git:Blit is displayed. | |||
web.siteName = | |||
# If web.authenticate=true, users with "admin" role can create repositories, | |||
@@ -52,8 +54,7 @@ web.allowAdministration = true | |||
web.repositoriesMessage = gitblit | |||
# Use the client timezone when formatting dates. | |||
# This uses AJAX to determine the browser's timezone and enables Wicket | |||
# session management for the connection. | |||
# This uses AJAX to determine the browser's timezone. | |||
web.useClientTimezone = false | |||
# Date and Time formats | |||
@@ -134,7 +135,7 @@ server.log4jPattern.linux = | |||
server.useNio = true | |||
# Standard http port to serve. <= 0 disables this connector. | |||
server.httpPort = 0 | |||
server.httpPort = 80 | |||
# Secure/SSL https port to serve. <= 0 disables this connector. | |||
server.httpsPort = 443 |
@@ -170,7 +170,7 @@ public class GitBlitServer { | |||
if (params.securePort > 0) { | |||
File keystore = new File("keystore"); | |||
if (!keystore.exists()) { | |||
logger.info("Generating self-signed ssl certificate"); | |||
logger.info("Generating self-signed SSL certificate"); | |||
generateSelfSignedCertificate("localhost", keystore, params.storePassword); | |||
} | |||
if (keystore.exists()) { | |||
@@ -331,7 +331,7 @@ public class GitBlitServer { | |||
SslSocketConnector ssl = new SslSocketConnector(); | |||
connector = ssl; | |||
} | |||
connector.setAllowRenegotiate(true); | |||
connector.setAllowRenegotiate(false); | |||
connector.setKeystore(keystore.getAbsolutePath()); | |||
connector.setPassword(password); | |||
connector.setPort(port); |
@@ -1,51 +0,0 @@ | |||
package com.gitblit; | |||
import java.io.File; | |||
import org.eclipse.jgit.api.Git; | |||
import org.eclipse.jgit.api.InitCommand; | |||
import com.beust.jcommander.JCommander; | |||
import com.beust.jcommander.Parameter; | |||
import com.beust.jcommander.ParameterException; | |||
import com.beust.jcommander.Parameters; | |||
public class MakeRepository { | |||
public static void main(String... args) throws Exception { | |||
Params params = new Params(); | |||
JCommander jc = new JCommander(params); | |||
try { | |||
jc.parse(args); | |||
if (params.help) | |||
jc.usage(); | |||
} catch (ParameterException t) { | |||
jc.usage(); | |||
} | |||
File directory = new File(params.create); | |||
InitCommand init = new InitCommand(); | |||
init.setDirectory(directory); | |||
init.setBare(true); | |||
Git git = init.call(); | |||
git.getRepository().close(); | |||
System.out.println("GIT repository " + directory.getCanonicalPath() + " created."); | |||
} | |||
@Parameters(separators = " ") | |||
private static class Params { | |||
/* | |||
* Help/Usage | |||
*/ | |||
@Parameter(names = { "-h", "--help" }, description = "Show this help") | |||
public Boolean help = false; | |||
/* | |||
* Repository to Create | |||
*/ | |||
@Parameter(names = { "--create" }, description = "GIT Repository to Create", required = true) | |||
public String create = ""; | |||
} | |||
} |