stable

Clone or download

Read-only

Restrict to project the access to a mirror

This commits is a first step in order to allow/forbid a project to access to a git mirror. Functionaly speaking, this is the equivalent of project/plugin restriction. In order to test this commit, you must manually edit the database to insert your data (do not forget forgeupgrade): 1. If you do nothing, then all is working as before:Β every mirrors are available for every projects 2. If you insert the id of a mirror in the table plugin_git_restricted_mirrors, then this mirror will be restricted. Nobody can use it (no git clone, no repo settings, no mass change, and it generates a nearly empty manifest file). 3. If you insert the id of a mirror in the table plugin_git_restricted_mirrors + you insert the id of the mirror and a project id in the table plugin_git_restricted_mirrors_allowed_projects, then only this project will be able to use the mirror (git clone, repo settings, mass change, and it appears in the manifest file). Implements: story #7709 - activate mirroring per project Change-Id: Ib30d3f4727d48e34ee06f9b9f895eaefcbd14b2a

Modified Files

Name
M plugins/git/db/install.sql +10 βˆ’0 Go to diff View file
A plugins/git/db/mysql/updates/2015/201503051029_add_restricted_mirrors.php +58 βˆ’0 Go to diff View file
M plugins/git/db/uninstall.sql +2 βˆ’0 Go to diff View file
M plugins/git/include/Git/Mirror/MirrorDao.class.php +37 βˆ’5 Go to diff View file
M plugins/git/include/Git/Mirror/MirrorDataMapper.class.php +17 βˆ’7 Go to diff View file
M plugins/git/include/GitViews.class.php +2 βˆ’2 Go to diff View file
M plugins/git/include/GitViews/RepoManagement/RepoManagement.class.php +2 βˆ’2 Go to diff View file