Table of content
This file contains hidden or 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
location ~ ^/.* { | |
include proxy_params; | |
sub_filter 'transfer.sh' 'domaine.tld'; | |
sub_filter 'transfer.sh' 'domaine.tld'; | |
sub_filter_once off; | |
proxy_pass http://127.0.0.1:8080; | |
} |
This file contains hidden or 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
// custom admin login logo | |
function custom_login_logo() { | |
echo '<style type="text/css"> | |
h1 a { background-image: url(' . get_stylesheet_directory_uri() . '/images/logo.png) !important; } | |
</style>'; | |
} | |
add_action('login_head', 'custom_login_logo'); |
Install cht.sh
bash <(wget -qO - https://gist.githubusercontent.com/VirtuBox/af97c7076173b9b145b09882e721a9d7/raw/ccb006f36cf9101025c79696610ba51db3328db6/cheat-install.sh )
This file contains hidden or 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
transfer() { | |
curl --progress-bar --upload-file $1 https://transfer.vtbox.net/$(basename $1) | tee /dev/null; | |
} | |
alias transfer=transfer |
This file contains hidden or 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
proxy_cache_path /var/cache/nginx levels=1:2 keys_zone=STATIC:75m inactive=24h max_size=8096m; | |
server { | |
server_name cdn.yourdomain.tld yourdomain.tld www.yourdomain.tld; | |
listen 443 ssl http2; | |
listen [::]:443 ssl http2; | |
ssl on; | |
ssl_certificate //path/to/ssl/yourdomain.tld/fullchain.pem; | |
ssl_certificate_key //path/to/ssl/yourdomain.tld/key.pem; |
This file contains hidden or 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 | |
echo "edit the variable innodb_log_file_size in /etc/mysql/my.cnf before launching this script" | |
echo "do you want to launch the script ? [y/n]" | |
read -r start | |
if [ "$start" = "n" ]; then | |
exit 1 | |
elif [[ "$start" = "y" ]]; then |
This file contains hidden or 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 | |
git clone https://github.com/fail2ban/fail2ban.git | |
cd fail2ban | |
sudo python setup.py install | |
cp build/fail2ban.service /lib/systemd/system/fail2ban.service -f | |
systemctl daemon-reload | |
service fail2ban restart |