Add website HTTPS requests to Coulobre Panel
This commit is contained in:
1 parent
43d03d207e
commit
4d6aa0c281
14 files changed
+368
-3
No files matched your search
@@ -290,6 +290,15 @@ class WebProvisioningPlan(models.Model):
|
||||
and self.primary_domain == self.account.primary_domain
|
||||
)
|
||||
|
||||
@property
|
||||
def can_enable_https(self):
|
||||
activation = getattr(self, "activation", None)
|
||||
return (
|
||||
self.can_export
|
||||
and activation is not None
|
||||
and activation.state == "configured"
|
||||
)
|
||||
|
||||
|
||||
class ProvisioningJobManager(models.Manager):
|
||||
def queue(self, **target):
|
||||
@@ -334,6 +343,15 @@ class WebActivation(ProvisioningJob):
|
||||
)
|
||||
|
||||
|
||||
class WebHTTPS(ProvisioningJob):
|
||||
plan = models.OneToOneField(
|
||||
WebProvisioningPlan, on_delete=models.CASCADE, related_name="https"
|
||||
)
|
||||
|
||||
class Meta:
|
||||
verbose_name = "website HTTPS request"
|
||||
|
||||
|
||||
class DatabaseProvisioning(ProvisioningJob):
|
||||
database = models.OneToOneField(
|
||||
HostingDatabase, on_delete=models.CASCADE, related_name="provisioning"
|
||||
|
||||
Reference in new issue
Block a user