•  
     
    story #8021 limit repository created on mirrors
Summary
site admin
limit repository created on mirrors
Empty
  • Use gitolite HOSTNAME mechanism
  • Add "hostname" info as mirror parameter
  • Once hostname is defined
    • Master hostname is assumed to be "master" (lowercase)
    • tuleap generates:
      • a gitolite.conf with [1] as content
      • a master.conf with all gitolite repo (actually it's the previous "gitolite.conf", see [2])
      • a file per mirror with mirror's hostname name (sfo in [3] exemple)
      • a directory per project/mirror with the conf file for the project with the repo that must be mirrored on the project (and only those files)
  • Plus other fixes to include:
    • gitolite-admin should be updated when the permissions changes (same as request #8001)

[1] gitolite.conf content

include "%HOSTNAME.conf"

[2] example of master.conf

include "projects/mozilla.conf"
include "projects/eclipse.conf"
include "projects/apache.conf"

[3] example of sfo.conf

include "sfo/mozilla.conf"
include "sfo/apache.conf"
Empty
loic.lefort@st.com, Nouha Terzi (terzino)
Status
Empty
Done
Development
  • [ ] Does it involves User Interface? 
  • [ ] Are there any mockups?
  • [ ] Are permissions checked?
  • [ ] Does it need Javascript development?
  • [ ] Does it need a forge upgrade bucket?
  • [ ] Does it need to execute things in system events?
  • [ ] Does it impact project creation (templates)?
  • [ ] Is it exploratory?
Empty
Details
#8021
Manuel Vacelet (vaceletm)
2015-05-28 09:52
2015-04-20 18:03
7818

References
Referencing story #8021

Git commit

tuleap/tuleap/stable

Merge commit 'refs/changes/87/3887/2' of ssh://gerrit.tuleap.net:29418/tuleap into HEAD 1bc1932250
story #8021: Add "hostname" info as mirror parameter 16f536f552
Merge commit 'refs/changes/02/3902/5' of ssh://gerrit.tuleap.net:29418/tuleap into tuleap-stable-master 25e70b754e
story #8021 - Write gitolite.conf in %HOSTNAME.conf if variable set in .gitolite.rc 65494855ce
Merge commit 'refs/changes/26/3926/3' of ssh://gerrit.tuleap.net:29418/tuleap into tuleap-stable-master 3a795a4ef5
story #8021 - Add a button to dump conf while taking hostname into account b98a9c4f60
Merge commit 'refs/changes/33/3933/1' of ssh://gerrit.tuleap.net:29418/tuleap into tuleap-stable-master 39e3878c32
story #8021 - Fix error 'variable not found' on mirror adding 7b8ed9934d
Merge commit 'refs/changes/32/3932/6' of ssh://gerrit.tuleap.net:29418/tuleap into HEAD 556655fc01
story #8021 - write conf on a per mirror basis if %HOSTNAME is set in .gitolite.rc file e97fe0a23d
Merge commit 'refs/changes/52/3952/1' of ssh://gerrit.tuleap.net:29418/tuleap into HEAD 89415ab292
story #8021 - delete mirror configuration on mirror delete 49a97305c0
Merge commit 'refs/changes/55/3955/1' of ssh://gerrit.tuleap.net:29418/tuleap into HEAD fe35539086
story #8021 - fix warning in gitolite syslog 2aaf950b54
Merge commit 'refs/changes/56/3956/4' of ssh://gerrit.tuleap.net:29418/tuleap into HEAD d6c05931c2
story #8021 - add a message to prevent hostname duplicates f66567f537
Merge commit 'refs/changes/71/3971/3' of ssh://gerrit.tuleap.net:29418/tuleap into stable 4efff68af4
story #8021 - Fix error when config of a mirror has never been dump 08887aed45
Merge commit 'refs/changes/78/3978/1' of ssh://gerrit.tuleap.net:29418/tuleap into stable 385c52bdc7
story #8021: Fix error when deleted mirror as no data a0b4980936
Merge commit 'refs/changes/79/3979/6' of ssh://gerrit.tuleap.net:29418/tuleap into stable d645a07d48
story #8021: Cannot use master %HOSTNAME and 'projects' hostname 5ccf806d80

Follow-ups

User avatar
Loïc Lefort (lefort)2015-05-28 09:52
I have updated permissions on a mirrored git. System event is completed.
I see files in gitolite config were updated (recent write time), but still Le_Mans.conf file is empty.

  • Category set to
User avatar
Martin GOYOT (goyotm)2015-05-28 09:43
I see. Could you try to update permissions on one of these repository and let the corresponding system event pass and then check again the content of the file?

Regards,
-- Martin
User avatar
Loïc Lefort (lefort)2015-05-28 09:30
In my case, I have created a Le_Mans mirror.
When as admin, I use Admin/"Git Plugin"/"Repositories on this mirror" for my mirror, I have correct list (2 git mirrored, from 2 different projects).

When I have a look at config for gitolite, I see Le_Mans directory containing one file per project and files content seems correct. I see also a file Le_Mans.conf but it is empty while it should have some "include Le_Mans/xxx.conf" lines.
We have this problem for all mirrors.
User avatar
Martin GOYOT (goyotm)2015-05-27 18:27
No, it should be good. Have you pressed the dump mirrored repositories button?

If yes, does your mirrors are concerned by a repository? I mean:

repo1 in project1 is mirrored on mirror1 => mirror1.conf includes mirror1/project1.conf which contains repo1 configuration

Regards,
-- Martin
User avatar
Loïc Lefort (lefort)2015-05-27 18:06
I see new .conf files for each mirrors, but they all are empty.
New directories per mirror seems to have a correct content.

I have installed tuleap 8.1.99.67.
Was there some specific steps for upgrade I could have missed ?
User avatar
Loïc Lefort (lefort)2015-04-21 16:53
Do not forget lines :
@mirrors = …
repo gitolite-admin
R = @mirrors
RW+ = id_rsa_gl-adm
I suppose they are useless on a mirror, so they could be moved to file master.conf

Add an error message if user tries to create a mirror named "projects", to avoid conflict with directory "projects" used by master ?
User avatar
  • Acceptance criteria
    Something went wrong, the follow up content couldn't be loaded
    Only formatting have been changed, you should switch to markup to see the changes