#3688 Document the configuration keys for repoSpanner
Merged 5 years ago by pingou. Opened 5 years ago by pingou.

file modified
+80
@@ -1456,6 +1456,86 @@ 

  Defaults to: ``True``

  

  

+ RepoSpanner Options

+ -------------

+ 

+ Pagure can be integrated with `repoSpanner <https://repospanner.org>`_

+ allowing to deploy pagure in a load-balanced environment since the git

+ repositories are then synced accross multiple servers simultaneously.

+ 

+ Support for this integration has been included in Pagure version 5.0 and higher.

+ 

+ Here below are the different options one can/should use to integrate pagure

+ with repoSpanner.

+ 

+ REPOSPANNER_NEW_REPO

+ ~~~~~~~~~~~~~~~~~~~~

+ 

+ This configuration key instructs pagure to create new git repositories on

+ repoSpanner or not.

+ Its value should be the region in which the new git repositories should be

+ created on.

+ 

+ Defaults to: ``None``.

+ 

+ REPOSPANNER_NEW_REPO_ADMIN_OVERRIDE

+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

+ 

+ This configuration key can be used to let pagure admin override the default

+ region used when creating new git repositories on repoSpanner.

+ Its value should be a boolean.

+ 

+ Defaults to: ``False``

+ 

+ REPOSPANNER_NEW_FORK

+ ~~~~~~~~~~~~~~~~~~~~

+ 

+ This configuration key instructs pagure on where/how to create new git

+ repositories for the forks with repoSpanner.

+ If ``None``, git repositories for forks are created outside of repoSpanner

+ entirely.

+ If ``True``, git repositories for forks are created in the same region as

+ the parent project.

+ Otherwise, a region can be directly specified where git repositories for

+ forks will be created.

+ 

+ Defaults to: ``True``

+ 

+ REPOSPANNER_ADMIN_MIGRATION

+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~

+ 

+ This configuration key can be used to let admin manually migrate individual

+ project into repoSpanner once it is set up.

+ 

+ Defaults to: ``False``

+ 

+ REPOSPANNER_REGIONS

+ ~~~~~~~~~~~~~~~~~~~

+ 

+ This configuration key allows to specify the different region where repoSpanner

+ is deployed and thus with which this pagure instance can be integrated.

+ 

+ An example entry could look like:

+ 

+ ::

+ 

+     REPOSPANNER_REGIONS = {

+         'default': {'url': 'https://nodea.regiona.repospanner.local:8444',

+                     'repo_prefix': 'pagure/',

+                     'hook': None,

+                     'ca': '/etc/pki/repospanner/pki/ca.crt',

+                     'admin_cert': {'cert': '/etc/pki/repospanner/pki/admin.crt',

+                                    'key': '/etc/pki/repospanner/pki/admin.key'},

+                     'push_cert': {'cert': '/etc/pki/repospanner/pki/pagure.crt',

+                                   'key': '/etc/pki/repospanner/pki/pagure.key'}}

+     }

+ 

+ If this configuration key is not defined, pagure will consider that it is

+ not set to be integrated with repoSpanner.

+ 

+ Defaults to: ``{}``

+ 

+ 

  Deprecated configuration keys

  -----------------------------

  

@@ -82,8 +82,10 @@ 

              href="#giveproject-tab" role="tab" aria-controls="giveproject">Give Project</a>

            {% endif %}

  

+           {% if config.get('REPOSPANNER_REGIONS') %}

            <a class="nav-item nav-link" id="repospanner-tab" data-toggle="tab"

              href="#repospanner" role="tab" aria-controls="repospanner">repoSpanner state</a>

+           {% endif %}

  

            {% if (not repo.is_fork and config.get('ENABLE_DEL_PROJECTS', True))

              or
@@ -1160,9 +1162,11 @@ 

            </div>

            {% endif %}

  

+           {% if config.get('REPOSPANNER_REGIONS') %}

            <div class="tab-pane fade" id="repospanner" role="tabpanel" aria-labelledby="repospanner-tab">

                {% include 'settings_repospanner.html' %}

            </div>

+           {% endif %}

  

  

      {% if (not repo.is_fork and config.get('ENABLE_DEL_PROJECTS', True))

@@ -3,11 +3,18 @@ 

  </h3>

  <div class="row">

    <div class="col">

+     <p>

+       <a href="https://repospanner.org">repoSpanner</a> is

+       a distributed git storage server allowing to keep in sync multiple git

+       repositories in multiple locations.

+     </p>

+     <p>

      {% if repo.is_on_repospanner %}

        This repository is on repoSpanner region {{ repo.repospanner_region }}

      {% else %}

        This repository is NOT yet on repoSpanner

        {% if pagure_admin and config.get('REPOSPANNER_ADMIN_MIGRATION') %}

+     </p>

    </div>

  </div>

  <div class="row">

There's a website URL: https://repospanner.org

We should use this, even though it currently redirects to GitHub.

This is better wording, I think: Support for this integration has been included in Pagure version 5.0 and higher.

2 new commits added

  • Only show the repoSpanner tab if pagure is configured for it
  • Document repoSpanner in its tab in the settings
5 years ago

3 new commits added

  • Only show the repoSpanner tab if pagure is configured for it
  • Document repoSpanner in its tab in the settings
  • Document the configuration keys for repoSpanner
5 years ago

rebased onto 92d3c8921870d6f9ac67f60e613aaea8fe0555a3

5 years ago

rebased onto b9acae2

5 years ago

Looks reasonable to me for just config reference.

Pull-Request has been merged by pingou

5 years ago