Commit 2ae3bec3 authored by ibuler's avatar ibuler

[Bugfix] Change user public key length to 5000, fixed #631

parent da5b9be5
......@@ -51,7 +51,6 @@ class AssetPermissionViewSet(viewsets.ModelViewSet):
assets.extend(list(instance.assets.all()))
asset_groups.extend(list(instance.asset_groups.all()))
system_users.extend(list(instance.system_users.all()))
print('Run')
associate_system_users_and_assets(system_users, assets, asset_groups)
def perform_create(self, serializer):
......
......@@ -39,7 +39,7 @@ class User(AbstractUser):
enable_otp = models.BooleanField(default=False, verbose_name=_('Enable OTP'))
secret_key_otp = models.CharField(max_length=16, blank=True)
_private_key = models.CharField(max_length=5000, blank=True, verbose_name=_('ssh private key'))
_public_key = models.CharField(max_length=1000, blank=True, verbose_name=_('ssh public key'))
_public_key = models.CharField(max_length=5000, blank=True, verbose_name=_('ssh public key'))
comment = models.TextField(max_length=200, blank=True, verbose_name=_('Comment'))
is_first_login = models.BooleanField(default=False)
date_expired = models.DateTimeField(default=date_expired_default, blank=True, null=True,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment