This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
header("Cache-Control: no-cache, must-revalidate"); | |
header("Expires: Sat, 26 Jul 1997 05:00:00 GMT"); | |
header("Pragma: no-cache"); | |
function human_filesize($bytes, $decimals = 2) { | |
$sz = 'BKMGTP'; | |
$factor = floor((strlen($bytes) - 1) / 3); | |
return sprintf("%.{$decimals}f", $bytes / pow(1024, $factor)) . @$sz[$factor]; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# | |
This license governs use of the accompanying software. If you use the software, you | |
accept this license. If you do not accept the license, do not use the software. | |
1. Definitions | |
The terms "reproduce," "reproduction," "derivative works," and "distribution" have the | |
same meaning here as under U.S. copyright law. | |
A "contribution" is the original software, or any additions or changes to the software. | |
A "contributor" is any person that distributes its contribution under this license. | |
"Licensed patents" are a contributor's patent claims that read directly on its contribution. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# Original Source Attribution: | |
# Location: https://gist.github.com/SandroMachado/87e591fc42f368636b251b566485ae46 | |
# Author: Sandro Machado | |
# Date of retrieval: 2020-01-25 | |
# | |
# Script Summary: | |
# This script checks a pingable source and when the failure | |
# limit is reached the host is restarted. No files are written |