livecd-rootfs/live-build/ubuntu-core/hooks/08-etc-writable.chroot
Michael Vogt cf6d153711 Import patches-unapplied version 2.259 to ubuntu/vivid-proposed
Imported using git-ubuntu import.

Changelog parent: 6c4b5a72d494663e427cd8e0eefebd3c1b3489f5

New changelog entries:
  * merge ubuntu-core system-image fixes from the PPA:
    - add ubuntu-core-libs
    - add packages not (yet) in the ubuntu-core seed
    - fix resolv.conf
    - make timezone, localtime and hostname writable for cloud-init
2014-10-29 10:18:29 +00:00

16 lines
381 B
Bash

#!/bin/sh
set -e
mkdir -p /etc/writable
# cloud-init needs to be able to modify hostname and has the ability to
# set the other two.
for f in timezone localtime hostname; do
if [ -e /etc/$f ]; then
echo "I: Moving /etc/$f to /etc/writable/"
mv /etc/$f /etc/writable/$f
fi
echo "I: Linking /etc/$f to /etc/writable/"
ln -s writable/$f /etc/$f
done