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 | |
/** | |
* Wordpress remote update checker | |
* Written by Tomasz Klim, based on wp-admin code | |
** | |
<Files wp-fetch-updates-info.php> | |
Order Deny,Allow | |
Deny from all | |
Allow from 1.2.3.4 |
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/sh | |
# warning: this installs old 17.05.0-ce version, see my install-docker-ubuntu18.sh gist for the current version | |
echo "deb https://apt.dockerproject.org/repo ubuntu-xenial main" >/etc/apt/sources.list.d/docker.list | |
apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D | |
apt-get update | |
apt-get install docker-engine python-pip |
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/sh | |
docker rmi $(docker images | grep "^<none>" | awk '{print $3}') |
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/sh | |
add-apt-repository ppa:certbot/certbot | |
apt-get update | |
apt-get install nginx python-certbot-nginx |
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 | |
api_key="u123456-qa9oic80zsll1xi0fhbwso1" | |
alert_contacts="0123456_0_0-2761234_0_0" | |
baseurl="https://serverfarmer.home.pl/heartbeat/query.php" | |
db="id_myaccount.txt" | |
# 300 for free accounts, 60 for paid accounts | |
interval=300 |
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/sh | |
api="u123456-qa9oic80zsll1xi0fhbwso1" | |
offset=$1 | |
if [ "$offset" = "" ]; then | |
offset=0 | |
fi | |
curl -s -X POST \ |
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/sh | |
git clone https://github.com/CISOfy/lynis /opt/lynis | |
cd /opt/lynis && /opt/lynis/lynis audit system --cronjob --quiet |grep -v custom.prf | |
grep warning /var/log/lynis-report.dat |egrep -v "(CONT-8104|KRNL-5830|NETW-2705)" |
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/sh | |
apt install apt-transport-https ca-certificates curl software-properties-common | |
echo "deb [arch=amd64] https://download.docker.com/linux/ubuntu bionic stable" >/etc/apt/sources.list.d/docker.list | |
curl -fsSL https://download.docker.com/linux/ubuntu/gpg |apt-key add - | |
apt update | |
apt install docker-ce python-pip |
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/sh | |
# Written by Tomasz Klim, 2019-07-05 | |
# | |
# This is a simplified, open source version. It relies on $MAILTO variable | |
# defined in /etc/crontab file for all cron tasks. A better approach would | |
# be to send emails in dedicated format, to dedicated list of recipients. | |
# | |
# Add this to /etc/crontab: | |
# * * * * * root /etc/local/docker-logtail.sh |
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/sh | |
# Espeo Software server analysis script | |
# Written by Tomasz Klim | |
# Version 1.2 | |
# | |
# Run this script as root and send us the created TGZ package. | |
WD=`pwd` | |
path=$WD/analysis | |
mkdir -p $path/etc $path/log $path/ls $path/proc |
OlderNewer