1 # Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
2 # Contributor: Bruno Galeotti <bgaleotti at gmail dot com>
5 pkgname=(python-elasticsearch-curator curator)
8 pkgdesc='Curator: Tending your Elasticsearch indices'
9 url='https://github.com/elastic/curator'
12 makedepends=('python' 'python-setuptools' 'python-elasticsearch' 'python-boto3'
13 'python-requests-aws4auth' 'python-click' 'python-urllib3' 'python-yaml'
14 'python-voluptuous' 'python-certifi' 'python-six' 'python-sphinx'
15 'python-cx_freeze' 'xz' 'mpdecimal')
16 checkdepends=('python-pytest' 'python-mock')
17 options=('!makeflags')
18 source=(https://github.com/elastic/curator/archive/v${pkgver}/${pkgname}-${pkgver}.tar.gz
21 sha256sums=('a48486cacf0b32038358babfc5a8755c9a24992ff5279226b923298b426fe253'
22 '566c43ae1182cdf1e6b08b7adabdb8540a943b7d9ae42478c896b233fd3ffc8f'
23 '1003aff5daa7adcf31703bca26be8bb0fe7109732118c7e4e6e32e2eb931f07a')
24 sha512sums=('d4f46fad5d8107899fc4c9ee1b7dad595749415cee53f55993c517743df6119ff7680f3ad96f1a937d793dad395416257b56a4b3cdcd6a99b162ad7f77196051'
25 '3bfc811e10f36c3ebe792939a482c8bc0ca959223561f919561a6cb10038e4f72e2b944e2416c9e595d8f3189d9236bba52fd2e932519a843b06bc1b87ba9da6'
26 '5d153fb9d264ad7e55f34f368f2065eaf6c1e2546254527d13e99fdd3cca565dd6f9fc0fa21cd583c74d96af8e22bd5bc846278c6fa7149c2cc25194484c2f6c')
30 sed -e 's|click>=6.7,<7.0|click|' \
31 -e 's|urllib3>=1.24.2,<1.25|urllib3|' \
32 -e 's|pyyaml==3.12|pyyaml|' \
33 -i setup.py # Admit click 8
34 patch -Np1 -i ../pyyaml-6.patch # Fix calls to yaml.load()
35 patch -Np1 -i ../cx-freeze-6.7.patch # Fix build with cx-freeze 6.7
49 package_python-elasticsearch-curator() {
50 pkgdesc+=' (python API)'
51 depends=('python' 'python-elasticsearch' 'python-elasticsearch' 'python-boto3'
52 'python-requests-aws4auth' 'python-click' 'python-urllib3' 'python-yaml'
53 'python-voluptuous' 'python-certifi' 'python-six' 'python-cx_freeze'
56 python setup.py install --root="${pkgdir}" --optimize=1 --skip-build
57 install -Dm 644 docs/_build/text/* -t "${pkgdir}/usr/share/doc/${pkgname}"
58 install -Dm 644 docs/_build/man/curator.1 "${pkgdir}/usr/share/man/man1/${pkgname}.1"
59 rm -rf "${pkgdir}"/usr/bin
63 depends=('python' 'python-elasticsearch-curator')
64 provides=("elasticsearch-curator=${pkgver}-${pkgrel}")
66 python setup.py install --root="${pkgdir}" --optimize=1 --skip-build
67 rm -rf "${pkgdir}"/usr/lib