mirror of
				https://github.com/zulip/zulip.git
				synced 2025-11-03 21:43:21 +00:00 
			
		
		
		
	zilencer: Remove uniqueness constraint on RemoteZulipServer.hostname.
Enforcing the unique constraint adds an unnecessary support burden for figuring out who actually controls a given hostname, and in particular, for verifying updates to the org id/key on a re-install of the Zulip server.
This commit is contained in:
		
							
								
								
									
										20
									
								
								zilencer/migrations/0007_remotezulipserver_fix_uniqueness.py
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										20
									
								
								zilencer/migrations/0007_remotezulipserver_fix_uniqueness.py
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,20 @@
 | 
			
		||||
# -*- coding: utf-8 -*-
 | 
			
		||||
# Generated by Django 1.11.11 on 2018-04-30 06:55
 | 
			
		||||
from __future__ import unicode_literals
 | 
			
		||||
 | 
			
		||||
from django.db import migrations, models
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
class Migration(migrations.Migration):
 | 
			
		||||
 | 
			
		||||
    dependencies = [
 | 
			
		||||
        ('zilencer', '0006_customer'),
 | 
			
		||||
    ]
 | 
			
		||||
 | 
			
		||||
    operations = [
 | 
			
		||||
        migrations.AlterField(
 | 
			
		||||
            model_name='remotezulipserver',
 | 
			
		||||
            name='hostname',
 | 
			
		||||
            field=models.CharField(max_length=128),
 | 
			
		||||
        ),
 | 
			
		||||
    ]
 | 
			
		||||
@@ -12,7 +12,7 @@ class RemoteZulipServer(models.Model):
 | 
			
		||||
    uuid = models.CharField(max_length=36, unique=True)  # type: Text
 | 
			
		||||
    api_key = models.CharField(max_length=64)  # type: Text
 | 
			
		||||
 | 
			
		||||
    hostname = models.CharField(max_length=128, unique=True)  # type: Text
 | 
			
		||||
    hostname = models.CharField(max_length=128)  # type: Text
 | 
			
		||||
    contact_email = models.EmailField(blank=True, null=False)  # type: Text
 | 
			
		||||
    last_updated = models.DateTimeField('last updated', auto_now=True)  # type: datetime.datetime
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user