32 lines
796 B
Text
32 lines
796 B
Text
#cloud-config
|
|
#apt_update: false
|
|
#apt_upgrade: true
|
|
#packages: [ bzr, pastebinit, ubuntu-dev-tools, ccache, bzr-builddeb, vim-nox, git-core, lftp ]
|
|
|
|
apt_sources:
|
|
- source: ppa:smoser/ppa
|
|
|
|
disable_root: True
|
|
|
|
mounts:
|
|
- [ ephemeral0, None ]
|
|
- [ swap, None ]
|
|
|
|
ssh_import_id: [smoser ]
|
|
|
|
sm_misc:
|
|
- &user_setup |
|
|
set -x; exec > ~/user_setup.log 2>&1
|
|
echo "starting at $(date -R)"
|
|
echo "set -o vi" >> ~/.bashrc
|
|
cat >> ~/.profile <<EOF
|
|
export EDITOR=vi
|
|
EOF
|
|
|
|
runcmd:
|
|
- [ sudo, -Hu, ubuntu, sh, -c, 'grep "cloud-init.*running" /var/log/cloud-init.log > ~/runcmd.log' ]
|
|
- [ sudo, -Hu, ubuntu, sh, -c, 'read up sleep < /proc/uptime; echo $(date): runcmd up at $up | tee -a ~/runcmd.log' ]
|
|
- [ sudo, -Hu, ubuntu, sh, -c, *user_setup ]
|
|
|
|
password: passw0rd
|
|
chpasswd: { expire: False }
|