mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2025-11-07 05:45:59 +01:00
final v2backups and sslv2
This commit is contained in:
@@ -24,7 +24,8 @@
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">{% trans "Select Website" %} </label>
|
||||
<div class="col-sm-6">
|
||||
<select id="selwebsite" ng-change="selectwebsite()" ng-model="selwebsite" class="form-control">
|
||||
<select id="selwebsite" ng-change="selectwebsite()" ng-model="selwebsite"
|
||||
class="form-control">
|
||||
{% for items in websiteList %}
|
||||
<option value="{{ items }}">{{ items }}</option>
|
||||
{% endfor %}
|
||||
@@ -37,8 +38,8 @@
|
||||
<label class="col-sm-3 control-label">{% trans "Select Backup Type" %} </label>
|
||||
<div class="col-sm-6">
|
||||
<select ng-change="selectbackuptype()" ng-model="v2backuptype" class="form-control">
|
||||
<option >SFTP</option>
|
||||
<option >GDrive</option>
|
||||
<option>SFTP</option>
|
||||
<option>GDrive</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -13,24 +13,36 @@
|
||||
|
||||
<div class="container">
|
||||
<div id="page-title">
|
||||
<h2>{% trans "Create V2 Backup" %} - <a target="_blank" href="http://go.cyberpanel.net/backup" style="height: 23px;line-height: 21px;" class="btn btn-border btn-alt border-red btn-link font-red" title=""><span>{% trans "Backup Docs" %}</span></a></h2>
|
||||
<h2>{% trans "Create V2 Backup" %} - <a target="_blank" href="http://go.cyberpanel.net/backup"
|
||||
style="height: 23px;line-height: 21px;"
|
||||
class="btn btn-border btn-alt border-red btn-link font-red"
|
||||
title=""><span>{% trans "Backup Docs" %}</span></a></h2>
|
||||
<p>{% trans "This page can be used to create your backup" %}</p>
|
||||
</div>
|
||||
|
||||
<div ng-controller="CreateV2Backup" class="panel">
|
||||
<div class="panel-body">
|
||||
<h3 class="title-hero">
|
||||
{% trans "Create v2 Backup" %} <img ng-hide="backupLoading" src="{% static 'images/loading.gif' %}"> - <a href="{% url 'RestoreV2backupSite' %}">Restore Backups</a>
|
||||
{% trans "Create v2 Backup" %} <img ng-hide="backupLoading" src="{% static 'images/loading.gif' %}">
|
||||
- <a href="{% url 'RestoreV2backupSite' %}">Restore Backups</a>
|
||||
</h3>
|
||||
<div class="example-box-wrapper">
|
||||
|
||||
<p align="center" style="margin-top: 2%; margin-bottom: 2%">
|
||||
<iframe width="788.54" height="443" src="https://youtu.be/kDUANNvtOwE"
|
||||
title="YouTube video player" frameborder="0"
|
||||
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
|
||||
allowfullscreen></iframe>
|
||||
</p>
|
||||
|
||||
<form class="form-horizontal bordered-row">
|
||||
|
||||
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">{% trans "Select Website" %} </label>
|
||||
<div class="col-sm-6">
|
||||
<select id="create-backup-select" ng-change="selectwebsite()" ng-model="selwebsite" class="form-control">
|
||||
<select id="create-backup-select" ng-change="selectwebsite()" ng-model="selwebsite"
|
||||
class="form-control">
|
||||
{% for items in websiteList %}
|
||||
<option value="{{ items }}">{{ items }}</option>
|
||||
{% endfor %}
|
||||
@@ -40,7 +52,8 @@
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">{% trans "Select Repo" %} </label>
|
||||
<div class="col-sm-6">
|
||||
<select id="reposelectbox" ng-change="selectrepo()" ng-model="testhabbi" class="form-control">
|
||||
<select id="reposelectbox" ng-change="selectrepo()" ng-model="testhabbi"
|
||||
class="form-control">
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
@@ -86,7 +99,10 @@
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">{% trans " " %} </label>
|
||||
<div class="col-sm-6">
|
||||
<button class="btn" id="CreateV2BackupButton" ng-click="CreateV2BackupButton()" style="border-radius: 6px;background-color: #3447b7;color: white !important;"> Create Backup</button>
|
||||
<button class="btn" id="CreateV2BackupButton" ng-click="CreateV2BackupButton()"
|
||||
style="border-radius: 6px;background-color: #3447b7;color: white !important;">
|
||||
Create Backup
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -134,7 +150,6 @@
|
||||
</form>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
@@ -11,16 +11,21 @@
|
||||
|
||||
</style>
|
||||
|
||||
{% if BackupStat %}
|
||||
<div class="container">
|
||||
<div id="page-title">
|
||||
<h2>{% trans "Restore V2 Backups" %} - <a target="_blank" href="http://go.cyberpanel.net/backup" style="height: 23px;line-height: 21px;" class="btn btn-border btn-alt border-red btn-link font-red" title=""><span>{% trans "Backup Docs" %}</span></a></h2>
|
||||
<h2>{% trans "Restore V2 Backups" %} - <a target="_blank" href="http://go.cyberpanel.net/backup"
|
||||
style="height: 23px;line-height: 21px;"
|
||||
class="btn btn-border btn-alt border-red btn-link font-red"
|
||||
title=""><span>{% trans "Backup Docs" %}</span></a></h2>
|
||||
<p>{% trans "This page can be used to restore your backup sites" %}</p>
|
||||
</div>
|
||||
|
||||
<div ng-controller="restorev2backupoage" class="panel">
|
||||
<div class="panel-body">
|
||||
<h3 class="title-hero">
|
||||
{% trans "Restore V2 Backups" %} <img ng-hide="backupLoading" src="{% static 'images/loading.gif' %}">
|
||||
{% trans "Restore V2 Backups" %} <img ng-hide="backupLoading"
|
||||
src="{% static 'images/loading.gif' %}">
|
||||
</h3>
|
||||
<div class="example-box-wrapper">
|
||||
|
||||
@@ -30,7 +35,8 @@
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">{% trans "Select Website" %} </label>
|
||||
<div class="col-sm-6">
|
||||
<select id="create-backup-select" ng-change="selectwebsite()" ng-model="selwebsite" class="form-control">
|
||||
<select id="create-backup-select" ng-change="selectwebsite()" ng-model="selwebsite"
|
||||
class="form-control">
|
||||
{% for items in websiteList %}
|
||||
<option value="{{ items }}">{{ items }}</option>
|
||||
{% endfor %}
|
||||
@@ -41,7 +47,8 @@
|
||||
<label class="col-sm-3 control-label">{% trans "Select Repo" %} </label>
|
||||
<div class="col-sm-6">
|
||||
|
||||
<select id="reposelectbox" ng-change="selectrepo()" ng-model="testhabbi" class="form-control">
|
||||
<select id="reposelectbox" ng-change="selectrepo()" ng-model="testhabbi"
|
||||
class="form-control">
|
||||
|
||||
</select>
|
||||
</div>
|
||||
@@ -50,7 +57,6 @@
|
||||
</form>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div ng-hide="runningSnapshot" class="form-group">
|
||||
@@ -59,7 +65,7 @@
|
||||
|
||||
<table id="snapshotstable" class="table">
|
||||
<thead>
|
||||
<tr style="border-bottom: #cccccc solid 1px!important;" >
|
||||
<tr style="border-bottom: #cccccc solid 1px!important;">
|
||||
<th style="border: none">{% trans "Snapshot ID" %}</th>
|
||||
<th style="border: none">{% trans "Time" %}</th>
|
||||
<th style="border: none">{% trans "Action" %} ></th>
|
||||
@@ -80,15 +86,19 @@
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal">×
|
||||
</button>
|
||||
<h4 id="restore_header_text" class="modal-title">{% trans "Restore" %} <img ng-hide="backupLoading" src="{% static 'images/loading.gif' %}"></h4>
|
||||
<h4 id="restore_header_text" class="modal-title">{% trans "Restore" %} <img
|
||||
ng-hide="backupLoading" src="{% static 'images/loading.gif' %}"></h4>
|
||||
</div>
|
||||
<div class="modal-body" style="">
|
||||
|
||||
<span style="font-weight: bolder">ID: <span style="font-weight: normal" id="Snapshot_id"></span></span><br>
|
||||
<span style="font-weight: bolder">PATH: <span style="font-weight: normal" id="Snapshot_Path_id"></span></span><br>
|
||||
<span style="font-weight: bolder">ID: <span style="font-weight: normal"
|
||||
id="Snapshot_id"></span></span><br>
|
||||
<span style="font-weight: bolder">PATH: <span style="font-weight: normal"
|
||||
id="Snapshot_Path_id"></span></span><br>
|
||||
<span style="display: flex;justify-content: center;margin-top: 20px;font-weight: bolder">{% trans "Are you ready to restore the backup? This may overwrite existing files." %} </span>
|
||||
<div style="display: flex;justify-content: center;margin-top: 10px;margin-bottom: 20px">
|
||||
<button type="button" class="btn btn-primary "style="margin-right: 20px!important;"
|
||||
<button type="button" class="btn btn-primary "
|
||||
style="margin-right: 20px!important;"
|
||||
ng-click="RestorePathV2()">Yes <img
|
||||
ng-hide="backupLoading"
|
||||
src="">
|
||||
@@ -104,12 +114,13 @@
|
||||
<div class="col-sm-12">
|
||||
|
||||
<div class="alert alert-success text-center">
|
||||
{# <h2>{$ currentStatus $}</h2>#}
|
||||
{# <h2>{$ currentStatus $}</h2>#}
|
||||
<h2 class="ng-binding">Successfully Restored</h2>
|
||||
</div>
|
||||
|
||||
<div class="progress">
|
||||
<div id="installProgress" class="progress-bar" role="progressbar" aria-valuenow="70"
|
||||
<div id="installProgress" class="progress-bar" role="progressbar"
|
||||
aria-valuenow="70"
|
||||
aria-valuemin="0" aria-valuemax="100" style="width:0%">
|
||||
<span class="sr-only">70% Complete</span>
|
||||
</div>
|
||||
@@ -158,6 +169,56 @@
|
||||
|
||||
|
||||
</div>
|
||||
{% else %}
|
||||
<style>
|
||||
.feturecard {
|
||||
width: 30%;
|
||||
padding: 46px;
|
||||
margin: 15px
|
||||
}
|
||||
</style>
|
||||
<div class="container">
|
||||
<div id="page-title" align="center">
|
||||
<h1 style="color: black"><strong>Backups v2 - Incremental Backups! </strong></h1>
|
||||
<p style="font-size: 15px; color: black; margin-top: 1%">Is your website's data protection strategy up
|
||||
to par? Are you tired of dealing with slow and unreliable backup solutions that don't offer the
|
||||
level of robustness you need? <br><br>
|
||||
|
||||
Introducing CyberPanel's latest feature, Backups v2! With Backups v2, you can ensure that your
|
||||
website's data is protected like never before. Our advanced incremental backup system utilizes
|
||||
rclone, a powerful backup tool that supports over 30+ backends, including popular cloud storage
|
||||
providers like Google Drive, Dropbox, Amazon S3, and more!<br><br>
|
||||
|
||||
Gone are the days of slow and cumbersome full backups. With Backups v2, you can take advantage of
|
||||
incremental backups that only capture changes to your data, making the process lightning-fast and
|
||||
highly efficient. This means you can save time and bandwidth while still maintaining the highest
|
||||
level of data integrity.<br><br>
|
||||
|
||||
Whether you have a small blog or a large e-commerce website, Backups v2 is tailored to meet your
|
||||
needs. With its robustness and versatility, you can have peace of mind knowing that your website's
|
||||
data is backed up securely and can be easily restored whenever you need it.
|
||||
<br></p>
|
||||
</div>
|
||||
<p align="center">
|
||||
<iframe width="788.54" height="443" src="https://www.youtube.com/watch?v=7dI1013xvUc"
|
||||
title="YouTube video player" frameborder="0"
|
||||
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
|
||||
allowfullscreen></iframe>
|
||||
</p>
|
||||
<div style="margin-top: 2%">
|
||||
<stripe-pricing-table pricing-table-id="prctbl_1MQtdYJMfY1fWGMszc4tx78j"
|
||||
publishable-key="pk_live_51ITXBmJMfY1fWGMs2G0LAydJweIDMp2WaYocM0xyzdn03WaHUbMw6uxfVuktAkgpRyUql7tz7gF5OwdccEZLd6Ot00XX6tGoZx">
|
||||
</stripe-pricing-table>
|
||||
<stripe-pricing-table pricing-table-id="prctbl_1LpSqSJMfY1fWGMsxSNhPLsc"
|
||||
publishable-key="pk_live_51ITXBmJMfY1fWGMs2G0LAydJweIDMp2WaYocM0xyzdn03WaHUbMw6uxfVuktAkgpRyUql7tz7gF5OwdccEZLd6Ot00XX6tGoZx">
|
||||
</stripe-pricing-table>
|
||||
<stripe-pricing-table pricing-table-id="prctbl_1M6WpCJMfY1fWGMsQXFlZWcW"
|
||||
publishable-key="pk_live_51ITXBmJMfY1fWGMs2G0LAydJweIDMp2WaYocM0xyzdn03WaHUbMw6uxfVuktAkgpRyUql7tz7gF5OwdccEZLd6Ot00XX6tGoZx">
|
||||
</stripe-pricing-table>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
|
||||
{% endblock %}
|
||||
@@ -11,6 +11,7 @@
|
||||
|
||||
</style>
|
||||
|
||||
{% if BackupStat %}
|
||||
<div class="container">
|
||||
<div id="page-title">
|
||||
<h2>{% trans "Schedule V2 Backup" %} - <a target="_blank" href="http://go.cyberpanel.net/backup"
|
||||
@@ -164,7 +165,8 @@
|
||||
<!-- Modal content-->
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal">×
|
||||
<button type="button" class="close" data-dismiss="modal">
|
||||
×
|
||||
</button>
|
||||
<h4 class="modal-title">{% trans "Set up account" %}</h4>
|
||||
</div>
|
||||
@@ -172,7 +174,8 @@
|
||||
|
||||
<form name="containerSettingsForm" action="/"
|
||||
class="form-horizontal">
|
||||
<div ng-hide="installationDetailsForm" class="form-group">
|
||||
<div ng-hide="installationDetailsForm"
|
||||
class="form-group">
|
||||
<label class="col-sm-3 control-label">{% trans "Are you sure?" %}</label>
|
||||
</div>
|
||||
|
||||
@@ -211,6 +214,56 @@
|
||||
|
||||
|
||||
</div>
|
||||
{% else %}
|
||||
<style>
|
||||
.feturecard {
|
||||
width: 30%;
|
||||
padding: 46px;
|
||||
margin: 15px
|
||||
}
|
||||
</style>
|
||||
<div class="container">
|
||||
<div id="page-title" align="center">
|
||||
<h1 style="color: black"><strong>Backups v2 - Incremental Backups! </strong></h1>
|
||||
<p style="font-size: 15px; color: black; margin-top: 1%">Is your website's data protection strategy up
|
||||
to par? Are you tired of dealing with slow and unreliable backup solutions that don't offer the
|
||||
level of robustness you need? <br><br>
|
||||
|
||||
Introducing CyberPanel's latest feature, Backups v2! With Backups v2, you can ensure that your
|
||||
website's data is protected like never before. Our advanced incremental backup system utilizes
|
||||
rclone, a powerful backup tool that supports over 30+ backends, including popular cloud storage
|
||||
providers like Google Drive, Dropbox, Amazon S3, and more!<br><br>
|
||||
|
||||
Gone are the days of slow and cumbersome full backups. With Backups v2, you can take advantage of
|
||||
incremental backups that only capture changes to your data, making the process lightning-fast and
|
||||
highly efficient. This means you can save time and bandwidth while still maintaining the highest
|
||||
level of data integrity.<br><br>
|
||||
|
||||
Whether you have a small blog or a large e-commerce website, Backups v2 is tailored to meet your
|
||||
needs. With its robustness and versatility, you can have peace of mind knowing that your website's
|
||||
data is backed up securely and can be easily restored whenever you need it.
|
||||
<br></p>
|
||||
</div>
|
||||
<p align="center">
|
||||
<iframe width="788.54" height="443" src="https://www.youtube.com/watch?v=7dI1013xvUc"
|
||||
title="YouTube video player" frameborder="0"
|
||||
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
|
||||
allowfullscreen></iframe>
|
||||
</p>
|
||||
<div style="margin-top: 2%">
|
||||
<stripe-pricing-table pricing-table-id="prctbl_1MQtdYJMfY1fWGMszc4tx78j"
|
||||
publishable-key="pk_live_51ITXBmJMfY1fWGMs2G0LAydJweIDMp2WaYocM0xyzdn03WaHUbMw6uxfVuktAkgpRyUql7tz7gF5OwdccEZLd6Ot00XX6tGoZx">
|
||||
</stripe-pricing-table>
|
||||
<stripe-pricing-table pricing-table-id="prctbl_1LpSqSJMfY1fWGMsxSNhPLsc"
|
||||
publishable-key="pk_live_51ITXBmJMfY1fWGMs2G0LAydJweIDMp2WaYocM0xyzdn03WaHUbMw6uxfVuktAkgpRyUql7tz7gF5OwdccEZLd6Ot00XX6tGoZx">
|
||||
</stripe-pricing-table>
|
||||
<stripe-pricing-table pricing-table-id="prctbl_1M6WpCJMfY1fWGMsQXFlZWcW"
|
||||
publishable-key="pk_live_51ITXBmJMfY1fWGMs2G0LAydJweIDMp2WaYocM0xyzdn03WaHUbMw6uxfVuktAkgpRyUql7tz7gF5OwdccEZLd6Ot00XX6tGoZx">
|
||||
</stripe-pricing-table>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
|
||||
{% endblock %}
|
||||
@@ -721,6 +721,13 @@ def ConfigureV2Backup(request):
|
||||
if ACLManager.currentContextPermission(current_acl, 'createBackup') == 0:
|
||||
return ACLManager.loadError()
|
||||
|
||||
data = {}
|
||||
|
||||
if ACLManager.CheckForPremFeature('all'):
|
||||
data['BackupStat'] = 1
|
||||
else:
|
||||
data['BackupStat'] = 0
|
||||
|
||||
websites = ACLManager.findAllSites(current_acl, user_id)
|
||||
#
|
||||
# destinations = _get_destinations(local=True)
|
||||
|
||||
@@ -65,9 +65,15 @@ class BackupManager:
|
||||
return proc.render()
|
||||
|
||||
def schedulev2Backups(self, request=None, userID=None, data=None):
|
||||
|
||||
if ACLManager.CheckForPremFeature('all'):
|
||||
BackupStat = 1
|
||||
else:
|
||||
BackupStat = 0
|
||||
|
||||
currentACL = ACLManager.loadedACL(userID)
|
||||
websitesName = ACLManager.findAllSites(currentACL, userID)
|
||||
proc = httpProc(request, 'IncBackups/ScheduleV2Backup.html', {'websiteList': websitesName}, 'createBackup')
|
||||
proc = httpProc(request, 'IncBackups/ScheduleV2Backup.html', {'websiteList': websitesName, "BackupStat": BackupStat}, 'createBackup')
|
||||
return proc.render()
|
||||
|
||||
def gDrive(self, request=None, userID=None, data=None):
|
||||
|
||||
@@ -1232,7 +1232,6 @@ team_drive =
|
||||
|
||||
return 1, None
|
||||
|
||||
|
||||
except BaseException as msg:
|
||||
print('Error: %s' % msg)
|
||||
return 0, str(msg)
|
||||
|
||||
@@ -436,7 +436,7 @@ class sslUtilities:
|
||||
subprocess.check_output(shlex.split(command))
|
||||
|
||||
try:
|
||||
command = acmePath + f" --issue -d *.{virtualHostName}" \
|
||||
command = acmePath + f" --issue -d {virtualHostName} -d *.{virtualHostName}" \
|
||||
+ ' --cert-file ' + existingCertPath + '/cert.pem' + ' --key-file ' + existingCertPath + '/privkey.pem' \
|
||||
+ ' --fullchain-file ' + existingCertPath + '/fullchain.pem' + f' --dns {DNS_TO_USE} -k ec-256 --force --server letsencrypt'
|
||||
#ResultText = open(logging.CyberCPLogFileWriter.fileName, 'r').read()
|
||||
|
||||
Reference in New Issue
Block a user