Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Startup script for pseq-instance on GCE
# Key off existence of the "data" mount point to determine whether
# this is the first boot.
if [[ ! -e /mnt/data ]]; then
# Basic setup - get the JRE installed
apt-get update
apt-get install --fix-broken
mkdir -p /mnt/data
# Get the device name of the "data" disk
DISK_DEV=$(basename $(readlink /dev/disk/by-id/google-pseq))
# Mount the data disk
/usr/share/google/safe_format_and_mount \
-m "mkfs.ext4 -F" /dev/$DISK_DEV /mnt/data
chmod 777 /mnt/data
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment