aboutsummaryrefslogtreecommitdiffstats
path: root/testing/ansible/APKBUILD
blob: ae9d30712840b365be9701017feac85d834ff1ef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# Contributor: Fabian Affolter <fabian@affolter-engineering.ch>
# Maintainer: Fabian Affolter <fabian@affolter-engineering.ch>
pkgname=ansible
pkgver=0.9
pkgrel=0
pkgdesc="A configuration-management, deployment, task-execution, and multinode orchestration framework"
url="http://ansible.github.com/"
arch="noarch"
license="GPL3+"
depends="python py-yaml py-paramiko py-jinja2"
depends_dev=""
makedepends="python-dev"
install=""
subpackages="$pkgname-doc"
source="https://github.com/downloads/$pkgname/$pkgname/$pkgname-$pkgver.tar.gz"
_builddir="$srcdir"/$pkgname-$pkgver

prepare() {
	local i
	cd "$_builddir"
	for i in $source; do
		case $i in
		*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
		esac
	done
}

build() {
	cd "$_builddir"
	python setup.py build || return 1
}

package() {
	cd "$_builddir"
	python setup.py install --prefix=/usr --root="$pkgdir" || return 1
	mkdir -p "$pkgdir"/etc/$pkgname
	install -m755 -D "$_builddir"/examples/hosts \
		"$pkgdir"/etc/$pkgname/hosts || return 1
	mkdir -p "$pkgdir"/usr/share/$pkgname
	install -m755 -D "$_builddir"/library/* \
		"$pkgdir"/usr/share/$pkgname/ || return 1

    _manpages="$pkgname-playbook.1 $pkgname.1"
    for _manpage in $_manpages; do
		install -m644 -D "$_builddir"/docs/man/man1/$_manpage \
			"$pkgdir"/usr/share/man/man1/$_manpage || return 1
	done
}

md5sums="bbabdb7d934218de8fce0148eadce7e1  ansible-0.9.tar.gz"