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 your browser downloads the file instead of displaying it? | |
sudo apt-get install libapache2-mod-php5 -y | |
After that enable php for apache | |
a2enmod php5 | |
Restart server | |
sudo service apache2 restart |
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
2.2 configuration: | |
Order deny,allow | |
Deny from all | |
2.4 configuration: | |
Require all denied | |
In this example, all requests are allowed. |
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
From remote to local | |
scp -i '/PATH/TO/YOURPEM.pem' -r USER@PUBLIC_IP:/SPECIFY/PATH/*.ini /PATH/TO/FILES/ | |
From local to remote | |
scp -i '/PATH/TO/YOURPEM.pem' PATH/TO/FILE/YOU/WANT/TO/COPY/* USER@PUBLIC_IP: |
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
memcached -d -m 2048 -M -p 11211 |
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
array.uniq.map { | e | [array.count(e), e] }.select { | c, _ | c > 1 }.sort.reverse.map { | c, e | "#{e}:#{c}" } |
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
script > script_output.txt 2>&1 |
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 tcpdump -A -s0 -ien4 port 3306 |
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
Compile | |
javac -cp json-20131018.jar Forecast.java | |
Execute | |
java -cp json-20131018.jar: Forecast |
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
SSLProtocol -SSLv3 |
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
nc IP-ADDRESS PORT < /dev/null; echo $? |
OlderNewer