# Generated by Django 5.2.8 on 2025-12-06 15:03

import apps.sigils.fields
from django.db import migrations, models


class Migration(migrations.Migration):

    initial = True

    dependencies = []

    operations = [
        migrations.CreateModel(
            name="GoDaddyDNSRecord",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("is_seed_data", models.BooleanField(default=False, editable=False)),
                ("is_user_data", models.BooleanField(default=False, editable=False)),
                ("is_deleted", models.BooleanField(default=False, editable=False)),
                (
                    "domain",
                    apps.sigils.fields.SigilShortAutoField(
                        help_text="Base domain such as example.com.", max_length=253
                    ),
                ),
                (
                    "name",
                    apps.sigils.fields.SigilShortAutoField(
                        help_text="Record host. Use @ for the zone apex.",
                        max_length=253,
                    ),
                ),
                (
                    "record_type",
                    models.CharField(
                        choices=[
                            ("A", "A"),
                            ("AAAA", "AAAA"),
                            ("CNAME", "CNAME"),
                            ("MX", "MX"),
                            ("NS", "NS"),
                            ("SRV", "SRV"),
                            ("TXT", "TXT"),
                        ],
                        default="A",
                        max_length=10,
                        verbose_name="Type",
                    ),
                ),
                (
                    "data",
                    apps.sigils.fields.SigilLongAutoField(
                        help_text="Record value such as an IP address or hostname."
                    ),
                ),
                (
                    "ttl",
                    models.PositiveIntegerField(
                        default=600, help_text="Time to live in seconds."
                    ),
                ),
                (
                    "priority",
                    models.PositiveIntegerField(
                        blank=True,
                        help_text="Priority for MX and SRV records.",
                        null=True,
                    ),
                ),
                (
                    "port",
                    models.PositiveIntegerField(
                        blank=True, help_text="Port for SRV records.", null=True
                    ),
                ),
                (
                    "weight",
                    models.PositiveIntegerField(
                        blank=True, help_text="Weight for SRV records.", null=True
                    ),
                ),
                (
                    "service",
                    apps.sigils.fields.SigilShortAutoField(
                        blank=True,
                        help_text="Service label for SRV records (for example _sip).",
                        max_length=50,
                    ),
                ),
                (
                    "protocol",
                    apps.sigils.fields.SigilShortAutoField(
                        blank=True,
                        help_text="Protocol label for SRV records (for example _tcp).",
                        max_length=10,
                    ),
                ),
                ("last_synced_at", models.DateTimeField(blank=True, null=True)),
                ("last_verified_at", models.DateTimeField(blank=True, null=True)),
                ("last_error", models.TextField(blank=True)),
            ],
            options={
                "verbose_name": "GoDaddy Record",
                "verbose_name_plural": "GoDaddy Records",
                "db_table": "nodes_dnsrecord",
            },
        ),
    ]
