# Contributor: Matt Dainty # Maintainer: pkgname=cloud-init pkgver=18.3 pkgrel=0 pkgdesc="Cloud instance init scripts" url="https://cloud-init.io" arch="noarch" license="Apache-2.0 GPL-3.0-only" depends="e2fsprogs-extra python3 py3-configobj py3-jinja2 py3-jsonpatch py3-jsonschema py3-oauthlib py3-requests py3-serial py3-six py3-yaml" makedepends="py3-setuptools" subpackages="$pkgname-doc $pkgname-bash-completion:bashcomp:noarch $pkgname-openrc" source="https://launchpad.net/cloud-init/trunk/18.3/+download/$pkgname-$pkgver.tar.gz add_distro-alpine.patch cloud.cfg hosts.alpine.tmpl alpine.py " builddir="$srcdir"/$pkgname-$pkgver prepare() { cd "$builddir" default_prepare install -m644 "$srcdir"/alpine.py \ "$builddir"/cloudinit/distros/ } build() { cd "$builddir" python3 setup.py build } check() { cd "$builddir" python3 setup.py check } package() { cd "$builddir" python3 setup.py install --prefix=/usr --root="$pkgdir" --init-system=sysvinit_openrc install -m644 "$srcdir"/cloud.cfg \ "$pkgdir"/etc/cloud/ install -m644 "$srcdir"/hosts.alpine.tmpl \ "$pkgdir"/etc/cloud/templates/ } bashcomp() { depends="bash" pkgdesc="Bash completions for $pkgname" install_if="$pkgname=$pkgver-r$pkgrel bash-completion" cd "$builddir" mkdir -p "$subpkgdir"/usr/share/bash-completion/completions cp bash_completion/$pkgname "$subpkgdir"/usr/share/bash-completion/completions/$pkgname } sha512sums="e066c48f74ed21d4bd673dbeb17fabbacc107369c5c10e656b166257313f50cf9ab6af5ec69f2e8cc2abf22261c4fa86ca88e41c98c66985439f9af144d7c8cc cloud-init-18.3.tar.gz 4ab37323e7662445af90ce2654199fe3080e256571e8e12b121ebde791b98e68d368b10c5f22b7e8840c0ba9593dd0a6e37ec60724cd0ae4c806944a826741e3 add_distro-alpine.patch 7dd8c3a2050af5536154e77cc3913d34b7d85d02130ea9b9f5b54710f96cd22cb4c255af34f3c710a1319f9bd0f667441482695e9bad927026f952d0cf39de41 cloud.cfg 813a67d446ee65f5ef5a45fe60bef4d0e404c5d1f9cb732bc0ec0b706a0274f4bc1e7f87e676da1ca9366c2f933163f620ee296ed783372869438dd8a928117b hosts.alpine.tmpl 301e99d25cbe3607f6187ef477e15c8ffc356456117fcd662528194d880a989ba79622208eb84c27decf19060c3810c9ff11441d041c2061feced823e453acaf alpine.py"