summaryrefslogtreecommitdiff
path: root/mirrors
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@sbcglobal.net>2014-10-02 20:40:34 -0400
committerLuke Shumaker <lukeshu@sbcglobal.net>2014-10-02 20:40:34 -0400
commitea00a099dffd7157c93af54b5817734348d2bbc6 (patch)
tree89fa4ba0c0ac19a4286ba4c4cb64f77536b1a098 /mirrors
parent1a1fd4a3d6aa7f6b2338f7751f5f97a30a059a04 (diff)
parent0f0ce18109f8104d7b2abe9024ef26fa07ff0292 (diff)
Merge branch 'archweb' into archweb-generic
Conflicts: templates/public/download.html templates/public/index.html
Diffstat (limited to 'mirrors')
-rw-r--r--mirrors/admin.py10
-rw-r--r--mirrors/fields.py4
-rw-r--r--mirrors/management/commands/mirrorcheck.py2
-rw-r--r--mirrors/migrations/0001_initial.py130
-rw-r--r--mirrors/migrations/0002_rename_model_tables.py80
-rw-r--r--mirrors/migrations/0003_auto__add_mirrorlog.py72
-rw-r--r--mirrors/migrations/0004_auto__add_field_mirrorprotocol_is_download.py62
-rw-r--r--mirrors/migrations/0005_populate_protocol_is_download.py64
-rw-r--r--mirrors/migrations/0006_auto__add_field_mirrorurl_has_ipv4__add_field_mirrorurl_has_ipv6.py66
-rw-r--r--mirrors/migrations/0007_unique_names_urls.py66
-rw-r--r--mirrors/migrations/0008_auto__add_field_mirrorurl_country.py67
-rw-r--r--mirrors/migrations/0009_auto__chg_field_mirrorurl_country.py66
-rw-r--r--mirrors/migrations/0010_auto__add_field_mirrorprotocol_default.py66
-rw-r--r--mirrors/migrations/0011_adjust_protocol_defaults.py67
-rw-r--r--mirrors/migrations/0012_auto__add_on_delete_attribute.py68
-rw-r--r--mirrors/migrations/0013_rename_country_fields.py68
-rw-r--r--mirrors/migrations/0014_add_country_code_fields.py74
-rw-r--r--mirrors/migrations/0015_assign_country_codes.py93
-rw-r--r--mirrors/migrations/0016_auto__del_field_mirror_country_old__del_field_mirrorurl_country_old.py76
-rw-r--r--mirrors/migrations/0017_auto__chg_field_mirrorlog_error.py66
-rw-r--r--mirrors/migrations/0018_auto__add_field_mirror_alternate_email.py68
-rw-r--r--mirrors/migrations/0019_move_country_data_to_url.py74
-rw-r--r--mirrors/migrations/0020_auto__del_field_mirror_country.py70
-rw-r--r--mirrors/migrations/0021_auto__chg_field_mirrorrsync_ip.py66
-rw-r--r--mirrors/migrations/0022_auto__add_checklocation.py83
-rw-r--r--mirrors/migrations/0023_auto__add_field_mirrorurl_created__add_field_mirrorrsync_created__add_.py97
-rw-r--r--mirrors/migrations/0024_auto__add_field_mirrorlog_location.py83
-rw-r--r--mirrors/migrations/0025_auto__chg_field_mirrorrsync_ip.py85
-rw-r--r--mirrors/migrations/0026_auto__add_field_mirrorurl_active.py83
-rw-r--r--mirrors/migrations/0027_auto__add_field_mirror_bug.py91
-rw-r--r--mirrors/models.py18
31 files changed, 139 insertions, 1946 deletions
diff --git a/mirrors/admin.py b/mirrors/admin.py
index 17365486..d5c89c2a 100644
--- a/mirrors/admin.py
+++ b/mirrors/admin.py
@@ -1,3 +1,4 @@
+from datetime import datetime
from urlparse import urlparse, urlunsplit
from django import forms
@@ -67,12 +68,19 @@ class MirrorAdmin(admin.ModelAdmin):
'isos', 'admin_email', 'alternate_email')
list_filter = ('tier', 'active', 'public')
search_fields = ('name', 'admin_email', 'alternate_email')
- readonly_fields = ('created',)
+ readonly_fields = ('created', 'last_modified')
inlines = [
MirrorUrlInlineAdmin,
MirrorRsyncInlineAdmin,
]
+ def save_model(self, request, obj, form, change):
+ if '~~~' in obj.notes:
+ date = datetime.utcnow().strftime('%Y-%m-%d')
+ usertext = request.user.get_full_name()
+ obj.notes = obj.notes.replace('~~~', '%s (%s)' % (date, usertext))
+ obj.save()
+
class MirrorProtocolAdmin(admin.ModelAdmin):
list_display = ('protocol', 'is_download', 'default')
diff --git a/mirrors/fields.py b/mirrors/fields.py
index 206c9d7d..e8963edf 100644
--- a/mirrors/fields.py
+++ b/mirrors/fields.py
@@ -4,7 +4,6 @@ from django import forms
from django.core import validators
from django.core.exceptions import ValidationError
from django.db import models
-from south.modelsinspector import add_introspection_rules
class IPNetworkFormField(forms.Field):
@@ -44,6 +43,3 @@ class IPNetworkField(models.Field):
defaults = {'form_class': IPNetworkFormField}
defaults.update(kwargs)
return super(IPNetworkField, self).formfield(**defaults)
-
-
-add_introspection_rules([], ["^mirrors\.fields\.IPNetworkField"])
diff --git a/mirrors/management/commands/mirrorcheck.py b/mirrors/management/commands/mirrorcheck.py
index e48aa42e..d2a27bee 100644
--- a/mirrors/management/commands/mirrorcheck.py
+++ b/mirrors/management/commands/mirrorcheck.py
@@ -139,7 +139,7 @@ def check_mirror_url(mirror_url, location, timeout):
if isinstance(e.reason, socket.timeout):
log.error = "Connection timed out."
elif isinstance(e.reason, socket.error):
- log.error = e.reason.args[1]
+ log.error = e.reason.args[-1]
logger.debug("failed: %s, %s", url, log.error)
except HTTPException:
# e.g., BadStatusLine
diff --git a/mirrors/migrations/0001_initial.py b/mirrors/migrations/0001_initial.py
index 4a3173c5..6f36c9eb 100644
--- a/mirrors/migrations/0001_initial.py
+++ b/mirrors/migrations/0001_initial.py
@@ -1,17 +1,123 @@
-# encoding: utf-8
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
+# -*- coding: utf-8 -*-
+from __future__ import unicode_literals
-class Migration(SchemaMigration):
+from django.db import models, migrations
+import django_countries.fields
+import django.db.models.deletion
+import mirrors.fields
- def forwards(self, orm):
- pass
- def backwards(self, orm):
- pass
+class Migration(migrations.Migration):
- models = {}
+ dependencies = [
+ ]
- complete_apps = ['mirrors']
+ operations = [
+ migrations.CreateModel(
+ name='CheckLocation',
+ fields=[
+ ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+ ('hostname', models.CharField(max_length=255)),
+ ('source_ip', models.GenericIPAddressField(unique=True, verbose_name=b'source IP', unpack_ipv4=True)),
+ ('country', django_countries.fields.CountryField(max_length=2)),
+ ('created', models.DateTimeField(editable=False)),
+ ],
+ options={
+ 'ordering': ('hostname', 'source_ip'),
+ },
+ bases=(models.Model,),
+ ),
+ migrations.CreateModel(
+ name='Mirror',
+ fields=[
+ ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+ ('name', models.CharField(unique=True, max_length=255)),
+ ('tier', models.SmallIntegerField(default=2, choices=[(0, b'Tier 0'), (1, b'Tier 1'), (2, b'Tier 2'), (-1, b'Untiered')])),
+ ('admin_email', models.EmailField(max_length=255, blank=True)),
+ ('alternate_email', models.EmailField(max_length=255, blank=True)),
+ ('public', models.BooleanField(default=True)),
+ ('active', models.BooleanField(default=True)),
+ ('isos', models.BooleanField(default=True, verbose_name=b'ISOs')),
+ ('rsync_user', models.CharField(default=b'', max_length=50, blank=True)),
+ ('rsync_password', models.CharField(default=b'', max_length=50, blank=True)),
+ ('bug', models.PositiveIntegerField(null=True, verbose_name=b'Flyspray bug', blank=True)),
+ ('notes', models.TextField(blank=True)),
+ ('created', models.DateTimeField(editable=False)),
+ ('last_modified', models.DateTimeField(editable=False)),
+ ('upstream', models.ForeignKey(on_delete=django.db.models.deletion.SET_NULL, to='mirrors.Mirror', null=True)),
+ ],
+ options={
+ 'ordering': ('name',),
+ },
+ bases=(models.Model,),
+ ),
+ migrations.CreateModel(
+ name='MirrorLog',
+ fields=[
+ ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+ ('check_time', models.DateTimeField(db_index=True)),
+ ('last_sync', models.DateTimeField(null=True)),
+ ('duration', models.FloatField(null=True)),
+ ('is_success', models.BooleanField(default=True)),
+ ('error', models.TextField(default=b'', blank=True)),
+ ('location', models.ForeignKey(related_name=b'logs', to='mirrors.CheckLocation', null=True)),
+ ],
+ options={
+ 'get_latest_by': 'check_time',
+ 'verbose_name': 'mirror check log',
+ },
+ bases=(models.Model,),
+ ),
+ migrations.CreateModel(
+ name='MirrorProtocol',
+ fields=[
+ ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+ ('protocol', models.CharField(unique=True, max_length=10)),
+ ('is_download', models.BooleanField(default=True, help_text=b'Is protocol useful for end-users, e.g. HTTP')),
+ ('default', models.BooleanField(default=True, help_text=b'Included by default when building mirror list?')),
+ ('created', models.DateTimeField(editable=False)),
+ ],
+ options={
+ 'ordering': ('protocol',),
+ },
+ bases=(models.Model,),
+ ),
+ migrations.CreateModel(
+ name='MirrorRsync',
+ fields=[
+ ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+ ('ip', mirrors.fields.IPNetworkField(max_length=44, verbose_name=b'IP')),
+ ('created', models.DateTimeField(editable=False)),
+ ('mirror', models.ForeignKey(related_name=b'rsync_ips', to='mirrors.Mirror')),
+ ],
+ options={
+ 'ordering': ('ip',),
+ 'verbose_name': 'mirror rsync IP',
+ },
+ bases=(models.Model,),
+ ),
+ migrations.CreateModel(
+ name='MirrorUrl',
+ fields=[
+ ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+ ('url', models.CharField(unique=True, max_length=255, verbose_name=b'URL')),
+ ('country', django_countries.fields.CountryField(blank=True, max_length=2, db_index=True)),
+ ('has_ipv4', models.BooleanField(default=True, verbose_name=b'IPv4 capable', editable=False)),
+ ('has_ipv6', models.BooleanField(default=False, verbose_name=b'IPv6 capable', editable=False)),
+ ('created', models.DateTimeField(editable=False)),
+ ('active', models.BooleanField(default=True)),
+ ('mirror', models.ForeignKey(related_name=b'urls', to='mirrors.Mirror')),
+ ('protocol', models.ForeignKey(related_name=b'urls', on_delete=django.db.models.deletion.PROTECT, editable=False, to='mirrors.MirrorProtocol')),
+ ],
+ options={
+ 'verbose_name': 'mirror URL',
+ },
+ bases=(models.Model,),
+ ),
+ migrations.AddField(
+ model_name='mirrorlog',
+ name='url',
+ field=models.ForeignKey(related_name=b'logs', to='mirrors.MirrorUrl'),
+ preserve_default=True,
+ ),
+ ]
diff --git a/mirrors/migrations/0002_rename_model_tables.py b/mirrors/migrations/0002_rename_model_tables.py
deleted file mode 100644
index 087edd68..00000000
--- a/mirrors/migrations/0002_rename_model_tables.py
+++ /dev/null
@@ -1,80 +0,0 @@
-# encoding: utf-8
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-class Migration(SchemaMigration):
-
- depends_on = (
- ('main', '0030_move_mirror_models'),
- )
-
- mirror_apps = [ 'mirror', 'mirrorprotocol', 'mirrorurl', 'mirrorrsync' ]
-
- def forwards(self, orm):
- db.rename_table('main_mirror', 'mirrors_mirror')
- db.rename_table('main_mirrorurl', 'mirrors_mirrorurl')
- db.rename_table('main_mirrorrsync', 'mirrors_mirrorrsync')
- db.rename_table('main_mirrorprotocol', 'mirrors_mirrorprotocol')
-
- if not db.dry_run:
- ct = orm['contenttypes.ContentType'].objects
- ct.filter(app_label='main', model__in=self.mirror_apps).update(
- app_label='mirrors')
-
- def backwards(self, orm):
- db.rename_table('mirrors_mirror', 'main_mirror')
- db.rename_table('mirrors_mirrorurl', 'main_mirrorurl')
- db.rename_table('mirrors_mirrorrsync', 'main_mirrorrsync')
- db.rename_table('mirrors_mirrorprotocol', 'main_mirrorprotocol')
-
- if not db.dry_run:
- ct = orm['contenttypes.ContentType'].objects
- ct.filter(app_label='mirrors', model__in=self.mirror_apps).update(
- app_label='main')
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True'})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'object_name': 'MirrorProtocol'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'max_length': '255'})
- },
- 'contenttypes.contenttype': {
- 'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
- 'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
- 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0003_auto__add_mirrorlog.py b/mirrors/migrations/0003_auto__add_mirrorlog.py
deleted file mode 100644
index 5b4c225b..00000000
--- a/mirrors/migrations/0003_auto__add_mirrorlog.py
+++ /dev/null
@@ -1,72 +0,0 @@
-# encoding: utf-8
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- # Adding model 'MirrorLog'
- db.create_table('mirrors_mirrorlog', (
- ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
- ('url', self.gf('django.db.models.fields.related.ForeignKey')(related_name='logs', to=orm['mirrors.MirrorUrl'])),
- ('check_time', self.gf('django.db.models.fields.DateTimeField')(db_index=True)),
- ('last_sync', self.gf('django.db.models.fields.DateTimeField')(null=True)),
- ('duration', self.gf('django.db.models.fields.FloatField')(null=True)),
- ('is_success', self.gf('django.db.models.fields.BooleanField')(default=True)),
- ('error', self.gf('django.db.models.fields.CharField')(default='', max_length=255, blank=True)),
- ))
- db.send_create_signal('mirrors', ['MirrorLog'])
-
- def backwards(self, orm):
- # Deleting model 'MirrorLog'
- db.delete_table('mirrors_mirrorlog')
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'object_name': 'MirrorProtocol'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0004_auto__add_field_mirrorprotocol_is_download.py b/mirrors/migrations/0004_auto__add_field_mirrorprotocol_is_download.py
deleted file mode 100644
index 0506e2cd..00000000
--- a/mirrors/migrations/0004_auto__add_field_mirrorprotocol_is_download.py
+++ /dev/null
@@ -1,62 +0,0 @@
-# encoding: utf-8
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- db.add_column('mirrors_mirrorprotocol', 'is_download', self.gf('django.db.models.fields.BooleanField')(default=True), keep_default=True)
-
- def backwards(self, orm):
- db.delete_column('mirrors_mirrorprotocol', 'is_download')
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'object_name': 'MirrorProtocol'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0005_populate_protocol_is_download.py b/mirrors/migrations/0005_populate_protocol_is_download.py
deleted file mode 100644
index 6d488388..00000000
--- a/mirrors/migrations/0005_populate_protocol_is_download.py
+++ /dev/null
@@ -1,64 +0,0 @@
-# encoding: utf-8
-import datetime
-from south.db import db
-from south.v2 import DataMigration
-from django.db import models
-
-class Migration(DataMigration):
-
- def forwards(self, orm):
- orm.MirrorProtocol.objects.filter(protocol__iexact='ftp').update(is_download=True)
- orm.MirrorProtocol.objects.filter(protocol__iexact='http').update(is_download=True)
- orm.MirrorProtocol.objects.filter(protocol__iexact='rsync').update(is_download=False)
-
- def backwards(self, orm):
- pass
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'object_name': 'MirrorProtocol'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0006_auto__add_field_mirrorurl_has_ipv4__add_field_mirrorurl_has_ipv6.py b/mirrors/migrations/0006_auto__add_field_mirrorurl_has_ipv4__add_field_mirrorurl_has_ipv6.py
deleted file mode 100644
index 5a40207d..00000000
--- a/mirrors/migrations/0006_auto__add_field_mirrorurl_has_ipv4__add_field_mirrorurl_has_ipv6.py
+++ /dev/null
@@ -1,66 +0,0 @@
-# encoding: utf-8
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- db.add_column('mirrors_mirrorurl', 'has_ipv4', self.gf('django.db.models.fields.BooleanField')(default=True), keep_default=True)
- db.add_column('mirrors_mirrorurl', 'has_ipv6', self.gf('django.db.models.fields.BooleanField')(default=False), keep_default=True)
-
- def backwards(self, orm):
- db.delete_column('mirrors_mirrorurl', 'has_ipv4')
- db.delete_column('mirrors_mirrorurl', 'has_ipv6')
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'object_name': 'MirrorProtocol'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0007_unique_names_urls.py b/mirrors/migrations/0007_unique_names_urls.py
deleted file mode 100644
index 49c0fbb7..00000000
--- a/mirrors/migrations/0007_unique_names_urls.py
+++ /dev/null
@@ -1,66 +0,0 @@
-# encoding: utf-8
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- db.create_unique('mirrors_mirror', ['name'])
- db.create_unique('mirrors_mirrorurl', ['url'])
-
- def backwards(self, orm):
- db.delete_unique('mirrors_mirrorurl', ['url'])
- db.delete_unique('mirrors_mirror', ['name'])
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0008_auto__add_field_mirrorurl_country.py b/mirrors/migrations/0008_auto__add_field_mirrorurl_country.py
deleted file mode 100644
index 660ac080..00000000
--- a/mirrors/migrations/0008_auto__add_field_mirrorurl_country.py
+++ /dev/null
@@ -1,67 +0,0 @@
-# encoding: utf-8
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- # Adding field 'MirrorUrl.country'
- db.add_column('mirrors_mirrorurl', 'country', self.gf('django.db.models.fields.CharField')(db_index=True, max_length=255, null=True, blank=True), keep_default=False)
-
- def backwards(self, orm):
- # Deleting field 'MirrorUrl.country'
- db.delete_column('mirrors_mirrorurl', 'country')
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django.db.models.fields.CharField', [], {'db_index': 'True', 'max_length': '255', 'null': 'True', 'blank': 'True'}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0009_auto__chg_field_mirrorurl_country.py b/mirrors/migrations/0009_auto__chg_field_mirrorurl_country.py
deleted file mode 100644
index bca6b6fb..00000000
--- a/mirrors/migrations/0009_auto__chg_field_mirrorurl_country.py
+++ /dev/null
@@ -1,66 +0,0 @@
-# encoding: utf-8
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- pass
-
-
- def backwards(self, orm):
- pass
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django.db.models.fields.CharField', [], {'db_index': 'True', 'max_length': '255', 'null': 'True', 'blank': 'True'}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0010_auto__add_field_mirrorprotocol_default.py b/mirrors/migrations/0010_auto__add_field_mirrorprotocol_default.py
deleted file mode 100644
index 66e60090..00000000
--- a/mirrors/migrations/0010_auto__add_field_mirrorprotocol_default.py
+++ /dev/null
@@ -1,66 +0,0 @@
-# encoding: utf-8
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- db.add_column('mirrors_mirrorprotocol', 'default', self.gf('django.db.models.fields.BooleanField')(default=True), keep_default=True)
-
- def backwards(self, orm):
- db.delete_column('mirrors_mirrorprotocol', 'default')
-
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django.db.models.fields.CharField', [], {'db_index': 'True', 'max_length': '255', 'null': 'True', 'blank': 'True'}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0011_adjust_protocol_defaults.py b/mirrors/migrations/0011_adjust_protocol_defaults.py
deleted file mode 100644
index a5ffafb4..00000000
--- a/mirrors/migrations/0011_adjust_protocol_defaults.py
+++ /dev/null
@@ -1,67 +0,0 @@
-# encoding: utf-8
-from south.db import db
-from south.v2 import DataMigration
-from django.db import models
-
-class Migration(DataMigration):
-
- def forwards(self, orm):
- orm.MirrorProtocol.objects.all().update(default=False)
- orm.MirrorProtocol.objects.filter(protocol='http').update(default=True)
-
- def backwards(self, orm):
- pass
-
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django.db.models.fields.CharField', [], {'db_index': 'True', 'max_length': '255', 'null': 'True', 'blank': 'True'}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0012_auto__add_on_delete_attribute.py b/mirrors/migrations/0012_auto__add_on_delete_attribute.py
deleted file mode 100644
index f81fe0ae..00000000
--- a/mirrors/migrations/0012_auto__add_on_delete_attribute.py
+++ /dev/null
@@ -1,68 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- db.alter_column('mirrors_mirror', 'upstream_id', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['mirrors.Mirror'], null=True, on_delete=models.SET_NULL))
- db.alter_column('mirrors_mirrorurl', 'protocol_id', self.gf('django.db.models.fields.related.ForeignKey')(on_delete=models.PROTECT, to=orm['mirrors.MirrorProtocol']))
-
- def backwards(self, orm):
- db.alter_column('mirrors_mirror', 'upstream_id', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['mirrors.Mirror'], null=True))
- db.alter_column('mirrors_mirrorurl', 'protocol_id', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['mirrors.MirrorProtocol']))
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django.db.models.fields.CharField', [], {'db_index': 'True', 'max_length': '255', 'null': 'True', 'blank': 'True'}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0013_rename_country_fields.py b/mirrors/migrations/0013_rename_country_fields.py
deleted file mode 100644
index 8a9bc34a..00000000
--- a/mirrors/migrations/0013_rename_country_fields.py
+++ /dev/null
@@ -1,68 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- db.rename_column('mirrors_mirror', 'country', 'country_old')
- db.rename_column('mirrors_mirrorurl', 'country', 'country_old')
-
- def backwards(self, orm):
- db.rename_column('mirrors_mirror', 'country_old', 'country')
- db.rename_column('mirrors_mirrorurl', 'country_old', 'country')
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country_old', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country_old': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country_old': ('django.db.models.fields.CharField', [], {'db_index': 'True', 'max_length': '255', 'null': 'True', 'blank': 'True'}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0014_add_country_code_fields.py b/mirrors/migrations/0014_add_country_code_fields.py
deleted file mode 100644
index 010194d7..00000000
--- a/mirrors/migrations/0014_add_country_code_fields.py
+++ /dev/null
@@ -1,74 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- db.add_column('mirrors_mirror', 'country',
- self.gf('django_countries.fields.CountryField')(default='', max_length=2, blank=True),
- keep_default=False)
- db.add_column('mirrors_mirrorurl', 'country',
- self.gf('django_countries.fields.CountryField')(default='', max_length=2, blank=True),
- keep_default=False)
-
- def backwards(self, orm):
- db.delete_column('mirrors_mirror', 'country')
- db.delete_column('mirrors_mirrorurl', 'country')
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django_countries.fields.CountryField', [], {'max_length': '2', 'blank': 'True'}),
- 'country_old': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django_countries.fields.CountryField', [], {'max_length': '2', 'blank': 'True'}),
- 'country_old': ('django.db.models.fields.CharField', [], {'db_index': 'True', 'max_length': '255', 'null': 'True', 'blank': 'True'}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0015_assign_country_codes.py b/mirrors/migrations/0015_assign_country_codes.py
deleted file mode 100644
index 5d83e02c..00000000
--- a/mirrors/migrations/0015_assign_country_codes.py
+++ /dev/null
@@ -1,93 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import DataMigration
-from django.db import models
-
-from django_countries.data import COUNTRIES
-
-class Migration(DataMigration):
-
- def forwards(self, orm):
- reverse_map = dict((v.upper(), k) for k, v in COUNTRIES.items())
- # add a few special cases to the list that we know might exist
- reverse_map['GREAT BRITAIN'] = 'GB'
- reverse_map['KOREA'] = 'KR'
- reverse_map['MACEDONIA'] = 'MK'
- reverse_map['RUSSIA'] = 'RU'
- reverse_map['SOUTH KOREA'] = 'KR'
- reverse_map['TAIWAN'] = 'TW'
- reverse_map['VIETNAM'] = 'VN'
-
- for country_name in orm.Mirror.objects.values_list(
- 'country_old', flat=True).order_by().distinct():
- code = reverse_map.get(country_name.upper(), '')
- orm.Mirror.objects.filter(
- country_old=country_name).update(country=code)
-
- for country_name in orm.MirrorUrl.objects.filter(
- country_old__isnull=False).values_list(
- 'country_old', flat=True).order_by().distinct():
- code = reverse_map.get(country_name.upper(), '')
- orm.MirrorUrl.objects.filter(
- country_old=country_name).update(country=code)
-
- def backwards(self, orm):
- orm.MirrorUrl.objects.all().update(country='')
- orm.Mirror.objects.all().update(country='')
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django_countries.fields.CountryField', [], {'max_length': '2', 'blank': 'True'}),
- 'country_old': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django_countries.fields.CountryField', [], {'max_length': '2', 'blank': 'True'}),
- 'country_old': ('django.db.models.fields.CharField', [], {'db_index': 'True', 'max_length': '255', 'null': 'True', 'blank': 'True'}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
- symmetrical = True
diff --git a/mirrors/migrations/0016_auto__del_field_mirror_country_old__del_field_mirrorurl_country_old.py b/mirrors/migrations/0016_auto__del_field_mirror_country_old__del_field_mirrorurl_country_old.py
deleted file mode 100644
index b296d7ae..00000000
--- a/mirrors/migrations/0016_auto__del_field_mirror_country_old__del_field_mirrorurl_country_old.py
+++ /dev/null
@@ -1,76 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- db.delete_column('mirrors_mirror', 'country_old')
- db.delete_column('mirrors_mirrorurl', 'country_old')
- db.create_index('mirrors_mirror', ['country'])
- db.create_index('mirrors_mirrorurl', ['country'])
-
- def backwards(self, orm):
- db.delete_index('mirrors_mirrorurl', ['country'])
- db.delete_index('mirrors_mirror', ['country'])
- db.add_column('mirrors_mirror', 'country_old',
- self.gf('django.db.models.fields.CharField')(default='Any', max_length=255, db_index=True),
- keep_default=False)
- db.add_column('mirrors_mirrorurl', 'country_old',
- self.gf('django.db.models.fields.CharField')(blank=True, max_length=255, null=True, db_index=True),
- keep_default=False)
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0017_auto__chg_field_mirrorlog_error.py b/mirrors/migrations/0017_auto__chg_field_mirrorlog_error.py
deleted file mode 100644
index 60c4ec26..00000000
--- a/mirrors/migrations/0017_auto__chg_field_mirrorlog_error.py
+++ /dev/null
@@ -1,66 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- db.alter_column('mirrors_mirrorlog', 'error', self.gf('django.db.models.fields.TextField')(default=''))
-
- def backwards(self, orm):
- db.alter_column('mirrors_mirrorlog', 'error', self.gf('django.db.models.fields.CharField')(max_length=255))
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0018_auto__add_field_mirror_alternate_email.py b/mirrors/migrations/0018_auto__add_field_mirror_alternate_email.py
deleted file mode 100644
index a08699e8..00000000
--- a/mirrors/migrations/0018_auto__add_field_mirror_alternate_email.py
+++ /dev/null
@@ -1,68 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
- def forwards(self, orm):
- db.add_column('mirrors_mirror', 'alternate_email',
- self.gf('django.db.models.fields.EmailField')(default='', max_length=255, blank=True),
- keep_default=False)
-
- def backwards(self, orm):
- db.delete_column('mirrors_mirror', 'alternate_email')
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'alternate_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0019_move_country_data_to_url.py b/mirrors/migrations/0019_move_country_data_to_url.py
deleted file mode 100644
index 81b7bb3e..00000000
--- a/mirrors/migrations/0019_move_country_data_to_url.py
+++ /dev/null
@@ -1,74 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import DataMigration
-from django.db import models
-
-class Migration(DataMigration):
-
- def forwards(self, orm):
- for url in orm.MirrorUrl.objects.select_related('mirror').all():
- # set the country field on the URL if we have one,
- # and it isn't already set to anything.
- if url.country or not url.mirror.country:
- continue
- orm.MirrorUrl.objects.filter(pk=url.pk).update(
- country=url.mirror.country)
-
- def backwards(self, orm):
- pass
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('country', 'name')", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'alternate_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
- symmetrical = True
diff --git a/mirrors/migrations/0020_auto__del_field_mirror_country.py b/mirrors/migrations/0020_auto__del_field_mirror_country.py
deleted file mode 100644
index c2220a50..00000000
--- a/mirrors/migrations/0020_auto__del_field_mirror_country.py
+++ /dev/null
@@ -1,70 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- db.delete_column('mirrors_mirror', 'country')
-
-
- def backwards(self, orm):
- db.add_column('mirrors_mirror', 'country',
- self.gf('django_countries.fields.CountryField')(blank=True, default='', max_length=2, db_index=True),
- keep_default=False)
-
-
- models = {
- 'mirrors.mirror': {
- 'Meta': {'ordering': "('name',)", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'alternate_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- 'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['mirrors.MirrorUrl']"})
- },
- 'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- 'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '24'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': "orm['mirrors.Mirror']"})
- },
- 'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': "orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': "orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0021_auto__chg_field_mirrorrsync_ip.py b/mirrors/migrations/0021_auto__chg_field_mirrorrsync_ip.py
deleted file mode 100644
index bbf14bb0..00000000
--- a/mirrors/migrations/0021_auto__chg_field_mirrorrsync_ip.py
+++ /dev/null
@@ -1,66 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- db.alter_column(u'mirrors_mirrorrsync', 'ip', self.gf('django.db.models.fields.CharField')(max_length=44))
-
- def backwards(self, orm):
- db.alter_column(u'mirrors_mirrorrsync', 'ip', self.gf('django.db.models.fields.CharField')(max_length=24))
-
- models = {
- u'mirrors.mirror': {
- 'Meta': {'ordering': "('name',)", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'alternate_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- u'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': u"orm['mirrors.MirrorUrl']"})
- },
- u'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- u'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '44'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': u"orm['mirrors.Mirror']"})
- },
- u'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': u"orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': u"orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0022_auto__add_checklocation.py b/mirrors/migrations/0022_auto__add_checklocation.py
deleted file mode 100644
index 896b2dab..00000000
--- a/mirrors/migrations/0022_auto__add_checklocation.py
+++ /dev/null
@@ -1,83 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- db.create_table(u'mirrors_checklocation', (
- (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
- ('hostname', self.gf('django.db.models.fields.CharField')(max_length=255)),
- ('source_ip', self.gf('django.db.models.fields.GenericIPAddressField')(unique=True, max_length=39)),
- ('country', self.gf('django_countries.fields.CountryField')(max_length=2)),
- ('created', self.gf('django.db.models.fields.DateTimeField')()),
- ))
- db.send_create_signal(u'mirrors', ['CheckLocation'])
-
-
- def backwards(self, orm):
- db.delete_table(u'mirrors_checklocation')
-
-
- models = {
- u'mirrors.checklocation': {
- 'Meta': {'ordering': "('hostname', 'source_ip')", 'object_name': 'CheckLocation'},
- 'country': ('django_countries.fields.CountryField', [], {'max_length': '2'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'hostname': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'source_ip': ('django.db.models.fields.GenericIPAddressField', [], {'unique': 'True', 'max_length': '39'})
- },
- u'mirrors.mirror': {
- 'Meta': {'ordering': "('name',)", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'alternate_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- u'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': u"orm['mirrors.MirrorUrl']"})
- },
- u'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- u'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '44'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': u"orm['mirrors.Mirror']"})
- },
- u'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': u"orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': u"orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0023_auto__add_field_mirrorurl_created__add_field_mirrorrsync_created__add_.py b/mirrors/migrations/0023_auto__add_field_mirrorurl_created__add_field_mirrorrsync_created__add_.py
deleted file mode 100644
index 1a1f48a0..00000000
--- a/mirrors/migrations/0023_auto__add_field_mirrorurl_created__add_field_mirrorrsync_created__add_.py
+++ /dev/null
@@ -1,97 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-from pytz import utc
-
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- default = datetime.datetime(2000, 1, 1, 0, 0).replace(tzinfo=utc)
- db.add_column(u'mirrors_mirrorurl', 'created',
- self.gf('django.db.models.fields.DateTimeField')(default=default),
- keep_default=False)
- db.add_column(u'mirrors_mirrorrsync', 'created',
- self.gf('django.db.models.fields.DateTimeField')(default=default),
- keep_default=False)
- db.add_column(u'mirrors_mirrorprotocol', 'created',
- self.gf('django.db.models.fields.DateTimeField')(default=default),
- keep_default=False)
- db.add_column(u'mirrors_mirror', 'created',
- self.gf('django.db.models.fields.DateTimeField')(default=default),
- keep_default=False)
-
-
- def backwards(self, orm):
- db.delete_column(u'mirrors_mirrorurl', 'created')
- db.delete_column(u'mirrors_mirrorrsync', 'created')
- db.delete_column(u'mirrors_mirrorprotocol', 'created')
- db.delete_column(u'mirrors_mirror', 'created')
-
-
- models = {
- u'mirrors.checklocation': {
- 'Meta': {'ordering': "('hostname', 'source_ip')", 'object_name': 'CheckLocation'},
- 'country': ('django_countries.fields.CountryField', [], {'max_length': '2'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'hostname': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'source_ip': ('django.db.models.fields.GenericIPAddressField', [], {'unique': 'True', 'max_length': '39'})
- },
- u'mirrors.mirror': {
- 'Meta': {'ordering': "('name',)", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'alternate_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- u'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': u"orm['mirrors.MirrorUrl']"})
- },
- u'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- u'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '44'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': u"orm['mirrors.Mirror']"})
- },
- u'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': u"orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': u"orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0024_auto__add_field_mirrorlog_location.py b/mirrors/migrations/0024_auto__add_field_mirrorlog_location.py
deleted file mode 100644
index acf8df17..00000000
--- a/mirrors/migrations/0024_auto__add_field_mirrorlog_location.py
+++ /dev/null
@@ -1,83 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- db.add_column(u'mirrors_mirrorlog', 'location',
- self.gf('django.db.models.fields.related.ForeignKey')(related_name='logs', null=True, to=orm['mirrors.CheckLocation']),
- keep_default=False)
-
-
- def backwards(self, orm):
- db.delete_column(u'mirrors_mirrorlog', 'location_id')
-
-
- models = {
- u'mirrors.checklocation': {
- 'Meta': {'ordering': "('hostname', 'source_ip')", 'object_name': 'CheckLocation'},
- 'country': ('django_countries.fields.CountryField', [], {'max_length': '2'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'hostname': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'source_ip': ('django.db.models.fields.GenericIPAddressField', [], {'unique': 'True', 'max_length': '39'})
- },
- u'mirrors.mirror': {
- 'Meta': {'ordering': "('name',)", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'alternate_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- u'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'location': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'null': 'True', 'to': u"orm['mirrors.CheckLocation']"}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': u"orm['mirrors.MirrorUrl']"})
- },
- u'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- u'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('django.db.models.fields.CharField', [], {'max_length': '44'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': u"orm['mirrors.Mirror']"})
- },
- u'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': u"orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': u"orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0025_auto__chg_field_mirrorrsync_ip.py b/mirrors/migrations/0025_auto__chg_field_mirrorrsync_ip.py
deleted file mode 100644
index b359b637..00000000
--- a/mirrors/migrations/0025_auto__chg_field_mirrorrsync_ip.py
+++ /dev/null
@@ -1,85 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- if db.backend_name == 'postgres':
- # For PostgreSQL, because it uses the 'inet' type and not a varchar
- # column, we need to add an explict 'USING' cast to the SQL
- # statement. We then execute the alter_column as well to ensure any
- # of the other side-effects happen.
- db.execute('ALTER TABLE "mirrors_mirrorrsync" ALTER COLUMN "ip" TYPE inet USING "ip"::inet')
- db.alter_column(u'mirrors_mirrorrsync', 'ip', self.gf('mirrors.fields.IPNetworkField')(max_length=44))
-
- def backwards(self, orm):
- db.alter_column(u'mirrors_mirrorrsync', 'ip', self.gf('django.db.models.fields.CharField')(max_length=44))
-
- models = {
- u'mirrors.checklocation': {
- 'Meta': {'ordering': "('hostname', 'source_ip')", 'object_name': 'CheckLocation'},
- 'country': ('django_countries.fields.CountryField', [], {'max_length': '2'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'hostname': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'source_ip': ('django.db.models.fields.GenericIPAddressField', [], {'unique': 'True', 'max_length': '39'})
- },
- u'mirrors.mirror': {
- 'Meta': {'ordering': "('name',)", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'alternate_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- u'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'location': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'null': 'True', 'to': u"orm['mirrors.CheckLocation']"}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': u"orm['mirrors.MirrorUrl']"})
- },
- u'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- u'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('mirrors.fields.IPNetworkField', [], {'max_length': '44'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': u"orm['mirrors.Mirror']"})
- },
- u'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': u"orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': u"orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0026_auto__add_field_mirrorurl_active.py b/mirrors/migrations/0026_auto__add_field_mirrorurl_active.py
deleted file mode 100644
index f989435f..00000000
--- a/mirrors/migrations/0026_auto__add_field_mirrorurl_active.py
+++ /dev/null
@@ -1,83 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- db.add_column(u'mirrors_mirrorurl', 'active',
- self.gf('django.db.models.fields.BooleanField')(default=True),
- keep_default=True)
-
- def backwards(self, orm):
- db.delete_column(u'mirrors_mirrorurl', 'active')
-
-
- models = {
- u'mirrors.checklocation': {
- 'Meta': {'ordering': "('hostname', 'source_ip')", 'object_name': 'CheckLocation'},
- 'country': ('django_countries.fields.CountryField', [], {'max_length': '2'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'hostname': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'source_ip': ('django.db.models.fields.GenericIPAddressField', [], {'unique': 'True', 'max_length': '39'})
- },
- u'mirrors.mirror': {
- 'Meta': {'ordering': "('name',)", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'alternate_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- u'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'location': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'null': 'True', 'to': u"orm['mirrors.CheckLocation']"}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': u"orm['mirrors.MirrorUrl']"})
- },
- u'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- u'mirrors.mirrorrsync': {
- 'Meta': {'object_name': 'MirrorRsync'},
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('mirrors.fields.IPNetworkField', [], {'max_length': '44'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': u"orm['mirrors.Mirror']"})
- },
- u'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': u"orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': u"orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/migrations/0027_auto__add_field_mirror_bug.py b/mirrors/migrations/0027_auto__add_field_mirror_bug.py
deleted file mode 100644
index f7304ba8..00000000
--- a/mirrors/migrations/0027_auto__add_field_mirror_bug.py
+++ /dev/null
@@ -1,91 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
- def forwards(self, orm):
- db.add_column(u'mirrors_mirror', 'bug',
- self.gf('django.db.models.fields.PositiveIntegerField')(null=True),
- keep_default=False)
- # UPDATE mirrors_mirror m
- # SET bug = (
- # SELECT extracted::int FROM (
- # SELECT id, substring(notes from 'FS#([\d]+)') AS extracted FROM mirrors_mirror
- # ) a
- # WHERE extracted IS NOT NULL AND a.id = m.id
- # )
- # WHERE notes LIKE '%FS#%';
-
- def backwards(self, orm):
- db.delete_column(u'mirrors_mirror', 'bug')
-
-
- models = {
- u'mirrors.checklocation': {
- 'Meta': {'ordering': "('hostname', 'source_ip')", 'object_name': 'CheckLocation'},
- 'country': ('django_countries.fields.CountryField', [], {'max_length': '2'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'hostname': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'source_ip': ('django.db.models.fields.GenericIPAddressField', [], {'unique': 'True', 'max_length': '39'})
- },
- u'mirrors.mirror': {
- 'Meta': {'ordering': "('name',)", 'object_name': 'Mirror'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'admin_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'alternate_email': ('django.db.models.fields.EmailField', [], {'max_length': '255', 'blank': 'True'}),
- 'bug': ('django.db.models.fields.PositiveIntegerField', [], {'null': 'True'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'isos': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
- 'notes': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
- 'public': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'rsync_password': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'rsync_user': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '50', 'blank': 'True'}),
- 'tier': ('django.db.models.fields.SmallIntegerField', [], {'default': '2'}),
- 'upstream': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['mirrors.Mirror']", 'null': 'True', 'on_delete': 'models.SET_NULL'})
- },
- u'mirrors.mirrorlog': {
- 'Meta': {'object_name': 'MirrorLog'},
- 'check_time': ('django.db.models.fields.DateTimeField', [], {'db_index': 'True'}),
- 'duration': ('django.db.models.fields.FloatField', [], {'null': 'True'}),
- 'error': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_success': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'last_sync': ('django.db.models.fields.DateTimeField', [], {'null': 'True'}),
- 'location': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'null': 'True', 'to': u"orm['mirrors.CheckLocation']"}),
- 'url': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': u"orm['mirrors.MirrorUrl']"})
- },
- u'mirrors.mirrorprotocol': {
- 'Meta': {'ordering': "('protocol',)", 'object_name': 'MirrorProtocol'},
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'default': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'is_download': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'protocol': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '10'})
- },
- u'mirrors.mirrorrsync': {
- 'Meta': {'ordering': "('ip',)", 'object_name': 'MirrorRsync'},
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'ip': ('mirrors.fields.IPNetworkField', [], {'max_length': '44'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'rsync_ips'", 'to': u"orm['mirrors.Mirror']"})
- },
- u'mirrors.mirrorurl': {
- 'Meta': {'object_name': 'MirrorUrl'},
- 'active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'country': ('django_countries.fields.CountryField', [], {'db_index': 'True', 'max_length': '2', 'blank': 'True'}),
- 'created': ('django.db.models.fields.DateTimeField', [], {}),
- 'has_ipv4': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
- 'has_ipv6': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
- u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'mirror': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'to': u"orm['mirrors.Mirror']"}),
- 'protocol': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'urls'", 'on_delete': 'models.PROTECT', 'to': u"orm['mirrors.MirrorProtocol']"}),
- 'url': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
- }
- }
-
- complete_apps = ['mirrors']
diff --git a/mirrors/models.py b/mirrors/models.py
index 0b053043..641a6b97 100644
--- a/mirrors/models.py
+++ b/mirrors/models.py
@@ -32,6 +32,7 @@ class Mirror(models.Model):
bug = models.PositiveIntegerField("Flyspray bug", null=True, blank=True)
notes = models.TextField(blank=True)
created = models.DateTimeField(editable=False)
+ last_modified = models.DateTimeField(editable=False)
class Meta:
ordering = ('name',)
@@ -74,6 +75,12 @@ class MirrorUrl(models.Model):
created = models.DateTimeField(editable=False)
active = models.BooleanField(default=True)
+ class Meta:
+ verbose_name = 'mirror URL'
+
+ def __unicode__(self):
+ return self.url
+
def address_families(self):
hostname = urlparse(self.url).hostname
info = socket.getaddrinfo(hostname, None, 0, socket.SOCK_STREAM)
@@ -100,11 +107,8 @@ class MirrorUrl(models.Model):
self.has_ipv4 = False
self.has_ipv6 = False
- def __unicode__(self):
- return self.url
-
- class Meta:
- verbose_name = 'mirror URL'
+ def get_absolute_url(self):
+ return '/mirrors/%s/%d/' % (self.mirror.name, self.pk)
class MirrorRsync(models.Model):
@@ -114,7 +118,7 @@ class MirrorRsync(models.Model):
created = models.DateTimeField(editable=False)
def __unicode__(self):
- return self.ip
+ return unicode(self.ip)
class Meta:
verbose_name = 'mirror rsync IP'
@@ -123,7 +127,7 @@ class MirrorRsync(models.Model):
class CheckLocation(models.Model):
hostname = models.CharField(max_length=255)
- source_ip = models.GenericIPAddressField(verbose_name='source IP',
+ source_ip = models.GenericIPAddressField('source IP',
unpack_ipv4=True, unique=True)
country = CountryField()
created = models.DateTimeField(editable=False)