summaryrefslogtreecommitdiff
path: root/public
diff options
context:
space:
mode:
Diffstat (limited to 'public')
-rw-r--r--public/views.py12
1 files changed, 11 insertions, 1 deletions
diff --git a/public/views.py b/public/views.py
index e031201e..29fec470 100644
--- a/public/views.py
+++ b/public/views.py
@@ -1,4 +1,5 @@
from datetime import datetime
+from operator import attrgetter
from django.conf import settings
from django.contrib.auth.models import User
@@ -6,7 +7,6 @@ from django.db.models import Count, Q
from django.http import Http404
from django.shortcuts import redirect
from django.views.decorators.cache import cache_control
-from django.views.generic import list_detail
from django.views.generic.simple import direct_to_template
from devel.models import MasterKey, PGPSignature
@@ -61,6 +61,16 @@ def donate(request):
@cache_control(max_age=300)
def download(request):
+ mirror_urls = MirrorUrl.objects.select_related('mirror').filter(
+ protocol__default=True,
+ mirror__public=True, mirror__active=True, mirror__isos=True)
+ sort_by = attrgetter('real_country.name', 'mirror.name')
+ mirror_urls = sorted(mirror_urls, key=sort_by)
+ context = {
+ 'releng_iso_url': settings.ISO_LIST_URL,
+ 'releng_pxeboot_url': settings.PXEBOOT_URL,
+ 'mirror_urls': mirror_urls,
+ }
return redirect('//wiki.parabolagnulinux.org/get', permanent=True)
@cache_control(max_age=300)