summaryrefslogtreecommitdiffstats
path: root/git-interface/git-serve.py
AgeCommit message (Collapse)AuthorFilesLines
2015-06-27git-serve: Drop direct AccountType checking, use AUR_PRIVILEGEDJohannes Löthberg1-2/+1
Signed-off-by: Johannes Löthberg <johannes@kyriasis.com> Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
2015-06-27git: Use AUR_USER env var instead of ForceCommand argumentJohannes Löthberg1-1/+1
Also add an utility function for formatting the ForceCommand, using shlex.quote to quote the value. Signed-off-by: Johannes Löthberg <johannes@kyriasis.com> Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
2015-06-27git: Use .format everywhere instead of %Johannes Löthberg1-13/+13
% formatting is deprecated, and .format should be used instead. Signed-off-by: Johannes Löthberg <johannes@kyriasis.com> Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
2015-06-12git-serve: Support cloning with simplified pathsJohannes Löthberg1-2/+4
This commit adds support for cloning repositories over SSH without a leading slash or with a trailing .git Fixes FS#45260 Signed-off-by: Johannes Löthberg <johannes@kyriasis.com> Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
2015-06-11Support exceptions in the maintenance modeLukas Fleischer1-1/+4
Allow for excluding certain IP addresses from the maintenance mode. This allows administrators to view the web page while the site is still under maintenance for the rest of the world. Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
2015-06-11Implement a maintenance modeLukas Fleischer1-0/+5
Add support for a maintenance mode that disables both the website and the SSH interface and can be enabled easily using a configuration option. Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
2015-06-11Do not use symrefs for manually created Git refsLukas Fleischer1-17/+0
When creating the refs for the package base branch and the HEAD ref workaround, directly use commit IDs instead of symrefs. It looks like Git cannot pack symrefs, so this is expected to improve space efficiency. Also, since the refs are now only created (or updated) when new objects are actually received, this fixes a problem with dangling refs that were created when a user initialized a repository but did not push anything. Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
2015-06-08git-serve: Use `pkgbase` for errors about invalid namesWieland Hoffmann1-1/+1
`repo` is not defined at the point it's used, so you would get errors like > Traceback (most recent call last): > File "/srv/http/vhosts/aur-dev.archlinux.org/public/git-interface/git-serve.py", line 138, in <module> > die('%s: invalid repository name: %s' % (action, repo)) > NameError: name 'repo' is not defined Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
2015-06-02config.proto: CleanupLukas Fleischer1-1/+0
Remove the template-path and git-update-hook options which are no longer used. Update the git_clone_uri_anon default value. Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
2015-06-02Setup Git repositories even if package base existsLukas Fleischer1-7/+17
Sometimes, we need to initialize the Git repository even if the package base already exists (e.g. when using a non-empty package database with empty repositories during the AUR 4.0.0 migration period). Make sure that the package branch and the namespaced HEAD ref is always created. Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
2015-06-02Restructure scriptsLukas Fleischer1-0/+162
* Move scripts/git-integration/ to git-interface/. * Move scripts/aurblup/aurblup.py to scripts/aurblup.py. Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>