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
sudo apt update | |
sudo apt install redis-server -y | |
sudo nano /etc/redis/redis.conf | |
supervised no -> systemd | |
sudo systemctl restart redis.service | |
sudo nano /etc/redis/redis.conf | |
# SECURITY # |
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
sudo apt update | |
sudo apt install dirmngr gnupg apt-transport-https ca-certificates software-properties-common | |
wget -qO - https://www.mongodb.org/static/pgp/server-4.4.asc | sudo apt-key add - | |
echo "deb [ arch=amd64,arm64 ] https://repo.mongodb.org/apt/ubuntu bionic/mongodb-org/4.4 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-4.4.list | |
sudo apt-get update | |
sudo apt-get install -y mongodb-org |
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
wget -O YANDEX-DISK-KEY.GPG http://repo.yandex.ru/yandex-disk/YANDEX-DISK-KEY.GPG | |
apt-key add YANDEX-DISK-KEY.GPG | |
echo "deb http://repo.yandex.ru/yandex-disk/deb/ stable main" >> /etc/apt/sources.list.d/yandex-disk.list | |
apt-get update | |
apt-get install yandex-disk | |
yandex-disk setup |
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
sudo timedatectl set-timezone Europe/Istanbul | |
sudo locale-gen tr_TR.UTF-8 | |
sudo update-locale |
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
sudo apt install postgresql postgresql-contrib -y | |
sudo -u postgres psql | |
postgres=# ALTER USER postgres PASSWORD 'pass'; | |
postgres=# \q | |
sudo nano /etc/postgresql/10/main/postgresql.conf | |
listen_addresses = '*' |
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
#terminal | |
sudo apt update | |
sudo apt install locale -y | |
sudo locale-gen tr_TR.UTF-8 | |
sudo update-locale | |
#dockerfile | |
FROM postgres:10 | |
RUN localedef -i tr_TR -c -f UTF-8 -A /usr/share/locale/locale.alias tr_TR.UTF-8 | |
ENV LANG tr_TR.UTF-8 |
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
if [[ -n $SSH_CONNECTION ]] ; then | |
echo "Merhaba Emre. Ip adresin:" | |
echo "${SSH_CLIENT%% *}" | |
echo "eski kurallar siliniyor" | |
for i in $(ufw status numbered | grep 27017 | awk -F"[][]" '{print $2}' | tr --delete [:blank:] | sort -rn); do | |
yes | ufw delete $i | |
echo "27017 silindi" | |
done | |
for i in $(ufw status numbered | grep 5432 | awk -F"[][]" '{print $2}' | tr --delete [:blank:] | sort -rn); do |
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
0 9 * * * sudo curl --silent http://localhost:5000/api/degree/dailyjob?key=xxxxxxxxxx 2>&1 | /usr/bin/logger -t DEGREEDAYS |
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
0 8 * * * sudo pg_dump --blobs -Fc --no-owner --dbname=postgresql://backuper:backup_user@localhost:5432/db_name | gzip > /root/Yandex.Disk/Postgres/`date '+\%m-\%d-\%Y'`.gzip |
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
set servers to {"192.168.10.1", "192.168.10.2", "192.168.10.3", "192.168.10.4"} | |
set server to choose from list servers with prompt "Sunucu seç:" default items {"192.168.10.1"} | |
tell application "Terminal" | |
set currentTab to do script ("ssh root@" & server) | |
delay 3 | |
end tell |
NewerOlder