summaryrefslogtreecommitdiff
path: root/mirrors
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2013-11-25 21:10:25 -0600
committerDan McGee <dan@archlinux.org>2013-11-25 21:10:25 -0600
commit108cfaa8df3b94031a3436fbb71c76fdc0650ba1 (patch)
tree61c30085b49e63c6605dfebac3bef5e123cbaa70 /mirrors
parent06317908f73420224fce0c400048c3b7dcfc8abb (diff)
parent071bd6bd71f681c45048fc0a0961e58d43d44d48 (diff)
Merge branch 'django-1.6'
Diffstat (limited to 'mirrors')
-rw-r--r--mirrors/admin.py6
-rw-r--r--mirrors/management/commands/mirrorcheck.py2
2 files changed, 7 insertions, 1 deletions
diff --git a/mirrors/admin.py b/mirrors/admin.py
index d0f2f475..e35d9ce7 100644
--- a/mirrors/admin.py
+++ b/mirrors/admin.py
@@ -10,6 +10,7 @@ from .models import (Mirror, MirrorProtocol, MirrorUrl, MirrorRsync,
class MirrorUrlForm(forms.ModelForm):
class Meta:
model = MirrorUrl
+ fields = ('url', 'country', 'active')
def clean_url(self):
# is this a valid-looking URL?
@@ -39,6 +40,7 @@ class MirrorUrlInlineAdmin(admin.TabularInline):
class MirrorRsyncForm(forms.ModelForm):
class Meta:
model = MirrorRsync
+ fields = ('ip',)
class MirrorRsyncInlineAdmin(admin.TabularInline):
@@ -50,6 +52,10 @@ class MirrorRsyncInlineAdmin(admin.TabularInline):
class MirrorAdminForm(forms.ModelForm):
class Meta:
model = Mirror
+ fields = ('name', 'tier', 'upstream', 'admin_email', 'alternate_email',
+ 'public', 'active', 'isos', 'rsync_user', 'rsync_password',
+ 'notes')
+
upstream = forms.ModelChoiceField(
queryset=Mirror.objects.filter(tier__gte=0, tier__lte=1),
required=False)
diff --git a/mirrors/management/commands/mirrorcheck.py b/mirrors/management/commands/mirrorcheck.py
index 3f026c36..e48aa42e 100644
--- a/mirrors/management/commands/mirrorcheck.py
+++ b/mirrors/management/commands/mirrorcheck.py
@@ -241,7 +241,7 @@ class MirrorCheckPool(object):
thread.daemon = True
self.threads.append(thread)
- @transaction.commit_on_success
+ @transaction.atomic
def run(self):
logger.debug("starting threads")
for thread in self.threads: