Added Repo-URL in repo list.

This commit is contained in:
Johannes Erwerle 2026-04-06 18:59:27 +02:00
parent 50784e3e7e
commit 9fdb75720c
2 changed files with 6 additions and 0 deletions

View file

@ -38,6 +38,10 @@ class BorgRepository(models.Model):
"""Returns the username of the linux user account for this user."""
return f"u-{self.pk}"
@property
def repo_url(self) -> str:
return f"{settings.BACKUP_USER}@{settings.BACKUP_REPO_HOST}:{self.user.pk}/{self.pk}"
def save(self):
from .tasks import update_user