feat: status page + maintenance
This commit is contained in:
parent
02645b7ef7
commit
f3d697699d
2
maintenance/scripts/jquery-3.7.0.min.js
vendored
Normal file
2
maintenance/scripts/jquery-3.7.0.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
@ -1,18 +1,6 @@
|
|||||||
function reboot() {
|
$("reboot").click(function(){
|
||||||
console.log("Vroom...");
|
$.get("https://www.thsf.net/thsf.net/maintenance/reboot.py", function(data, status){
|
||||||
var xhttp = new XMLHttpRequest();
|
document.getElementById("logs").innerHTML = data;
|
||||||
console.log("Vroop...");
|
setTimeout(function () {document.location.reload()}, 5000);
|
||||||
xhttp.onreadystatechange = function() {
|
});
|
||||||
if (this.readyState == 4 && this.status == 200) {
|
});
|
||||||
console.log("Houba");
|
|
||||||
document.getElementById("logs").innerHTML = this.responseText;
|
|
||||||
console.log("Hop");
|
|
||||||
setTimeout(function () {location.reload()}, 5000);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
console.log("Ready");
|
|
||||||
xhttp.open("GET", "https://www.thsf.net/thsf.net/maintenance/reboot.py", true);
|
|
||||||
console.log("Go");
|
|
||||||
xhttp.send();
|
|
||||||
console.log("Gone !");
|
|
||||||
}
|
|
||||||
|
@ -55,7 +55,7 @@
|
|||||||
}
|
}
|
||||||
.container_log {
|
.container_log {
|
||||||
text-align: left;
|
text-align: left;
|
||||||
width: 48.4em;
|
width: 48.6em;
|
||||||
padding: 0.2em;
|
padding: 0.2em;
|
||||||
border-width: 1px;
|
border-width: 1px;
|
||||||
border-style: solid;
|
border-style: solid;
|
||||||
|
@ -11,6 +11,7 @@ Content-type: text/html
|
|||||||
href="/thsf.net/maintenance/style/maintenance.css">
|
href="/thsf.net/maintenance/style/maintenance.css">
|
||||||
<link rel="stylesheet"
|
<link rel="stylesheet"
|
||||||
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
|
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
|
||||||
|
<script src="/thsf.net/maintenance/scripts/jquery-3.7.0.min.js"></script>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div class="page_wrapper">
|
<div class="page_wrapper">
|
||||||
@ -30,7 +31,7 @@ Content-type: text/html
|
|||||||
<div class="status">{{ container.name }}</div>
|
<div class="status">{{ container.name }}</div>
|
||||||
<div class="status">{{ container.status }}</div>
|
<div class="status">{{ container.status }}</div>
|
||||||
<div class="status">
|
<div class="status">
|
||||||
<i class="button fa-regular fa-recycle" onclick="reboot()"></i>
|
<i id="reboot" class="button fa-regular fa-recycle" onclick="reboot()"></i>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="container_log" id="logs">
|
<div class="container_log" id="logs">
|
||||||
|
Loading…
Reference in New Issue
Block a user