configuration.rst 58 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083
  1. Configuration
  2. =============
  3. Pagure offers a wide varieties of options that must or can be used to
  4. adjust its behavior.
  5. All of these options can be edited or added to your configuration file.
  6. If you have installed pagure, this configuration file is likely located in
  7. ``/etc/pagure/pagure.cfg``. Otherwise, it will depend on your
  8. setup/deployment.
  9. Must options
  10. ------------
  11. Here are the options you must set up in order to get pagure running.
  12. SECRET_KEY
  13. ~~~~~~~~~~
  14. This configuration key is used by flask to create the session. It should be kept secret
  15. and set as a long and random string.
  16. SALT_EMAIL
  17. ~~~~~~~~~~
  18. This configuration key is used to ensure that when sending
  19. notifications to different users, each one of them has a different, unique
  20. and unfakeable ``Reply-To`` header. This header is then used by the milter to find
  21. out if the response received is a real one or a fake/invalid one.
  22. DB_URL
  23. ~~~~~~
  24. This configuration key indicates to the framework how and where to connect to the database
  25. server. Pagure uses `SQLAchemy <http://www.sqlalchemy.org/>`_ to connect
  26. to a wide range of database server including MySQL, PostgreSQL, and SQLite.
  27. Examples values:
  28. ::
  29. DB_URL = 'mysql://user:pass@host/db_name'
  30. DB_URL = 'postgres://user:pass@host/db_name'
  31. DB_URL = 'sqlite:////var/tmp/pagure_dev.sqlite'
  32. Defaults to ``sqlite:////var/tmp/pagure_dev.sqlite``
  33. APP_URL
  34. ~~~~~~~
  35. This configuration key indicates the URL at which this pagure instance will be made available.
  36. Defaults to: ``http://localhost.localdomain/``
  37. EMAIL_ERROR
  38. ~~~~~~~~~~~
  39. Pagure sends email when it catches an unexpected error (which saves you from
  40. having to monitor the logs regularly; but if you like, the error is still
  41. present in the logs).
  42. This configuration key allows you to specify to which email address to send
  43. these error reports.
  44. GIT_URL_SSH
  45. ~~~~~~~~~~~
  46. This configuration key provides the information to the user on how to clone
  47. the git repos hosted on pagure via `SSH <https://en.wikipedia.org/wiki/Secure_Shell>`_.
  48. The URL should end with a slash ``/``.
  49. Defaults to: ``'ssh://git@llocalhost.localdomain/'``
  50. .. note:: If you are using a custom setup for your deployment where every
  51. user has an account on the machine you may want to tweak this URL
  52. to include the username. If that is the case, you can use
  53. ``{username}`` in the URL and it will be expanded to the username
  54. of the user viewing the page when rendered.
  55. For example: ``'ssh://{username}@pagure.org/'``
  56. GIT_URL_GIT
  57. ~~~~~~~~~~~
  58. This configuration key provides the information to the user on how to clone
  59. the git repos hosted on pagure anonymously. This access can be granted via
  60. the ``git://`` or ``http(s)://`` protocols.
  61. The URL should end with a slash ``/``.
  62. Defaults to: ``'git://localhost.localdomain/'``
  63. BROKER_URL
  64. ~~~~~~~~~~
  65. This configuration key is used to point celery to the broker to use. This
  66. is the broker that is used to communicate between the web application and
  67. its workers.
  68. Defaults to: ``'redis://%s' % APP.config['REDIS_HOST']``
  69. .. note:: See the :ref:`redis-section` for the ``REDIS_HOST`` configuration
  70. key
  71. Repo Directories
  72. ----------------
  73. Each project in pagure has 2 to 4 git repositories, depending on configuration
  74. of the Pagure instance (see below):
  75. - the main repo for the code
  76. - the doc repo showed in the doc server (optional)
  77. - the ticket repo storing the metadata of the tickets (optional)
  78. - the request repo storing the metadata of the pull-requests
  79. There are then another 3 folders: one for specifying the locations of the forks, one
  80. for the remote git repo used for the remotes pull-requests (ie: those coming from
  81. a project not hosted on this instance of pagure), and one for user-uploaded tarballs.
  82. GIT_FOLDER
  83. ~~~~~~~~~~
  84. This configuration key points to the folder where the git repos are stored.
  85. For every project, two to four repos are created:
  86. * a repo with source code of the project
  87. * a repo with documentation of the project
  88. (if ``ENABLE_DOCS`` is ``True``)
  89. * a repo with metadata of tickets opened against the project
  90. (if ``ENABLE_TICKETS`` is ``True``)
  91. * a repo with metadata of pull requests opened against the project
  92. Note that gitolite config value ``GL_REPO_BASE`` (if using gitolite 3)
  93. or ``$REPO_BASE`` (if using gitolite 2) **must** have exactly the same
  94. value as ``GIT_FOLDER``.
  95. REMOTE_GIT_FOLDER
  96. ~~~~~~~~~~~~~~~~~
  97. This configuration key points to the folder where the remote git repos (ie:
  98. not hosted on pagure) that someone used to open a pull-request against a
  99. project hosted on pagure are stored.
  100. UPLOAD_FOLDER_PATH
  101. ~~~~~~~~~~~~~~~~~~
  102. This configuration key points to the folder where user-uploaded tarballs
  103. are stored and served from.
  104. ATTACHMENTS_FOLDER
  105. ~~~~~~~~~~~~~~~~~~
  106. This configuration key points to the folder where attachments can be cached
  107. for easier access by the web-server (allowing to not interact with the git
  108. repo having it to serve it).
  109. UPLOAD_FOLDER_URL
  110. ~~~~~~~~~~~~~~~~~~
  111. Full URL to where the uploads are available. It is highly recommended for
  112. security reasons that this URL lives on a different domain than the main
  113. application (an entirely different domain, not just a sub-domain).
  114. Defaults to: ``/releases/``, unsafe for production!
  115. .. warning:: both `UPLOAD_FOLDER_PATH` and `UPLOAD_FOLDER_URL` must be
  116. specified for the upload release feature to work
  117. SESSION_COOKIE_SECURE
  118. ~~~~~~~~~~~~~~~~~~~~~
  119. When this is set to True, the session cookie will only be returned to the
  120. server via ssl (https). If you connect to the server via plain http, the
  121. cookie will not be sent. This prevents sniffing of the cookie contents.
  122. This may be set to False when testing your application but should always
  123. be set to True in production.
  124. Defaults to: ``False`` for development, must be ``True`` in production with
  125. https.
  126. SESSION_TYPE
  127. ~~~~~~~~~~~~
  128. Enables the `flask-session <https://pythonhosted.org/Flask-Session/>`_
  129. extension if set to a value other than ``None``. The ``flask-session``
  130. package needs to be installed and proper
  131. `configuration <https://pythonhosted.org/Flask-Session/#configuration>`_
  132. needs to be included in the Pagure config file.
  133. This is useful when the Pagure server needs to be scaled up to multiple
  134. instances, which requires the flask session keys to be shared between those.
  135. Flask-session allows you to use Redis, Memcached, relational database
  136. or MongoDB for storing shared session keys.
  137. FROM_EMAIL
  138. ~~~~~~~~~~
  139. This configuration key specifies the email address used by this pagure instance
  140. when sending emails (notifications).
  141. Defaults to: ``pagure@localhost.localdomain``
  142. DOMAIN_EMAIL_NOTIFICATIONS
  143. ~~~~~~~~~~~~~~~~~~~~~~~~~~
  144. This configuration key specifies the domain used by this pagure instance
  145. when sending emails (notifications). More precisely, it is used
  146. when building the ``msg-id`` header of the emails sent.
  147. Defaults to: ``localhost.localdomain``
  148. VIRUS_SCAN_ATTACHMENTS
  149. ~~~~~~~~~~~~~~~~~~~~~~
  150. This configuration key configures whether attachments are scanned for viruses on
  151. upload. For more information, see the install.rst guide.
  152. Defaults to: ``False``
  153. GIT_AUTH_BACKEND
  154. ^^^^^^^^^^^^^^^^
  155. This configuration key allows specifying which git auth backend to use.
  156. Git auth backends can either be static (like gitolite), where a file is
  157. generated when something changed and then used on login, or dynamic,
  158. where the actual ACLs are checked in a git hook before being applied.
  159. By default pagure provides the following backends:
  160. - `test_auth`: simple debugging backend printing and returning the string ``Called GitAuthTestHelper.generate_acls()``
  161. - `gitolite2`: allows deploying pagure on the top of gitolite 2
  162. - `gitolite3`: allows deploying pagure on the top of gitolite 3
  163. - `pagure`: Pagure git auth implementation (using keyhelper.py and aclchecker.py)
  164. Defaults to: ``gitolite3``
  165. .. note:: The option GITOLITE_BACKEND is the legacy name, and for backwards compatibility reasons will override this setting
  166. .. note:: These options can be expended, cf :ref:`custom-gitolite`.
  167. Configure Gitolite
  168. ------------------
  169. Pagure can use `gitolite <http://gitolite.com/>`_ as an authorization layer.
  170. Gitolite relies on `SSH <https://en.wikipedia.org/wiki/Secure_Shell>`_ for
  171. the authentication. In other words, SSH lets you in and gitolite checks if
  172. you are allowed to do what you are trying to do once you are inside.
  173. Pagure supports both gitolite 2 and gitolite 3 and the code generating
  174. the gitolite configuration can be customized for easier integration with
  175. other systems (cf :ref:`custom-gitolite`).
  176. **gitolite 2 and 3**
  177. ~~~~~~~~~~~~~~~~~~~~
  178. GITOLITE_HOME
  179. ^^^^^^^^^^^^^
  180. This configuration key points to the home directory of the user under which
  181. gitolite is ran.
  182. GITOLITE_KEYDIR
  183. ^^^^^^^^^^^^^^^
  184. This configuration key points to the folder where gitolite stores and accesses
  185. the public SSH keys of all the user have access to the server.
  186. Since pagure is the user interface, it is pagure that writes down the files
  187. in this directory, effectively setting up the users to be able to use gitolite.
  188. GITOLITE_CONFIG
  189. ^^^^^^^^^^^^^^^
  190. This configuration key points to the gitolite.conf file where pagure writes
  191. the gitolite repository access configuration.
  192. GITOLITE_CELERY_QUEUE
  193. ^^^^^^^^^^^^^^^^^^^^^
  194. This configuration is useful for large pagure deployment where recompiling
  195. the gitolite config file can take a long time. By default the compilation
  196. of gitolite's configuration file is done by the pagure_worker, which spawns
  197. by default 4 concurrent workers. If it takes a while to recompile the
  198. gitolite configuration file, these workers may be stepping on each others'
  199. toes.
  200. In this situation, this configuration key allows you to direct the messages
  201. asking for the gitolite configuration file to be compiled to a different
  202. queue which can then be handled by a different service/worker.
  203. Pagure provides a ``pagure_gitolite_worker.service`` systemd service file
  204. pre-configured to handles these messages if this configuration key is set
  205. to ``gitolite_queue``.
  206. **gitolite 2 only**
  207. ~~~~~~~~~~~~~~~~~~~
  208. GL_RC
  209. ^^^^^
  210. This configuration key points to the file ``gitolite.rc`` used by gitolite
  211. to record who has access to what (ie: who has access to which repo/branch).
  212. GL_BINDIR
  213. ^^^^^^^^^
  214. This configuration key indicates the folder in which the gitolite tools can
  215. be found. It can be as simple as ``/usr/bin/`` if the tools have been installed
  216. using a package manager or something like ``/opt/bin/`` for a more custom
  217. install.
  218. **gitolite 3 only**
  219. ~~~~~~~~~~~~~~~~~~~
  220. GITOLITE_HAS_COMPILE_1
  221. ^^^^^^^^^^^^^^^^^^^^^^
  222. By setting this configuration key to ``True``, you can turn on using the
  223. gitolite ``compile-1`` binary. This speeds up gitolite task when it recompiles
  224. configuration after new project is created. In order to use this, you need to
  225. have the ``compile-1`` gitolite command.
  226. There are two ways to have it,
  227. #. You distribution already has the file installed for you and you can then
  228. just use it.
  229. #. You need to download and install it yourself. We are describing what
  230. needs to be done for this here below.
  231. Installing the ``compile-1`` command:
  232. * You also have to make sure that your distribution of gitolite contains
  233. `patch <https://github.com/sitaramc/gitolite/commit/c4b6521a4b82e639f6ed776abad79c>`_
  234. which makes gitolite respect ``ALLOW_ORPHAN_GL_CONF`` configuration variable,
  235. if this patch isn't already present, you will have to make the change yourself.
  236. * In your ``gitolite.rc`` set ``ALLOW_ORPHAN_GL_CONF`` to ``1`` (you may
  237. have to add it yourself).
  238. * Still in your ``gitolite.rc`` file, uncomment ``LOCAL_CODE`` file and set
  239. it to a full path of a directory that you choose (for example
  240. ``/usr/local/share/gitolite3``).
  241. * Create a subdirectory ``commands`` under the path you picked for ``LOCAL_CODE``
  242. (in our example, you will need to do: ``mkdir -p /usr/local/share/gitolite3/commands``)
  243. * Finally, install the ``compile-1`` command in this ``commands`` subdirectory
  244. If your installation doesn't ship this file, you can `download it
  245. <https://github.com/sitaramc/gitolite/blob/master/contrib/commands/compile-1>`_.
  246. (Ensure the file is executable, otherwise gitolite will not find it)
  247. Defaults to: ``False``
  248. EventSource options
  249. -------------------
  250. EVENTSOURCE_SOURCE
  251. ~~~~~~~~~~~~~~~~~~
  252. This configuration key indicates the URL at which the EventSource server is
  253. available. If not defined, pagure will behave as if there are no EventSource
  254. server running.
  255. EVENTSOURCE_PORT
  256. ~~~~~~~~~~~~~~~~
  257. This configuration key indicates the port at which the EventSource server is
  258. running.
  259. .. note:: The EventSource server requires a redis server (see ``Redis options``
  260. below)
  261. Web-hooks notifications
  262. -----------------------
  263. WEBHOOK
  264. ~~~~~~~
  265. This configuration key allows turning on or off web-hooks notifications for
  266. this pagure instance.
  267. Defaults to: ``False``.
  268. .. note:: The Web-hooks server requires a redis server (see ``Redis options``
  269. below)
  270. .. _redis-section:
  271. Redis options
  272. -------------
  273. REDIS_HOST
  274. ~~~~~~~~~~
  275. This configuration key indicates the host at which the `redis <http://redis.io/>`_
  276. server is running.
  277. Defaults to: ``0.0.0.0``.
  278. REDIS_PORT
  279. ~~~~~~~~~~
  280. This configuration key indicates the port at which the redis server can be
  281. contacted.
  282. Defaults to: ``6379``.
  283. REDIS_DB
  284. ~~~~~~~~
  285. This configuration key indicates the name of the redis database to use for
  286. communicating with the EventSource server.
  287. Defaults to: ``0``.
  288. Authentication options
  289. ----------------------
  290. ADMIN_GROUP
  291. ~~~~~~~~~~~
  292. List of groups, either local or remote (if the openid server used supports the
  293. group extension), that are the site admins. These admins can regenerate the
  294. gitolite configuration, the ssh key files, and the hook-token for every project
  295. as well as manage users and groups.
  296. PAGURE_ADMIN_USERS
  297. ~~~~~~~~~~~~~~~~~~
  298. List of local users that are the site admins. These admins have the same rights as
  299. the users in the admin groups listed above as well as admin rights to
  300. all projects hosted on this pagure instance.
  301. Celery Queue options
  302. --------------------
  303. In order to help prioritize between tasks having a direct impact on the user
  304. experience and tasks needed to be run on the background but not directly
  305. impacting the users, we have split the generic tasks triggered by the web
  306. application into three possible queues: Fast, Medium, Slow.
  307. If none of these options are set, a single queue will be used for all tasks.
  308. FAST_CELERY_QUEUE
  309. ~~~~~~~~~~~~~~~~~
  310. This configuration key can be used to specify a dedicated queue for tasks that
  311. are triggered by the web frontend and need to be processed quickly for the
  312. best user experience.
  313. This will be used for tasks such as creating a new project, forking or
  314. merging a pull-request.
  315. Defaults to: ``None``.
  316. MEDIUM_CELERY_QUEUE
  317. ~~~~~~~~~~~~~~~~~~~
  318. This configuration key can be used to specify a dedicated queue for tasks that
  319. are triggered by the web frontend and need to be processed but aren't critical
  320. for the best user experience.
  321. This will be used for tasks such as updating a file in a git repository.
  322. Defaults to: ``None``.
  323. SLOW_CELERY_QUEUE
  324. ~~~~~~~~~~~~~~~~~
  325. This configuration key can be used to specify a dedicated queue for tasks that
  326. are triggered by the web frontend, are slow and do not impact the user
  327. experience in the user interface.
  328. This will be used for tasks such as updating the ticket git repo based on
  329. the content posted in the user interface.
  330. Defaults to: ``None``.
  331. Stomp Options
  332. -------------
  333. Pagure integration with Stomp allows you to emit messages to any
  334. stomp-compliant message bus.
  335. STOMP_NOTIFICATIONS
  336. ~~~~~~~~~~~~~~~~~~~
  337. This configuration key can be used to turn on or off notifications via
  338. `stomp protocol <https://stomp.github.io/>`_. All other stomp-related
  339. settings don't need to be present if this is set to ``False``.
  340. Defaults to: ``False``.
  341. STOMP_BROKERS
  342. ~~~~~~~~~~~~~
  343. List of 2-tuples with broker domain names and ports. For example
  344. ``[('primary.msg.bus.com', 6543), ('backup.msg.bus.com`, 6543)]``.
  345. STOMP_HIERARCHY
  346. ~~~~~~~~~~~~~~~
  347. Base name of the hierarchy to emit messages to. For example
  348. ``/queue/some.hierarchy.``. Note that this **must** end with
  349. a dot. Pagure will append queue names such as ``project.new``
  350. to this value, resulting in queue names being e.g.
  351. ``/queue/some.hierarchy.project.new``.
  352. STOMP_SSL
  353. ~~~~~~~~~
  354. Whether or not to use SSL when connecting to message brokers.
  355. Defaults to: ``False``.
  356. STOMP_KEY_FILE
  357. ~~~~~~~~~~~~~~
  358. Absolute path to key file for SSL connection. Only required if
  359. ``STOMP_SSL`` is set to ``True``.
  360. STOMP_CERT_FILE
  361. ~~~~~~~~~~~~~~~
  362. Absolute path to certificate file for SSL connection. Only required if
  363. ``STOMP_SSL`` is set to ``True``.
  364. STOMP_CREDS_PASSWORD
  365. ~~~~~~~~~~~~~~~~~~~~
  366. Password for decoding ``STOMP_CERT_FILE`` and ``STOMP_KEY_FILE``. Only
  367. required if ``STOMP_SSL`` is set to ``True`` and credentials files are
  368. password-encoded.
  369. ALWAYS_STOMP_ON_COMMITS
  370. ~~~~~~~~~~~~~~~~~~~~~~~
  371. This configuration key can be used to enforce `stomp <https://stomp.github.io/>`_
  372. notifications on commits made on all projects in a pagure instance.
  373. Defaults to: ``False``.
  374. API token ACLs
  375. --------------
  376. ACLS
  377. ~~~~
  378. This configuration key lists all the ACLs that can be associated with an API
  379. token with a short description of what the ACL allows one to do.
  380. This key it not really meant to be changed unless you really know what you
  381. are doing.
  382. USER_ACLS
  383. ~~~~~~~~~
  384. This configuration key can be used to list which of the ACLs listed in ``ACLS``
  385. can be associated with an API token of a project in the (web) user interface.
  386. Use this configuration key in combination with ``ADMIN_API_ACLS`` to disable
  387. certain ACLs for users while allowing admins to generate keys with them.
  388. Defaults to: ``[key for key in ACLS.keys() if key != 'generate_acls_project']``
  389. (ie: all the ACLs in ``ACLS`` except for ``generate_acls_project``)
  390. ADMIN_API_ACLS
  391. ~~~~~~~~~~~~~~
  392. This configuration key can be used to list which of the ACLs listed in ``ACLS``
  393. can be generated by the ``pagure-admin`` CLI tool by admins.
  394. Defaults to: ``['issue_comment', 'issue_create', 'issue_change_status', 'pull_request_flag', 'pull_request_comment', 'pull_request_merge', 'generate_acls_project', 'commit_flag', 'create_branch']``
  395. CROSS_PROJECT_ACLS
  396. ~~~~~~~~~~~~~~~~~~
  397. This configuration key can be used to list which of the ACLs listed in ``ACLS``
  398. can be associated with a project-less API token in the (web) user interface.
  399. These project-less API tokens can be generated in the user's settings page
  400. and allows action in multiple projects instead of being restricted to a
  401. specific one.
  402. Defaults to: ``['create_project', 'fork_project', 'modify_project']``
  403. Optional options
  404. ----------------
  405. Theming
  406. ~~~~~~~
  407. THEME
  408. ^^^^^
  409. This configuration key allows you to specify the theme to be used. The
  410. string specified is the name of the theme directory in ``pagure/themes/``
  411. For more information about theming see the :doc:`usage/theming`
  412. Default options:
  413. - ``chameleon`` The OpenSUSE theme for pagure
  414. - ``default`` The default theme for pagure
  415. - ``pagureio`` The theme used at https://pagure.io
  416. - ``srcfpo`` The theme used at https://src.fedoraproject.org
  417. Defaults to: ``default``
  418. Git repository templates
  419. ~~~~~~~~~~~~~~~~~~~~~~~~
  420. PROJECT_TEMPLATE_PATH
  421. ^^^^^^^^^^^^^^^^^^^^^
  422. This configuration key allows you to specify the path to a git repository
  423. to use as a template when creating new repository for new projects.
  424. This template will not be used for forks nor any of the git repository but
  425. the one used for the sources (ie: it will not be used for the tickets,
  426. requests or docs repositories).
  427. FORK_TEMPLATE_PATH
  428. ^^^^^^^^^^^^^^^^^^
  429. This configuration key allows you to specify the path to a git repository
  430. to use as a template when creating new repository for new forks.
  431. This template will not be used for any of the git repository but
  432. the one used for the sources of forks (ie: it will not be used for the
  433. tickets, requests or docs repositories).
  434. SSH_KEYS
  435. ~~~~~~~~
  436. It is a good practice to publish the fingerprint and public SSH key of a
  437. server you provide access to.
  438. Pagure offers the possibility to expose this information based on the values
  439. set in the configuration file, in the ``SSH_KEYS`` configuration key.
  440. See the `SSH hostkeys/Fingerprints page on pagure.io <https://pagure.io/ssh_info>`_.
  441. .. warning: The format is important
  442. SSH_KEYS = {'RSA': {'fingerprint': '<foo>', 'pubkey': '<bar>'}}
  443. Where `<foo>` and `<bar>` must be replaced by your values.
  444. CSP_HEADERS
  445. ~~~~~~~~~~~
  446. Content Security Policy (CSP) is a computer security standard introduced to
  447. prevent cross-site scripting (XSS), clickjacking and other code injection
  448. attacks resulting from execution of malicious content in the trusted web page
  449. context
  450. Source: https://en.wikipedia.org/wiki/Content_Security_Policy
  451. Defaults to:
  452. ::
  453. CSP_HEADERS = (
  454. "default-src 'self' https:; "
  455. "script-src 'self' 'nonce-{nonce}'; "
  456. "style-src 'self' 'nonce-{nonce}'"
  457. )
  458. Where ``{nonce}`` is dynamically set by pagure.
  459. LOGGING
  460. ~~~~~~~
  461. This configuration key allows you to set up the logging of the application.
  462. It relies on the standard `python logging module
  463. <https://docs.python.org/2/library/logging.html>`_.
  464. The default value is:
  465. ::
  466. LOGGING = {
  467. 'version': 1,
  468. 'disable_existing_loggers': False,
  469. 'formatters': {
  470. 'standard': {
  471. 'format': '%(asctime)s [%(levelname)s] %(name)s: %(message)s'
  472. },
  473. 'email_format': {
  474. 'format': MSG_FORMAT
  475. }
  476. },
  477. 'filters': {
  478. 'myfilter': {
  479. '()': ContextInjector,
  480. }
  481. },
  482. 'handlers': {
  483. 'console': {
  484. 'level': 'INFO',
  485. 'formatter': 'standard',
  486. 'class': 'logging.StreamHandler',
  487. 'stream': 'ext://sys.stdout',
  488. },
  489. 'email': {
  490. 'level': 'ERROR',
  491. 'formatter': 'email_format',
  492. 'class': 'logging.handlers.SMTPHandler',
  493. 'mailhost': 'localhost',
  494. 'fromaddr': 'pagure@localhost',
  495. 'toaddrs': 'root@localhost',
  496. 'subject': 'ERROR on pagure',
  497. 'filters': ['myfilter'],
  498. },
  499. },
  500. # The root logger configuration; this is a catch-all configuration
  501. # that applies to all log messages not handled by a different logger
  502. 'root': {
  503. 'level': 'INFO',
  504. 'handlers': ['console'],
  505. },
  506. 'loggers': {
  507. 'pagure': {
  508. 'handlers': ['console'],
  509. 'level': 'DEBUG',
  510. 'propagate': True
  511. },
  512. 'flask': {
  513. 'handlers': ['console'],
  514. 'level': 'INFO',
  515. 'propagate': False
  516. },
  517. 'sqlalchemy': {
  518. 'handlers': ['console'],
  519. 'level': 'WARN',
  520. 'propagate': False
  521. },
  522. 'binaryornot': {
  523. 'handlers': ['console'],
  524. 'level': 'WARN',
  525. 'propagate': True
  526. },
  527. 'pagure.lib.encoding_utils': {
  528. 'handlers': ['console'],
  529. 'level': 'WARN',
  530. 'propagate': False
  531. },
  532. }
  533. }
  534. .. note:: as you can see there is an ``email`` handler defined. It's not used
  535. anywhere by default but you can use it to get report of errors by email
  536. and thus monitor your pagure instance.
  537. To do this the easiest is to set, on the ``root`` logger:
  538. ::
  539. 'handlers': ['console', 'email'],
  540. ITEM_PER_PAGE
  541. ~~~~~~~~~~~~~
  542. This configuration key allows you to configure the length of a page by
  543. setting the number of items on the page. Items can be commits, users, groups,
  544. or projects for example.
  545. Defaults to: ``50``.
  546. PR_TARGET_MATCHING_BRANCH
  547. ~~~~~~~~~~~~~~~~~~~~~~~~~
  548. If set to ``True``, the default target branch for all pull requests in UI
  549. is the branch that is longest substring of the branch that the pull request
  550. is created from. For example, a ``mybranch`` branch in original repo will
  551. be the default target of a pull request from branch ``mybranch-feature-1``
  552. in a fork when opening a new pull request. If this is set to ``False``,
  553. the default branch of the repo will be the default target of all pull requests.
  554. Defaults to: ``False``.
  555. SSH_ACCESS_GROUPS
  556. ~~~~~~~~~~~~~~~~~
  557. Some instances of pagure are deployed in such a way that only the members of
  558. certain groups are allowed to commit via ssh. This configuration key allows
  559. to specify which groups have commit access and thus let pagure hide the ssh
  560. URL from the drop-down "Clone" menu for all the person who are not in one of
  561. these groups.
  562. If this configuration key is not defined or left empty, it is assume that there
  563. is no such group restriction and everyone can commit via ssh (default behavior).
  564. Defaults to: ``[]``
  565. SMTP configuration
  566. ~~~~~~~~~~~~~~~~~~
  567. SMTP_SERVER
  568. ^^^^^^^^^^^
  569. This configuration key specifies the SMTP server to use when
  570. sending emails.
  571. Defaults to: ``localhost``.
  572. SMTP_PORT
  573. ^^^^^^^^^
  574. This configuration key specifies the SMTP server port.
  575. SMTP by default uses TCP port 25. The protocol for mail submission is
  576. the same, but uses port 587.
  577. SMTP connections secured by SSL, known as SMTPS, default to port 465
  578. (nonstandard, but sometimes used for legacy reasons).
  579. Defaults to: ``25``
  580. SMTP_SSL
  581. ^^^^^^^^
  582. This configuration key specifies whether the SMTP connections
  583. should be secured over SSL.
  584. Defaults to: ``False``
  585. SMTP_USERNAME
  586. ^^^^^^^^^^^^^
  587. This configuration key allows usage of SMTP with auth.
  588. Note: Specify SMTP_USERNAME and SMTP_PASSWORD for using SMTP auth
  589. Defaults to: ``None``
  590. SMTP_PASSWORD
  591. ^^^^^^^^^^^^^
  592. This configuration key allows usage of SMTP with auth.
  593. Note: Specify SMTP_USERNAME and SMTP_PASSWORD for using SMTP auth
  594. Defaults to: ``None``
  595. SHORT_LENGTH
  596. ~~~~~~~~~~~~
  597. This configuration key specifies the length of the commit ids or
  598. file hex displayed in the user interface.
  599. Defaults to: ``6``.
  600. BLACKLISTED_PROJECTS
  601. ~~~~~~~~~~~~~~~~~~~~
  602. This configuration key specifies a list of project names that are forbidden.
  603. This list is used for example to avoid conflicts at the URL level between the
  604. static files located under ``/static/`` and a project that would be named
  605. ``static`` and thus be located at ``/static``.
  606. Defaults to:
  607. ::
  608. [
  609. 'static', 'pv', 'releases', 'new', 'api', 'settings',
  610. 'logout', 'login', 'users', 'groups', 'about'
  611. ]
  612. CHECK_SESSION_IP
  613. ~~~~~~~~~~~~~~~~
  614. This configuration key specifies whether to check the user's IP
  615. address when retrieving its session. This makes things more secure but
  616. under certain setups it might not work (for example if there
  617. are proxies in front of the application).
  618. Defaults to: ``True``.
  619. PAGURE_AUTH
  620. ~~~~~~~~~~~~
  621. This configuration key specifies which authentication method to use.
  622. Valid options are ``fas``, ``openid``, ``oidc``, or ``local``.
  623. * ``fas`` uses the Fedora Account System `FAS <https://admin.fedoraproject.org/accounts>`
  624. to provide user authentication and enforces that users sign the FPCA.
  625. * ``openid`` uses OpenID authentication. Any provider may be used by
  626. changing the FAS_OPENID_ENDPOINT configuration key. By default
  627. FAS (without FPCA) will be used.
  628. * ``oidc`` enables OpenID Connect using any provider. This provider requires
  629. the configuration options starting with ``OIDC_`` (see below) to be provided.
  630. * ``local`` causes pagure to use the local pagure database for user management.
  631. Defaults to: ``local``.
  632. OIDC Settings
  633. ~~~~~~~~~~~~~
  634. .. note:: Pagure uses `flask-oidc <https://github.com/puiterwijk/flask-oidc/>`_
  635. to support OIDC authentication. This extension has a `number of configuration
  636. keys <http://flask-oidc.readthedocs.io/en/latest/#settings-reference>`_
  637. that may be useful depending on your set-up
  638. OIDC_CLIENT_SECRETS
  639. ^^^^^^^^^^^^^^^^^^^
  640. Provide a path to client secrets file on local filesystem. This file can be
  641. obtained from your OpenID Connect identity provider. Note that some providers
  642. don't fill in ``userinfo_uri``. If that is the case, you need to add it to
  643. the secrets file manually.
  644. OIDC_ID_TOKEN_COOKIE_SECURE
  645. ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  646. When this is set to True, the cookie with OpenID Connect Token will only be
  647. returned to the server via ssl (https). If you connect to the server via plain
  648. http, the cookie will not be sent. This prevents sniffing of the cookie contents.
  649. This may be set to False when testing your application but should always
  650. be set to True in production.
  651. Defaults to: ``True`` for production with https, can be set to ``False`` for
  652. convenient development.
  653. OIDC_SCOPES
  654. ^^^^^^^^^^^
  655. List of `OpenID Connect scopes http://openid.net/specs/openid-connect-core-1_0.html#ScopeClaims`
  656. to request from identity provider.
  657. OIDC_PAGURE_EMAIL
  658. ^^^^^^^^^^^^^^^^^
  659. Name of key of user's email in userinfo JSON returned by identity provider.
  660. OIDC_PAGURE_FULLNAME
  661. ^^^^^^^^^^^^^^^^^^^^
  662. Name of key of user's full name in userinfo JSON returned by identity provider.
  663. OIDC_PAGURE_USERNAME
  664. ^^^^^^^^^^^^^^^^^^^^
  665. Name of key of user's preferred username in userinfo JSON returned by identity
  666. provider.
  667. OIDC_PAGURE_SSH_KEY
  668. ^^^^^^^^^^^^^^^^^^^
  669. Name of key of user's ssh key in userinfo JSON returned by identity provider.
  670. OIDC_PAGURE_GROUPS
  671. ^^^^^^^^^^^^^^^^^^
  672. Name of key of user's groups in userinfo JSON returned by identity provider.
  673. OIDC_PAGURE_USERNAME_FALLBACK
  674. ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  675. This specifies fallback for getting username assuming ``OIDC_PAGURE_USERNAME``
  676. is empty - can be ``email`` (to use the part before ``@``) or ``sub``
  677. (IdP-specific user id, can be a nickname, email or a numeric ID
  678. depending on identity provider).
  679. IP_ALLOWED_INTERNAL
  680. ~~~~~~~~~~~~~~~~~~~
  681. This configuration key specifies which IP addresses are allowed
  682. to access the internal API endpoint. These endpoints are accessed by the
  683. milters for example and allow performing actions in the name of someone else
  684. which is sensitive, thus the origin of the request using
  685. these endpoints is validated.
  686. Defaults to: ``['127.0.0.1', 'localhost', '::1']``.
  687. MAX_CONTENT_LENGTH
  688. ~~~~~~~~~~~~~~~~~~
  689. This configuration key specifies the maximum file size allowed when
  690. uploading content to pagure (for example, screenshots to a ticket).
  691. Defaults to: ``4 * 1024 * 1024`` which corresponds to 4 megabytes.
  692. ENABLE_TICKETS
  693. ~~~~~~~~~~~~~~
  694. This configuration key activates or deactivates the ticketing system
  695. for all the projects hosted on this pagure instance.
  696. Defaults to: ``True``
  697. ENABLE_TICKETS_NAMESPACE
  698. ~~~~~~~~~~~~~~~~~~~~~~~~
  699. This configuration key can be used to restrict the namespace in which the ticketing
  700. system is enabled.
  701. So if your pagure instance has ``ENABLE_TICKETS`` as ``True`` and sets
  702. ``ENABLE_TICKETS_NAMESPACE`` to ``['tests', 'infra']`` only the projects opened
  703. in these two namespaces will have the ticketing system enabled. All the other
  704. namespaces will not.
  705. Defaults to: ``[]``
  706. ENABLE_DOCS
  707. ~~~~~~~~~~~
  708. This configuration key activates or deactivates creation of git repos
  709. for documentation for all the projects hosted on this pagure instance.
  710. Defaults to: ``True``
  711. ENABLE_NEW_PROJECTS
  712. ~~~~~~~~~~~~~~~~~~~
  713. This configuration key permits or forbids creation of new projects via
  714. the user interface and the API of this pagure instance.
  715. Defaults to: ``True``
  716. ENABLE_UI_NEW_PROJECTS
  717. ~~~~~~~~~~~~~~~~~~~~~~
  718. This configuration key permits or forbids creation of new projects via
  719. the user interface (only) of this pagure instance. It allows forbidding
  720. to create new project in the user interface while letting a set of trusted
  721. person to create projects via the API granted they have the API token with
  722. the corresponding ACL.
  723. Defaults to: ``True``
  724. ENABLE_DEL_PROJECTS
  725. ~~~~~~~~~~~~~~~~~~~
  726. This configuration key permits or forbids deletion of projects via
  727. the user interface of this pagure instance.
  728. Defaults to: ``True``
  729. ENABLE_DEL_FORKS
  730. ~~~~~~~~~~~~~~~~
  731. This configuration key permits or forbids deletion of forks via
  732. the user interface of this pagure instance.
  733. Defaults to: ``ENABLE_DEL_PROJECTS``
  734. GIT_HOOK_DB_RO
  735. ~~~~~~~~~~~~~~
  736. This configuration key specifies if the git hook have a read-only (RO) access
  737. to the database or not.
  738. Some pagure deployment provide an actual shell account on the host and thus the
  739. git hook called upon git push are executed under that account. If the user
  740. manages to by-pass git and is able to access the configuration file, they could
  741. have access to "private" information. So in those deployments the git hooks
  742. have a specific configuration file with a database access that is read-only,
  743. making pagure behave differently in those situations.
  744. Defaults to: ``False``
  745. EMAIL_SEND
  746. ~~~~~~~~~~
  747. This configuration key enables or disables all email notifications for
  748. this pagure instance. This can be useful to turn off when developing on
  749. pagure, or for test or pre-production instances.
  750. Defaults to: ``False``.
  751. .. note::
  752. This does not disable emails to the email address set in ``EMAIL_ERROR``.
  753. FEDMSG_NOTIFICATIONS
  754. ~~~~~~~~~~~~~~~~~~~~
  755. This configuration key can be used to turn on or off notifications via `fedmsg
  756. <http://www.fedmsg.com/>`_.
  757. Defaults to: ``False``.
  758. FEDORA_MESSAGING_NOTIFICATIONS
  759. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  760. This configuration key can be used to turn on or off sending notifications via
  761. `fedora-messaging <>`_.
  762. Defaults to: ``False``.
  763. ALWAYS_FEDMSG_ON_COMMITS
  764. ~~~~~~~~~~~~~~~~~~~~~~~~
  765. This configuration key can be used to enforce `fedmsg <http://www.fedmsg.com/>`_
  766. notifications on commits made on all projects in a pagure instance.
  767. Defaults to: ``True``.
  768. ALLOW_DELETE_BRANCH
  769. ~~~~~~~~~~~~~~~~~~~
  770. This configuration keys enables or disables allowing users to delete git
  771. branches from the user interface. In sensible pagure instance you may
  772. want to turn this off and with a customized gitolite configuration you can
  773. prevent users from deleting branches in their git repositories.
  774. Defaults to: ``True``.
  775. ALLOW_ADMIN_IGNORE_EXISTING_REPOS
  776. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  777. This enables a checkbox "Ignore existing repos" for admins when creating a new
  778. project. When this is checkbox is checked, existing repositories will not cause
  779. project creation to fail.
  780. This could be used to assume responsibility of existing repositories.
  781. Defaults to: ``False``.
  782. USERS_IGNORE_EXISTING_REPOS
  783. ~~~~~~~~~~~~~~~~~~~~~~~~~~~
  784. List of users who can al create a project while ignoring existing repositories.
  785. Defaults to: ``[]``.
  786. LOCAL_SSH_KEY
  787. ~~~~~~~~~~~~~
  788. This configuration key can be used to let pagure administrate the user's ssh keys
  789. or have a third party tool do it for you.
  790. In most cases, it will be fine to let pagure handle it.
  791. Defaults to ``True``.
  792. DEPLOY_KEY
  793. ~~~~~~~~~~
  794. This configuration key can be used to disable the deploy keys feature of an
  795. entire pagure instance. This feature enable to add extra public ssh keys
  796. that a third party could use to push to a project.
  797. Defaults to ``True``.
  798. OLD_VIEW_COMMIT_ENABLED
  799. ~~~~~~~~~~~~~~~~~~~~~~~
  800. In version 1.3, pagure changed its URL scheme to view the commit of a
  801. project in order to add support for pseudo-namespaced projects.
  802. For pagure instances older than 1.3, who care about backward compatibility,
  803. we added an endpoint ``view_commit_old`` that brings URL backward
  804. compatibility for URLs using the complete git hash (the 40 characters).
  805. For URLs using a shorter hash, the URLs will remain broken.
  806. This configuration key enables or disables this backward compatibility
  807. which is useful for pagure instances running since before 1.3 but is not
  808. for newer instances.
  809. Defaults to: ``False``.
  810. DISABLE_REMOTE_PR
  811. ~~~~~~~~~~~~~~~~~
  812. In some pagure deployments remote pull requests need to be disabled
  813. due to legal / policy reasons.
  814. Defaults to: ``False``.
  815. PAGURE_CI_SERVICES
  816. ~~~~~~~~~~~~~~~~~~
  817. Pagure can be configure to integrate results of a Continuous Integration (CI)
  818. service to pull-requests open against a project.
  819. To enable this integration, follow the documentation on how to install
  820. pagure-ci and set this configuration key to ``['jenkins']`` (Jenkins being
  821. the only CI service supported at the moment).
  822. Defaults to: ``None``.
  823. .. warning:: Requires `Redis` to be configured and running.
  824. INSTANCE_NAME
  825. ~~~~~~~~~~~~~
  826. This allows giving a name to this running instance of pagure. The name is
  827. then used in the welcome screen shown upon first login.
  828. Defaults to: ``Pagure``
  829. .. note: the welcome screen currently does not work with the `local`
  830. authentication.
  831. ADMIN_EMAIL
  832. ~~~~~~~~~~~
  833. This configuration key allows you to change the default administrator email
  834. which is displayed on the "about" page. It can also be used elsewhere.
  835. Defaults to: ``root@localhost.localdomain``
  836. USER_NAMESPACE
  837. ~~~~~~~~~~~~~~
  838. This configuration key can be used to enforce that project are namespaced under
  839. the user's username, behaving in this way in a similar fashion as github.com
  840. or gitlab.com.
  841. Defaults to: ``False``
  842. DOC_APP_URL
  843. ~~~~~~~~~~~
  844. This configuration key allows you to specify where the documentation server
  845. is running (preferably in a different domain name entirely).
  846. If not set, the documentation page will show an error message saying that
  847. this pagure instance does not have a documentation server.
  848. Defaults to: ``None``
  849. PRIVATE_PROJECTS
  850. ~~~~~~~~~~~~~~~~
  851. This configuration key allows you to host private repositories. These
  852. repositories are visible only to the creator of the repository and to the
  853. users who are given access to the repository. No information is leaked about the
  854. private repository which means redis doesn't have the access to the repository
  855. and even fedmsg doesn't get any notifications.
  856. Defaults to: ``True``
  857. EXCLUDE_GROUP_INDEX
  858. ~~~~~~~~~~~~~~~~~~~
  859. This configuration key can be used to hide project an user has access to via
  860. one of the groups listed in this key.
  861. The use-case is the following: the Fedora project is deploying pagure has a
  862. front-end for the git repos of the packages in the distribution, that means
  863. about 17,000 git repositories in pagure. The project has a group of people
  864. that have access to all of these repositories, so when viewing the user's
  865. page of one member of that group, instead of seeing all the project that
  866. this user works on, you can see all the projects hosted in that pagure
  867. instance. Using this configuration key, pagure will hide all the projects
  868. that this user has access to via the specified groups and thus return only
  869. the groups of forks of that users.
  870. Defaults to: ``[]``
  871. TRIGGER_CI
  872. ~~~~~~~~~~
  873. A run of pagure-ci can be manually triggered if some key sentences are added
  874. as comment to a pull-request, either manually or via the "Rerun CI" dropdown.
  875. This allows one to re-run a test that failed due to some network outage or other
  876. unexpected issues unrelated to the test suite.
  877. This configuration key can be used to define all the sentences that can be used
  878. to trigger this pagure-ci run. The format is following: ``{"<sentence>":
  879. {"name": "<name of the CI>", "description": "<short description>"}}``
  880. Sentences which have ``None`` as value won't show up in the "Rerun CI"
  881. dropdown. Additionally, it's possible to add a ``requires_project_hook_attr``
  882. key to the dict with data about a sentence. For example, having
  883. ``"requires_project_hook_attr": ("ci_hook", "active_pr", True)`` would make
  884. the "Rerun CI" dropdown have a button for this specific CI only if the
  885. project has ``ci_hook`` activated and its ``active_pr`` value is ``True``.
  886. In versions before 5.2, this was a list containing just the sentences.
  887. Defaults to: ``{"pretty please pagure-ci rebuild": {"name": "Default CI",
  888. "description": "Rerun default CI"}}``
  889. .. note:: The sentences defined in this configuration key should be lower
  890. case only!
  891. FLAG_STATUSES_LABELS
  892. ~~~~~~~~~~~~~~~~~~~~
  893. By default, Pagure has ``success``, ``failure``, ``error``, ``pending`` and
  894. ``canceled`` statuses of PR and commit flags. This setting allows you to
  895. define a custom mapping of statuses to their respective Bootstrap labels.
  896. FLAG_SUCCESS
  897. ~~~~~~~~~~~~
  898. Holds name of PR/commit flag that is considered a success.
  899. Defaults to: ``success``
  900. FLAG_FAILURE
  901. ~~~~~~~~~~~~
  902. Holds name of PR/commit flag that is considered a failure.
  903. Defaults to: ``failure``
  904. FLAG_PENDING
  905. ~~~~~~~~~~~~
  906. Holds name of PR/commit flag that is considered a pending state.
  907. Defaults to: ``pending``
  908. EXTERNAL_COMMITTER
  909. ~~~~~~~~~~~~~~~~~~
  910. The external committer feature is a way to allow members of groups defined
  911. outside pagure (and provided to pagure upon login by the authentication
  912. system) to be consider committers on pagure.
  913. This feature can give access to all the projects on the instance, all but
  914. some or just some.
  915. Defaults to: ``{}``
  916. To give access to all the projects to a group named ``fedora-altarch`` use
  917. a such a structure::
  918. EXTERNAL_COMMITTER = {
  919. 'fedora-altarch': {}
  920. }
  921. To give access to all the projects but one (named ``rpms/test``) to a group
  922. named ``provenpackager`` use a such a structure::
  923. EXTERNAL_COMMITTER = {
  924. 'fedora-altarch': {},
  925. 'provenpackager': {
  926. 'exclude': ['rpms/test']
  927. }
  928. }
  929. To give access to just some projects (named ``rpms/test`` and
  930. ``modules/test``) to a group named ``testers`` use a such a structure::
  931. EXTERNAL_COMMITTER = {
  932. 'fedora-altarch': {},
  933. 'provenpackager': {
  934. 'exclude': ['rpms/test']
  935. },
  936. 'testers': {
  937. 'restrict': ['rpms/test', 'modules/test']
  938. }
  939. }
  940. REQUIRED_GROUPS
  941. ~~~~~~~~~~~~~~~
  942. The required groups allows one to specify in which group an user must be to be
  943. added to a project with commit or admin access.
  944. Defaults to: ``{}``
  945. Example configuration::
  946. REQUIRED_GROUPS = {
  947. 'rpms/kernel': ['packager', 'kernel-team'],
  948. 'modules/*': ['module-packager', 'packager'],
  949. 'rpms/*': ['packager'],
  950. '*': ['contributor'],
  951. }
  952. With this configuration (evaluated in the provided order):
  953. * only users that are in the groups ``packager`` and ``kernel-team`` will be
  954. allowed to be added the ``rpms/kernel`` project (where ``rpms`` is the
  955. namespace and ``kernel`` the project name).
  956. * only users that are in the groups ``module-packager`` and ``packager``
  957. will be allowed to be added to projects in the ``modules`` namespace.
  958. * only users that are in the group ``packager`` will be allowed to be added
  959. to projects in the ``rpms`` namespace.
  960. * only users in the ``contributor`` group will be allowed to be added to
  961. any project on this pagure instance.
  962. GITOLITE_PRE_CONFIG
  963. ~~~~~~~~~~~~~~~~~~~
  964. This configuration key allows you to include some content at the *top* of
  965. the gitolite configuration file (such as some specific group definition),
  966. thus allowing to customize the gitolite configuration file with elements
  967. and information that are outside of pagure's control.
  968. This can be used in combination with ``GITOLITE_POST_CONFIG`` to further
  969. customize gitolite's configuration file. It can also be used with
  970. ``EXTERNAL_COMMITTER`` to give commit access to git repos based on external
  971. information.
  972. Defaults to: ``None``
  973. GITOLITE_POST_CONFIG
  974. ~~~~~~~~~~~~~~~~~~~~
  975. This configuration key allows you to include some content at the *end* of
  976. the gitolite configuration file (such as some project definition or access),
  977. thus allowing to customize the gitolite configuration file with elements
  978. and information that are outside of pagure's control.
  979. This can be used in combination with ``GITOLITE_PRE_CONFIG`` to further
  980. customize gitolite's configuration file. It can also be used with
  981. ``EXTERNAL_COMMITTER`` to give commit access to git repos based on external
  982. information.
  983. Defaults to: ``None``
  984. GIT_GARBAGE_COLLECT
  985. ~~~~~~~~~~~~~~~~~~~
  986. This configuration key allows for explicit running of ``git gc --auto``
  987. after every operation that adds new objects to any git repository -
  988. that is after pushing and merging. The reason for having this functionality
  989. in Pagure is that gc is not guaranteed to be run by git after every
  990. object-adding operation.
  991. The garbage collection run by Pagure will respect git settings, so you
  992. can tweak ``gc.auto`` and ``gc.autoPackLimit`` to your liking
  993. and that will have immediate effect on the task that runs the garbage
  994. collection. These values can be configured system-wide in ``/etc/gitconfig``.
  995. See https://git-scm.com/docs/git-gc#git-gc---auto for more details.
  996. This is especially useful if repositories are stored on NFS (or similar
  997. network storage), where file metadata access is expensive - having unpacked
  998. objects in repositories requires *a lot* of metadata reads.
  999. Note that the garbage collection is only run on repos that are not on
  1000. repoSpanner.
  1001. Defaults to: ``False``
  1002. CELERY_CONFIG
  1003. ~~~~~~~~~~~~~
  1004. This configuration key allows you to tweak the configuration of celery for
  1005. your needs.
  1006. See the documentation about `celery configuration
  1007. <http://docs.celeryproject.org/en/latest/userguide/configuration.html>`_ for
  1008. more information.
  1009. Defaults to: ``{}``
  1010. CASE_SENSITIVE
  1011. ~~~~~~~~~~~~~~
  1012. This configuration key can be used to make this pagure instance case sensitive
  1013. instead of its default: case-insensitive.
  1014. Defaults to: ``False``
  1015. PROJECT_NAME_REGEX
  1016. ~~~~~~~~~~~~~~~~~~
  1017. This configuration key can be used to customize the regular expression used to
  1018. validate new project name.
  1019. Defaults to: ``^[a-zA-z0-9_][a-zA-Z0-9-_]*$``
  1020. APPLICATION_ROOT
  1021. ~~~~~~~~~~~~~~~~
  1022. This configuration key is used in the path of the cookie used by pagure.
  1023. Defaults to: ``'/'``
  1024. ALLOWED_PREFIX
  1025. ~~~~~~~~~~~~~~
  1026. This configuration key can be used to specify a list of allowed namespaces that
  1027. will not require creating a group for users to create projects in.
  1028. Defaults to: ``[]``
  1029. ADMIN_SESSION_LIFETIME
  1030. ~~~~~~~~~~~~~~~~~~~~~~
  1031. This configuration key allows specifying the lifetime of the session during
  1032. which the user won't have to re-login for admin actions.
  1033. In other words, the maximum time between which an user can access a project's
  1034. settings page without re-login.
  1035. Defaults to: ``timedelta(minutes=20)``
  1036. where timedelta comes from the python datetime module
  1037. BLACKLISTED_GROUPS
  1038. ~~~~~~~~~~~~~~~~~~
  1039. This configuration key can be used to blacklist some group names.
  1040. Defaults to: ``['forks', 'group']``
  1041. ENABLE_GROUP_MNGT
  1042. ~~~~~~~~~~~~~~~~~
  1043. This configuration key can be used to turn on or off managing (ie: creating a
  1044. group, adding or removing users in that group) groups in this pagure instance.
  1045. If turned off, groups and group members are to be managed outside of pagure
  1046. and synced upon login.
  1047. Defaults to: ``True``
  1048. ENABLE_USER_MNGT
  1049. ~~~~~~~~~~~~~~~~
  1050. This configuration key can be used to turn on or off managing users (adding or
  1051. removing them from a project) in this pagure instance.
  1052. If turned off, users are managed outside of pagure.
  1053. Defaults to: ``True``
  1054. SESSION_COOKIE_NAME
  1055. ~~~~~~~~~~~~~~~~~~~
  1056. This configuration key can be used to specify the name of the session cookie used
  1057. by pagure.
  1058. Defaults to: ``'pagure'``
  1059. SHOW_PROJECTS_INDEX
  1060. ~~~~~~~~~~~~~~~~~~~
  1061. This configuration key can be used to specify what is shown in the index page of
  1062. logged in users.
  1063. Defaults to: ``['repos', 'myrepos', 'myforks']``
  1064. EMAIL_ON_WATCHCOMMITS
  1065. ~~~~~~~~~~~~~~~~~~~~~
  1066. By default pagure sends an email to every one watch commits on a project when a
  1067. commit is made.
  1068. However some pagure instances may be using a different notification mechanism on
  1069. commits and thus may not want this feature to double the notifications received.
  1070. This configuration key can be used to turn on or off email being sent to people
  1071. watching commits on a project upon commits.
  1072. Defaults to: ``True``
  1073. ALLOW_HTTP_PULL_PUSH
  1074. ~~~~~~~~~~~~~~~~~~~~
  1075. This configuration key controls whether any HTTP access to repositories is provided
  1076. via the support for that that's embedded in Pagure.
  1077. This provides HTTP pull access via <pagureurl>/<reponame>.git if nothing else
  1078. serves this URL.
  1079. Defaults to: ``True``
  1080. ALLOW_HTTP_PUSH
  1081. ~~~~~~~~~~~~~~~
  1082. This configuration key controls whether pushing is possible via the HTTP interface.
  1083. This is disabled by default, as it requires setting up an authentication mechanism
  1084. on the webserver that sets REMOTE_USER.
  1085. Defaults to: ``False``
  1086. HTTP_REPO_ACCESS_GITOLITE
  1087. ~~~~~~~~~~~~~~~~~~~~~~~~~
  1088. This configuration key configures the path to the gitolite-shell binary.
  1089. If this is set to None, Git http-backend is used directly.
  1090. Only set this to ``None`` if you intend to provide HTTP push access via Pagure, and
  1091. are using a dynamic ACL backend.
  1092. Defaults to: ``/usr/share/gitolite3/gitolite-shell``
  1093. MIRROR_SSHKEYS_FOLDER
  1094. ~~~~~~~~~~~~~~~~~~~~~
  1095. This configuration key specificies where pagure should store the ssh keys
  1096. generated for the mirroring feature. This folder should be properly backed up
  1097. and kept secure.
  1098. Defaults to: ``/var/lib/pagure/sshkeys/``
  1099. LOG_ALL_COMMITS
  1100. ~~~~~~~~~~~~~~~
  1101. This configuration key will make pagure log all commits pushed to all
  1102. branches of all repositories instead of logging only the once that are
  1103. pushed to the default branch.
  1104. Defaults to: ``False``
  1105. DISABLE_MIRROR_IN
  1106. ~~~~~~~~~~~~~~~~~
  1107. This configuration key allows a pagure instance to not support mirroring in
  1108. projects (from third party git server).
  1109. Defaults to: ``False``
  1110. SYNTAX_ALIAS_OVERRIDES
  1111. ~~~~~~~~~~~~~~~~~~~~~~
  1112. This configuration key can be used to force highlight.js to use a certain logic
  1113. on certain files based on their extensions.
  1114. It should be a dictionary containing the file extensions as keys and
  1115. the highlighting language/category to use as values.
  1116. Defaults to: ``{".spec": "specfile", ".patch": "diff"}``
  1117. RepoSpanner Options
  1118. -------------------
  1119. Pagure can be integrated with `repoSpanner <https://repospanner.org>`_
  1120. allowing to deploy pagure in a load-balanced environment since the git
  1121. repositories are then synced across multiple servers simultaneously.
  1122. Support for this integration has been included in Pagure version 5.0 and higher.
  1123. Here below are the different options one can/should use to integrate pagure
  1124. with repoSpanner.
  1125. REPOBRIDGE_BINARY
  1126. ~~~~~~~~~~~~~~~~~
  1127. This should contain the path to the repoBridge binary, which is used for pushing
  1128. and pulling to/from repoSpanner.
  1129. Defaults to: ``/usr/libexec/repobridge``.
  1130. REPOSPANNER_NEW_REPO
  1131. ~~~~~~~~~~~~~~~~~~~~
  1132. This configuration key instructs pagure to create new git repositories on
  1133. repoSpanner or not.
  1134. Its value should be the region in which the new git repositories should be
  1135. created on.
  1136. Defaults to: ``None``.
  1137. REPOSPANNER_NEW_REPO_ADMIN_OVERRIDE
  1138. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  1139. This configuration key can be used to let pagure admin override the default
  1140. region used when creating new git repositories on repoSpanner.
  1141. Its value should be a boolean.
  1142. Defaults to: ``False``
  1143. REPOSPANNER_NEW_FORK
  1144. ~~~~~~~~~~~~~~~~~~~~
  1145. This configuration key instructs pagure on where/how to create new git
  1146. repositories for the forks with repoSpanner.
  1147. If ``None``, git repositories for forks are created outside of repoSpanner
  1148. entirely.
  1149. If ``True``, git repositories for forks are created in the same region as
  1150. the parent project.
  1151. Otherwise, a region can be directly specified where git repositories for
  1152. forks will be created.
  1153. Defaults to: ``True``
  1154. REPOSPANNER_ADMIN_MIGRATION
  1155. ~~~~~~~~~~~~~~~~~~~~~~~~~~~
  1156. This configuration key can be used to let admin manually migrate individual
  1157. project into repoSpanner once it is set up.
  1158. Defaults to: ``False``
  1159. REPOSPANNER_REGIONS
  1160. ~~~~~~~~~~~~~~~~~~~
  1161. This configuration key can be used to specify the different region where repoSpanner
  1162. is deployed and thus with which this pagure instance can be integrated.
  1163. An example entry could look like:
  1164. ::
  1165. REPOSPANNER_REGIONS = {
  1166. 'default': {'url': 'https://nodea.regiona.repospanner.local:8444',
  1167. 'repo_prefix': 'pagure/',
  1168. 'hook': None,
  1169. 'ca': '/etc/pki/repospanner/pki/ca.crt',
  1170. 'admin_cert': {'cert': '/etc/pki/repospanner/pki/admin.crt',
  1171. 'key': '/etc/pki/repospanner/pki/admin.key'},
  1172. 'push_cert': {'cert': '/etc/pki/repospanner/pki/pagure.crt',
  1173. 'key': '/etc/pki/repospanner/pki/pagure.key'}}
  1174. }
  1175. If this configuration key is not defined, pagure will consider that it is
  1176. not set to be integrated with repoSpanner.
  1177. Defaults to: ``{}``
  1178. SSH_KEYS_USERNAME_LOOKUP
  1179. ~~~~~~~~~~~~~~~~~~~~~~~~
  1180. This configuration key is used by the keyhelper script to indicate that the
  1181. git username should be used and looked up. Use this if the username that is sent
  1182. to ssh is specific for a unique Pagure user (i.e. not using a single "git@" user
  1183. for all git operations).
  1184. SSH_KEYS_USERNAME_FORBIDDEN
  1185. ~~~~~~~~~~~~~~~~~~~~~~~~~~~
  1186. A list of usernames that are exempted from being verified via the keyhelper.
  1187. SSH_KEYS_USERNAME_EXPECT
  1188. ~~~~~~~~~~~~~~~~~~~~~~~~
  1189. This configuration key should contain the username that is used for git if a single
  1190. SSH user is used for all git ssh traffic (i.e. "git").
  1191. SSH_KEYS_OPTIONS
  1192. ~~~~~~~~~~~~~~~~
  1193. This configuration key provides the options added to keys as they are returned
  1194. to sshd, in the same format as AuthorizedKeysFile
  1195. (see "AUTHORIZED_KEYS FILE FORMAT" in sshd(8)).
  1196. SSH_ADMIN_TOKEN
  1197. ~~~~~~~~~~~~~~~
  1198. If not set to ``None``, ``aclchecker`` and ``keyhelper`` will use this api
  1199. admin token to get authorized to internal endpoints that they use. The token
  1200. must have the ``internal_access`` ACL.
  1201. This is useful when the IP address of sshd service is not predictable
  1202. (e.g. because of running in a distributed cloud environment) and so
  1203. it's not possible to use the ``IP_ALLOWED_INTERNAL`` address list.
  1204. Defaults to: ``None``
  1205. SSH_COMMAND_REPOSPANNER
  1206. ~~~~~~~~~~~~~~~~~~~~~~~
  1207. The command to run if a repository is on repospanner when aclchecker is in use.
  1208. SSH_COMMAND_NON_REPOSPANNER
  1209. ~~~~~~~~~~~~~~~~~~~~~~~~~~~
  1210. The command to run if a repository is not on repospanner when aclchecker is in use.
  1211. MQTT Options
  1212. ------------
  1213. If approprietly configured pagure supports sending messages to an MQTT
  1214. message queue.
  1215. Here below are the different configuration options to make it so.
  1216. MQTT_NOTIFICATIONS
  1217. ~~~~~~~~~~~~~~~~~~
  1218. Global configuration key to turn on or off the code to send notifications
  1219. to an MQTT message queue.
  1220. Defaults to: ``False``
  1221. MQTT_HOST
  1222. ~~~~~~~~~
  1223. Host name of the MQTT server to send the MQTT notifications to.
  1224. Defaults to: ``None``
  1225. MQTT_PORT
  1226. ~~~~~~~~~
  1227. Port of the MQTT server to use to send the MQTT notifications to.
  1228. Defaults to: ``None``
  1229. MQTT_USERNAME
  1230. ~~~~~~~~~~~~~
  1231. Username to authenticate to the MQTT server as.
  1232. Defaults to: ``None``
  1233. MQTT_PASSWORD
  1234. ~~~~~~~~~~~~~
  1235. Password to authenticate to the MQTT server with.
  1236. Defaults to: ``None``
  1237. MQTT_CA_CERTS
  1238. ~~~~~~~~~~~~~
  1239. When using SSL-based authentication to the MQTT server, use this
  1240. configuration key to point to the CA cert to use.
  1241. Defaults to: ``None``
  1242. MQTT_CERTFILE
  1243. ~~~~~~~~~~~~~
  1244. When using SSL-based authentication to the MQTT server, use this
  1245. configuration key to point to the cert file to use.
  1246. Defaults to: ``None``
  1247. MQTT_KEYFILE
  1248. ~~~~~~~~~~~~~
  1249. When using SSL-based authentication to the MQTT server, use this
  1250. configuration key to point to the key file to use.
  1251. Defaults to: ``None``
  1252. MQTT_CERT_REQS
  1253. ~~~~~~~~~~~~~~
  1254. When using SSL-based authentication to the MQTT server, use this
  1255. configuration key to specify if the CERT is required.
  1256. Defaults to: ``ssl.CERT_REQUIRED`` (from python's ssl library)
  1257. MQTT_TLS_VERSION
  1258. ~~~~~~~~~~~~~~~~
  1259. When using SSL-based authentication to the MQTT server, use this
  1260. configuration key to specify the TLS protocols to support/use.
  1261. Defaults to: ``ssl.PROTOCOL_TLSv1_2`` (from python's ssl library)
  1262. MQTT_CIPHERS
  1263. ~~~~~~~~~~~~
  1264. When using SSL-based authentication to the MQTT server, use this
  1265. configuration key to specify the ciphers.
  1266. Defaults to: ``None``
  1267. MQTT_TOPIC_PREFIX
  1268. ~~~~~~~~~~~~~~~~~
  1269. This configuration key can be used to specify a prefix to the mqtt messages sent.
  1270. This prefix will be added to the topic used by pagure thus allowing the mqtt
  1271. admins to specify a parent topic for all pagure-related messages.
  1272. Defaults to: ``None``
  1273. ALWAYS_MQTT_ON_COMMITS
  1274. ~~~~~~~~~~~~~~~~~~~~~~
  1275. This configuration key can be used to enforce `mqtt <https://mqtt.org/>`_
  1276. notifications on commits made on all projects in a pagure instance.
  1277. Defaults to: ``False``.
  1278. Deprecated configuration keys
  1279. -----------------------------
  1280. FORK_FOLDER
  1281. ~~~~~~~~~~~
  1282. This configuration key used to be use to specify the folder where the forks
  1283. are placed. Since the release 2.0 of pagure, it has been deprecated, forks
  1284. are now automatically placed in a sub-folder of the folder containing the
  1285. mains git repositories (ie ``GIT_FOLDER``).
  1286. See the ``UPGRADING.rst`` file for more information about this change and
  1287. how to handle it.
  1288. UPLOAD_FOLDER
  1289. ~~~~~~~~~~~~~
  1290. This configuration key used to be use to specify where the uploaded releases
  1291. are available. It has been replaced by `UPLOAD_FOLDER_PATH` in the release
  1292. 2.10 of pagure.
  1293. GITOLITE_VERSION
  1294. ~~~~~~~~~~~~~~~~
  1295. This configuration key specifies which version of gitolite you are
  1296. using, it can be either ``2`` or ``3``.
  1297. Defaults to: ``3``.
  1298. This has been replaced by `GITOLITE_BACKEND` in the release 3.0 of pagure.
  1299. DOCS_FOLDER, REQUESTS_FOLDER, TICKETS_FOLDER
  1300. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  1301. These configuration values were removed. It has been found out that
  1302. due to how Pagure writes repo names in the gitolite configuration file,
  1303. these must have fixed paths relative to `GIT_FOLDER`. Specifically, they
  1304. must occupy subdirectories `docs`, `requests` and `tickets` under `GIT_FOLDER`.
  1305. They are now computed automatically based on value of `GIT_FOLDER`.
  1306. Usage of docs and tickets can be triggered by setting `ENABLE_DOCS` and
  1307. `ENABLE_TICKETS` to `True` (this is the default).
  1308. FILE_SIZE_HIGHLIGHT
  1309. ~~~~~~~~~~~~~~~~~~~
  1310. This configuration key can be used to specify the maximum number of characters a file
  1311. or diff should have to have syntax highlighting. Everything above this limit
  1312. will not have syntax highlighting as this is a memory intensive procedure that
  1313. easily leads to out of memory error on large files or diff.
  1314. Defaults to: ``5000``
  1315. BOOTSTRAP_URLS_CSS
  1316. ~~~~~~~~~~~~~~~~~~
  1317. This configuration key can be used to specify the URL where are hosted the bootstrap
  1318. CSS file since the files hosted on apps.fedoraproject.org used in pagure.io
  1319. are not restricted in browser access.
  1320. Defaults to: ``'https://apps.fedoraproject.org/global/fedora-bootstrap-1.1.1/fedora-bootstrap.css'``
  1321. This has been deprecated by the new way of theming pagure, see the `theming
  1322. documentation <https://docs.pagure.org/pagure/usage/theming.html>`_
  1323. BOOTSTRAP_URLS_JS
  1324. ~~~~~~~~~~~~~~~~~
  1325. This configuration key can be used to specify the URL where are hosted the bootstrap
  1326. JS file since the files hosted on apps.fedoraproject.org used in pagure.io
  1327. are not restricted in browser access.
  1328. Defaults to: ``'https://apps.fedoraproject.org/global/fedora-bootstrap-1.1.1/fedora-bootstrap.js'``
  1329. This has been deprecated by the new way of theming pagure, see the `theming
  1330. documentation <https://docs.pagure.org/pagure/usage/theming.html>`_
  1331. HTML_TITLE
  1332. ~~~~~~~~~~
  1333. This configuration key allows you to customize the HTML title of all the
  1334. pages, from ``... - pagure`` (default) to ``... - <your value>``.
  1335. Defaults to: ``Pagure``
  1336. This has been deprecated by the new way of theming pagure, see the `theming
  1337. documentation <https://docs.pagure.org/pagure/usage/theming.html>`_
  1338. GITOLITE_BACKEND
  1339. ~~~~~~~~~~~~~~~~
  1340. This configuration key allowed specifying the gitolite backend.
  1341. This has now been replaced by GIT_AUTH_BACKEND, please see that option
  1342. for information on valid values.