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
Command line tool for interacting with Google Compute Engine. | |
Please refer to http://developers.google.com/compute/docs/gcutil/tips for more | |
information about gcutil usage. | |
USAGE: gcutil [--global_flags] <command> [--command_flags] [args] | |
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
Command line tool for interacting with Google Compute Engine. | |
Please refer to http://developers.google.com/compute/docs/gcutil/tips for more | |
information about gcutil usage. | |
USAGE: gcutil [--global_flags] <command> [--command_flags] [args] | |
Any of the following commands: |
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
Available commands (grouped by type): | |
Base images: | |
create_base_image | |
delete_base_image | |
desc_base_images | |
Bundles: | |
add_content_to_bundle | |
create_bundle | |
delete_bundle | |
delete_content_from_bundle |
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-get install -y open-vm-tools | |
vmware-toolbox-cmd timesync enable |
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 | |
command -v openvpn >/dev/null 2>&1 || { echo "OpenVPN should be installed first. Aborting." >&2; exit 1; } | |
command -v curl >/dev/null 2>&1 || { echo "This script requires curl, but it's not installed. Aborting." >&2; exit 1; } | |
MGRIP=10.0.0.10 | |
APIPW=pa55Word | |
NAME=$1 | |
if [ -e /etc/openvpn/clientpack.ip ]; then | |
echo "VNS3 Clientpack already installed" | |
else | |
CLIENTPACKJSON=`curl -k -X POST -u api:$APIPW -H 'Content-Type: application/json' https://$MGRIP:8000/api/clientpacks/next_available` |
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 | |
VERBOSITY=0 | |
TEMP_D="" | |
DEF_DISK_FORMAT="raw" | |
DEF_FILESYSTEM="iso9660" | |
error() { echo "$@" 1>&2; } | |
errorp() { printf "$@" 1>&2; } | |
fail() { [ $# -eq 0 ] || error "$@"; exit 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
shell -$SHELL |
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
ping www.google.com.tw | |
sudo ping www.google.com.tw | |
sudo apt-get update | |
df | |
cd Desktop/ | |
ls | |
tar -zxvf ASUSTinkerBoard.gpio-0.1_20161025.tar.gz | |
cd ASUSTinkerBoard.gpio-0.1_20161025/ | |
ls | |
cd .. |
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 | |
# Set credentials and address for VNS3 manager | |
VNS3_PW=pa55Word | |
VNS3_IP=10.11.22.33 | |
# Use IPsec connection 2 | |
VNS3_EP=2 | |
# Clear out any existing IPsec tunnels | |
while true; do | |
TUNNEL=$(curl -s -k -X GET -u api:"$VNS3_PW" \ | |
https://"$VNS3_IP":8000/api/ipsec | python -mjson.tool \ |
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 mkdir /etc/systemd/system/docker.service.d | |
sudo bash -c 'cat <<EOF > /etc/systemd/system/docker.service.d/overlay.conf | |
[Service] | |
ExecStart= | |
ExecStart=/usr/bin/docker daemon -H fd:// --storage-driver=overlay | |
EOF' | |
sudo systemctl daemon-reload | |
sudo systemctl restart docker |