Content :
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 | |
# You need to uncomment two lines for the script work. | |
# Please check the logic before use it. | |
main () { | |
#aws s3 ls $BUCKETNAME | grep -v ' PRE ' | grep -v ' 0 ' > data.txt | |
UNIXDAYS=$(date -d "$DAYS days ago" +%s) | |
while read LINE | |
do |
Block or filter IPs based on location in Nginx (tested on 1.18.0) on Ubuntu 20.04.
To make use of the geographical filtering, we must first install the Nginx GeoIP module as well as the GeoIP database containing the mappings between visitors’ IP addresses and their respective countries. To do so, let’s execute:
$ sudo apt install libnginx-mod-http-geoip geoip-database
Old EBS volumes example:
growpart /dev/xvda 1
resize2fs /dev/xvda1
New NVME volumes example:
growpart /dev/nvme0n1 1
resize2fs /dev/nvme0n1p1
$i++;
$cfg['Servers'][$i]['verbose'] = 'Database Server 2';
$cfg['Servers'][$i]['host'] = '192.168.1.102';
$cfg['Servers'][$i]['port'] = '';
$cfg['Servers'][$i]['socket'] = '';
$cfg['Servers'][$i]['connect_type'] = 'tcp';
$cfg['Servers'][$i]['extension'] = 'mysqli';
$cfg['Servers'][$i]['auth_type'] = 'cookie';
$cfg['Servers'][$i]['AllowNoPassword'] = false;
NewerOlder