This file contains hidden or 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
# install wordpress and requirements | |
sudo apg-get install wordpress mysql-server apache2 php5 libapache2-mod-php5 | |
# set wordpress folder to www root | |
# * in other way, setting wordpress folder to DocumentRoot in /etc/apache2/sites-enabled/000-default, it is the same effect as above commands. | |
sudo rm -fr /var/www | |
sudo ln -s /usr/share/wordpress /var/www | |
sudo chown www-data:www-data /usr/share/wordpress/ -R | |
# configuration wordpress and mysql |
This file contains hidden or 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
awk 'NR>1 {print $1}' file |
This file contains hidden or 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
cat hoge.txt | while read line | |
do | |
echo $line | |
done | |
whle read line | |
do | |
echo $line | |
done < hoge.txt |
This file contains hidden or 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 su -s /bin/bash - git |
This file contains hidden or 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
import string | |
import random | |
length = 10 | |
print ''.join([random.choice(string.ascii_letters + string.digits) for i in range(length)]) |
This file contains hidden or 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-get install qemu-utils | |
sudo modprobe nbd | |
sudo qemu-nbd --connect=/dev/nbd0 /full/path/to/qcow2/image/file | |
sudo mkdir /mnt/ubuntu | |
sudo mount /dev/nbd0p1 /mnt/ubuntu |
This file contains hidden or 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
"d:\Program Files (x86)\Unity\Editor\Unity.exe" -batchmode -executeMethod UnityTest.Batch.RunUnitTests -projectPath "D:\workspaces\Unity\Template" -logFile .\unittest.log -resultFilePath=D:\workspaces\Unity\Template |
This file contains hidden or 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
VPNCMD="sudo /usr/local/vpnserver/vpncmd localhost:443 /SERVER /CMD" | |
# Create virtual hub | |
${VPNCMD} HubCreate ${HubName} /PASSWD:admin | |
# Create local bridge(connect to physical device) | |
${VPNCMD} BridgeCreate ${HubName} /DEVICE:${phy_dev_name:-eth0} | |
# Create local bridge(create tap interface) |
This file contains hidden or 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 | |
# chkconfig: 2345 99 01 | |
# description: SoftEther VPN Server | |
DAEMON=/usr/local/vpnbridge/vpnbridge | |
LOCK=/var/lock/subsys/vpnbridge | |
test -x $DAEMON || exit 0 | |
case "$1" in | |
start) | |
$DAEMON start | |
touch $LOCK |
This file contains hidden or 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
dd if=/dev/cdrom of=~/foo.iso |