This repository has been archived on 2024-05-31. You can view files and clone it, but cannot push or open issues or pull requests.
authentik/passbook/sources/ldap/migrations/0001_initial.py

97 lines
3.2 KiB
Python
Raw Normal View History

# Generated by Django 2.2.6 on 2019-10-08 20:43
2018-11-26 16:18:56 +00:00
2019-10-10 15:36:09 +00:00
import django.core.validators
2018-11-26 16:18:56 +00:00
import django.db.models.deletion
from django.db import migrations, models
class Migration(migrations.Migration):
initial = True
dependencies = [
("passbook_core", "0001_initial"),
2018-11-26 16:18:56 +00:00
]
operations = [
2019-10-10 15:36:09 +00:00
migrations.CreateModel(
2019-12-31 11:51:16 +00:00
name="LDAPPropertyMapping",
2019-10-10 15:36:09 +00:00
fields=[
2019-12-31 11:51:16 +00:00
(
"propertymapping_ptr",
models.OneToOneField(
auto_created=True,
on_delete=django.db.models.deletion.CASCADE,
parent_link=True,
primary_key=True,
serialize=False,
to="passbook_core.PropertyMapping",
),
),
("ldap_property", models.TextField()),
2019-12-31 11:51:16 +00:00
("object_field", models.TextField()),
2019-10-10 15:36:09 +00:00
],
options={"abstract": False,},
2019-12-31 11:51:16 +00:00
bases=("passbook_core.propertymapping",),
2019-10-10 15:36:09 +00:00
),
2018-11-26 16:18:56 +00:00
migrations.CreateModel(
name="LDAPSource",
2018-11-26 16:18:56 +00:00
fields=[
2019-12-31 11:51:16 +00:00
(
"source_ptr",
2019-12-31 11:51:16 +00:00
models.OneToOneField(
auto_created=True,
on_delete=django.db.models.deletion.CASCADE,
parent_link=True,
primary_key=True,
serialize=False,
to="passbook_core.Source",
2019-12-31 11:51:16 +00:00
),
),
(
"server_uri",
models.URLField(
2019-12-31 11:51:16 +00:00
validators=[
django.core.validators.URLValidator(
schemes=["ldap", "ldaps"]
)
]
2019-12-31 11:51:16 +00:00
),
),
("bind_cn", models.TextField()),
2019-12-31 11:51:16 +00:00
("bind_password", models.TextField()),
("start_tls", models.BooleanField(default=False)),
("base_dn", models.TextField()),
2019-12-31 11:51:16 +00:00
(
"additional_user_dn",
models.TextField(
help_text="Prepended to Base DN for User-queries."
2019-12-31 11:51:16 +00:00
),
),
(
"additional_group_dn",
models.TextField(
help_text="Prepended to Base DN for Group-queries."
2019-12-31 11:51:16 +00:00
),
),
("user_object_filter", models.TextField()),
("group_object_filter", models.TextField()),
2019-12-31 11:51:16 +00:00
("sync_groups", models.BooleanField(default=True)),
(
"sync_parent_group",
models.ForeignKey(
blank=True,
default=None,
on_delete=django.db.models.deletion.SET_DEFAULT,
to="passbook_core.Group",
),
),
2018-11-26 16:18:56 +00:00
],
options={
"verbose_name": "LDAP Source",
"verbose_name_plural": "LDAP Sources",
2018-11-26 16:18:56 +00:00
},
bases=("passbook_core.source",),
2018-11-26 16:18:56 +00:00
),
]