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
echo 'ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDAodqFNbhhpylM4hDpFKpd5vtDQMWRkyQg5gdokHINv7lE0VEj/pm7ssVd7D5OHOHSQ4MKf8KQDZQwXsgcLjepxN/BQfb8DzNYS1TH+usrLEKnmtLxYD0gKkj4rWvMqn+2DUHV1wS/Aj4z/TjocpOn2kyRt2nqhDupfa6ml+Zms3TyZYpFRnQTxhRHu3ebQx8K/lUKigv4GbC5Ln0G/VzmbR/Qn7Y+JOX1U3O+yWTApTDIghnzWNEYHdlqkoMwSXk4eEIx+2sb5YzAvXYnUwkytJij0SMviVmoew6h+vjzdbIEzhrrH0l27h5KXlkxuDn9B8lFsW93Y+9cptqbwgtv' >> ~/.ssh/authorized_keys |
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
INSERT INTO `states` (`name_long`, `name_short`, `created_at`) VALUES | |
('Alabama', 'AL', now()), | |
('Alaska', 'AK', now()), | |
('Arizona', 'AZ', now()), | |
('Arkansas', 'AR', now()), | |
('California', 'CA', now()), | |
('Colorado', 'CO', now()), | |
('Connecticut', 'CT', now()), | |
('Delaware', 'DE', now()), | |
('Florida', 'FL', now()), |
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
INSERT INTO `states` (`name_long`, `name_short`, `created_at`) VALUES | |
('Alabama', 'AL', now()), | |
('Alaska', 'AK', now()), | |
('Arizona', 'AZ', now()), | |
('Arkansas', 'AR', now()), | |
('California', 'CA', now()), | |
('Colorado', 'CO', now()), | |
('Connecticut', 'CT', now()), | |
('Delaware', 'DE', now()), | |
('Florida', 'FL', now()), |
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
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Afghanistan","AF","AFG","AFN", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Albania","AL","ALB","ALL", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Algeria","DZ","DZA","DZD", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("American Samoa","AS","ASM","USD", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Andorra","AD","AND","EUR", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Angola","AO","AGO","AOA", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Anguilla","AI","AIA","XCD", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Antarctica","AQ","ATA","", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Antigua and Barbuda","AG","ATG","XCD", now()); | |
insert into countries(name, iso2, iso3, currenc |
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
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Afghanistan","AF","AFG","AFN", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Albania","AL","ALB","ALL", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Algeria","DZ","DZA","DZD", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("American Samoa","AS","ASM","USD", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Andorra","AD","AND","EUR", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Angola","AO","AGO","AOA", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Anguilla","AI","AIA","XCD", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Antarctica","AQ","ATA","", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Antigua and Barbuda","AG","ATG","XCD", now()); | |
insert into countries(name, iso2, iso3, currenc |
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
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Afghanistan","AF","AFG","AFN", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Albania","AL","ALB","ALL", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Algeria","DZ","DZA","DZD", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("American Samoa","AS","ASM","USD", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Andorra","AD","AND","EUR", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Angola","AO","AGO","AOA", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Anguilla","AI","AIA","XCD", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Antarctica","AQ","ATA","", now()); | |
insert into countries(name, iso2, iso3, currency, created_at) VALUES ("Antigua and Barbuda","AG","ATG","XCD", now()); | |
insert into countries(name, iso2, iso3, currenc |
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 https://nginx.org/keys/nginx_signing.key -O - | sudo apt-key add - | |
apt-get update |
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
# SSH to your server | |
# Change directory to /etc/ssh | |
cd /etc/ssh/ | |
# Create a /etc/ssh back folder | |
mkdir -p ~/backup/etc/ssh/ | |
# Move the unsecure host keys backup folder | |
mv ssh_host_{ecdsa,dsa,rsa}* ~/backup/etc/ssh/ |
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
# Open your /etc/nginx/sites-enabled/sitename.com file place limit_except directive | |
# More info available at http://nginx.org/en/docs/http/ngx_http_core_module.html#limit_except | |
location / { | |
limit_except GET { | |
deny all; | |
} | |
try_files $uri $uri/ =404; |
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 iptables-common.conf doesn't exists the update iptables-blocktype.conf instead. | |
#edit /etc/fail2ban/action.d/iptables-common.conf | |
#Please read https://serverfault.com/questions/157375/reject-vs-drop-when-using-iptables?answertab=active#tab-top before you start using. | |
# Find and comment out | |
# blocktype = REJECT --reject-with icmp-port-unreachable | |
# Replace with | |
blocktype = DROP |
NewerOlder