16 lines
509 B
Python
16 lines
509 B
Python
"""Set the fixed quota on existing private spaces; filesystem relocation is manual."""
|
|
from django.db import migrations
|
|
|
|
|
|
QUOTA = 50 * 1024 ** 3
|
|
|
|
|
|
def set_private_quotas(apps, schema_editor):
|
|
Space = apps.get_model('drive', 'DriveSpace')
|
|
Space.objects.filter(private_owner__isnull=False).update(quota_bytes=QUOTA)
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
dependencies = [('drive', '0012_merge_20261014_0129')]
|
|
operations = [migrations.RunPython(set_private_quotas, migrations.RunPython.noop)]
|