authentik.enterprise.agents.migrations.0001_initial

 1# Generated by Django 5.2.16 on 2026-08-05 10:42
 2
 3import django.db.models.deletion
 4from django.db import migrations, models
 5
 6
 7class Migration(migrations.Migration):
 8
 9    initial = True
10
11    dependencies = [
12        ("authentik_core", "0063_actor"),
13    ]
14
15    operations = [
16        migrations.CreateModel(
17            name="Agent",
18            fields=[
19                (
20                    "actor_ptr",
21                    models.OneToOneField(
22                        auto_created=True,
23                        on_delete=django.db.models.deletion.CASCADE,
24                        parent_link=True,
25                        primary_key=True,
26                        serialize=False,
27                        to="authentik_core.actor",
28                    ),
29                ),
30            ],
31            options={
32                "verbose_name": "Agent",
33                "verbose_name_plural": "Agents",
34                "permissions": [("add_agent_self_service", "Add an agent user (self-service)")],
35                "abstract": False,
36            },
37            bases=("authentik_core.actor",),
38        ),
39    ]
class Migration(django.db.migrations.migration.Migration):
 8class Migration(migrations.Migration):
 9
10    initial = True
11
12    dependencies = [
13        ("authentik_core", "0063_actor"),
14    ]
15
16    operations = [
17        migrations.CreateModel(
18            name="Agent",
19            fields=[
20                (
21                    "actor_ptr",
22                    models.OneToOneField(
23                        auto_created=True,
24                        on_delete=django.db.models.deletion.CASCADE,
25                        parent_link=True,
26                        primary_key=True,
27                        serialize=False,
28                        to="authentik_core.actor",
29                    ),
30                ),
31            ],
32            options={
33                "verbose_name": "Agent",
34                "verbose_name_plural": "Agents",
35                "permissions": [("add_agent_self_service", "Add an agent user (self-service)")],
36                "abstract": False,
37            },
38            bases=("authentik_core.actor",),
39        ),
40    ]

The base class for all migrations.

Migration files will import this from django.db.migrations.Migration and subclass it as a class called Migration. It will have one or more of the following attributes:

  • operations: A list of Operation instances, probably from django.db.migrations.operations
  • dependencies: A list of tuples of (app_path, migration_name)
  • run_before: A list of tuples of (app_path, migration_name)
  • replaces: A list of migration_names

Note that all migrations come out of migrations and into the Loader or Graph as instances, having been initialized with their app label and name.

initial = True
dependencies = [('authentik_core', '0063_actor')]
operations = [<CreateModel name='Agent', fields=[('actor_ptr', <django.db.models.fields.related.OneToOneField>)], options={'verbose_name': 'Agent', 'verbose_name_plural': 'Agents', 'permissions': [('add_agent_self_service', 'Add an agent user (self-service)')], 'abstract': False}, bases=('authentik_core.actor',)>]