remove email related code
Build and Push Docker Images / Build and Push Docker Images (push) Failing after 9s

This commit is contained in:
2026-08-02 14:25:41 +05:00
parent 6cdf042f49
commit 00d25698c6
12 changed files with 30 additions and 199 deletions
View File
View File
+27
View File
@@ -0,0 +1,27 @@
# api/management/commands/seed.py
from django.core.management.base import BaseCommand
from api.models import Atoll, Island
class Command(BaseCommand):
help = "Seeds baseline reference data (atolls and islands) required for sign up."
def handle(self, *args, **options):
atoll, atoll_created = Atoll.objects.get_or_create(name="Faafu")
self.stdout.write(
self.style.SUCCESS(f"Created atoll: {atoll.name}")
if atoll_created
else self.style.NOTICE(f"Atoll already exists: {atoll.name}")
)
island, island_created = Island.objects.get_or_create(
name="Dharanboodhoo", defaults={"atoll": atoll}
)
self.stdout.write(
self.style.SUCCESS(f"Created island: {island.name} ({atoll.name})")
if island_created
else self.style.NOTICE(f"Island already exists: {island.name}")
)
self.stdout.write(self.style.SUCCESS("Seeding complete."))