Commit 33f5e67a authored by Dermot Bradley's avatar Dermot Bradley Committed by Leo
Browse files

testing/cloud-init: remove post-install script

Replace actions of package post-install script with a setup-cloud-init
script and update README.Alpine accordingly.
parent 3c4b9dca
......@@ -3,7 +3,7 @@
# Maintainer: Dermot Bradley <dermot_bradley@yahoo.com>
pkgname=cloud-init
pkgver=20.3
pkgrel=1
pkgrel=2
pkgdesc="Cloud instance init scripts"
url="https://cloud-init.io"
# Dependant package "cloud-utils-growpart" is not available for mips,
......@@ -36,9 +36,9 @@ subpackages="$pkgname-doc $pkgname-bash-completion $pkgname-openrc"
source="cloud-init-$pkgver.tar.gz::https://github.com/canonical/cloud-init/archive/$pkgver.tar.gz
01-remove-debug-line.patch
interfaces
setup-cloud-init
README.Alpine
"
install="$pkgname-openrc.post-install"
prepare() {
default_prepare
......@@ -57,7 +57,7 @@ package() {
--prefix=/usr --root="$pkgdir" --init-system=sysvinit_openrc
# Delete __pycache__ directories containing PYC files
find $pkgdir -name '__pycache__' -type d | xargs rm -Rf
find $pkgdir -name '__pycache__' -type d -print0 | xargs rm -Rf
mkdir -p \
"$pkgdir"/etc/network
......@@ -65,6 +65,12 @@ package() {
"$srcdir"/interfaces \
"$pkgdir"/etc/network/
mkdir -p \
"$pkgdir"/sbin
install -m755 \
"$srcdir"/setup-cloud-init \
"$pkgdir"/sbin/
# Delete non-Alpine distribution template files
for distro in \
debian fedora freebsd opensuse redhat rhel sles suse ubuntu
......@@ -93,4 +99,5 @@ doc() {
sha512sums="10008710f1876538dab445b07e768953adf8ee31c8848bdf4c95201d6bc894b15ed042e7c90b2cf59491c9dc4b163f64d2be275fbd954f52cb6e4bf37b8e227b cloud-init-20.3.tar.gz
6f0e5c93c3136e3b06f6cfe71bb3160a800a681fa7ebb9aaf551b33fcfb5ac25cf24588c147e1d99e9b361482a8e6cedf4ff3a91d5b6b52e160c456a7033a77a 01-remove-debug-line.patch
48b25ec4457c2b3772a7d210033551d041749a0d1869818d888030e6df7fd9bbc13a38b95cf465de3d46d96881a722f94a337584ce48f280c4a52b819586563a interfaces
14a5f93b320b97aec8da6c043c07926b4a5591f6ad887e41e70de8aee732ae03914851af1e141ec958e15ece6ad1f7afb44646aafc505b94a29fd291b6d54083 README.Alpine"
f32b90f26d1df0d88fbea7a1a9ab6704a20babdb750b933484bb7c4e91cc19a587d4bfbc95489a354003ecd00795d1592e71b4b93eccd41e392bb7170bfebb0e setup-cloud-init
3cfba05374bc13eb83c8cec03ae91e0bd0093643e5d9b66f12fb1d9dfd7a097534f989d7f6b1d42cf0acca5352f34b31271eeb63c265ea8e5f763c4bb7e85d32 README.Alpine"
When the cloud-init package is installed it will enable its init.d services
so that they are run upon future boots/reboots. It also enables eudev's
init.d services as udev is used by cloud-init for both disk configuration and
network card persistent naming.
After the cloud-init package is installed you will need to run the
"setup-cloud-init" command to prepare the OS for cloud-init use.
This command will enable cloud-init's init.d services so that they are run
upon future boots/reboots. It also enables eudev's init.d services as udev is
used by cloud-init for both disk configuration and network card persistent
naming.
NTP
......
#!/bin/sh
echo "Enabling cloud-init's boot services..."
for i in boot/cloud-init-local \
default/cloud-config \
default/cloud-final \
......@@ -10,6 +11,7 @@ for i in boot/cloud-init-local \
done
# Cloud-init requires udev so enable it also
echo "Enabling udev's boot services (and disabling mdev if currently enabled)..."
setup-udev -n
exit 0
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment