diff --git a/manifests/init.pp b/manifests/init.pp index 3d035ae..d101732 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -14,6 +14,8 @@ # eg., https://review.example.com/ # git_http_url: # Optional base URL for repositories available over the HTTP protocol +# canonical_git_url: +# URL for repositories available over the anonymous git protocol # ssl_cert_file: # ssl_key_file: # Used in the Apache virtual host to specify the SSL cert and key files. @@ -130,6 +132,7 @@ class gerrit( $redirect_to_canonicalweburl = true, $canonicalweburl = "https://${::fqdn}/", $git_http_url = '', + $canonical_git_url = '', $robots_txt_source = '', # If left empty, the gerrit default will be used. $serveradmin = "webmaster@${::fqdn}", $ssl_cert_file = '/etc/ssl/certs/ssl-cert-snakeoil.pem', @@ -342,6 +345,7 @@ class gerrit( # - $mysql_host # - $canonicalweburl # - $git_http_url + # - $canonical_git_url # - $smtpserver # - $sendemail_from # - $sendemail_include_diff diff --git a/templates/gerrit.config.erb b/templates/gerrit.config.erb index 841dcc4..aa96d78 100644 --- a/templates/gerrit.config.erb +++ b/templates/gerrit.config.erb @@ -10,6 +10,9 @@ <% if @git_http_url != "" -%> gitHttpUrl = <%= @git_http_url %> <% end -%> +<% if @canonical_git_url != "" -%> + canonicalGitUrl = <%= @canonical_git_url %> +<% end -%> [database] type = MYSQL hostname = <%= @mysql_host %>