mirror of
https://gitlab2.federez.net/re2o/re2o
synced 2024-11-26 06:32:26 +00:00
54 lines
1.6 KiB
Python
54 lines
1.6 KiB
Python
# -*- coding: utf-8 -*-
|
|
# Generated by Django 1.11.28 on 2020-04-23 16:04
|
|
from __future__ import unicode_literals
|
|
|
|
from django.conf import settings
|
|
from django.db import migrations, models
|
|
import django.db.models.deletion
|
|
import ldapdb.models.fields
|
|
import re2o.mixins
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
|
|
dependencies = [
|
|
("users", "0091_auto_20200423_1256"),
|
|
]
|
|
|
|
operations = [
|
|
migrations.CreateModel(
|
|
name="SSHKey",
|
|
fields=[
|
|
(
|
|
"id",
|
|
models.AutoField(
|
|
auto_created=True,
|
|
primary_key=True,
|
|
serialize=False,
|
|
verbose_name="ID",
|
|
),
|
|
),
|
|
("key", models.TextField(blank=True, verbose_name="Public ssh key")),
|
|
(
|
|
"user",
|
|
models.ForeignKey(
|
|
on_delete=django.db.models.deletion.CASCADE,
|
|
to=settings.AUTH_USER_MODEL,
|
|
),
|
|
),
|
|
],
|
|
options={
|
|
"verbose_name": "SSH key",
|
|
"verbose_name_plural": "SSH keys",
|
|
"permissions": (("view_sshkey", "Can view an SSHKey object"),),
|
|
},
|
|
bases=(re2o.mixins.RevMixin, re2o.mixins.AclMixin, models.Model),
|
|
),
|
|
migrations.AddField(
|
|
model_name="ldapuser",
|
|
name="ssh_keys",
|
|
field=ldapdb.models.fields.ListField(
|
|
blank=True, db_column="sshkeys", null=True
|
|
),
|
|
),
|
|
]
|