Compare commits

..

2 Commits

Author SHA1 Message Date
a53cb9c98f upgpkg: thumbor 7.0.0a5-2 2021-03-16 13:12:22 +01:00
54b4ca44de Initial upload: thumbor 7.0.0a5-1 2021-03-16 12:34:08 +01:00
3 changed files with 76 additions and 0 deletions

17
thumbor/.SRCINFO Normal file
View File

@@ -0,0 +1,17 @@
pkgbase = thumbor
pkgdesc = open-source photo thumbnail service
pkgver = 7.0.0a5
pkgrel = 2
url = https://github.com/thumbor/thumbor
arch = x86_64
license = MIT
makedepends = python-setuptools
depends = python
backup = etc/thumbor.conf
source = https://github.com/thumbor/thumbor/archive/7.0.0a5.tar.gz
source = thumbor.service
b2sums = be18d4cda7cfb759a4a928bb6e63f2b8126a379a81c9902dd3e8e243e0418bb294a684664c636ffdc86a96366976ed5510a084e44e643581874da1f085a219cc
b2sums = c0fe21516f245132ac9bb1a833601eabc8348f8c420c76d49ffe7cb25e00712fcbc0fe7c579604616f5008507ec9f7582936596e54e8a311acf949fb031cd5ca
pkgname = thumbor

38
thumbor/PKGBUILD Normal file
View File

@@ -0,0 +1,38 @@
# Maintainer: Giovanni Harting <539@idlegandalf.com>
pkgname=thumbor
pkgver=7.0.0a5
pkgrel=2
pkgdesc="open-source photo thumbnail service"
arch=('x86_64')
url="https://github.com/thumbor/thumbor"
license=('MIT')
depends=(python)
makedepends=(python-setuptools)
backup=("etc/thumbor.conf")
source=("https://github.com/thumbor/thumbor/archive/$pkgver.tar.gz"
"thumbor.service")
b2sums=('be18d4cda7cfb759a4a928bb6e63f2b8126a379a81c9902dd3e8e243e0418bb294a684664c636ffdc86a96366976ed5510a084e44e643581874da1f085a219cc'
'c0fe21516f245132ac9bb1a833601eabc8348f8c420c76d49ffe7cb25e00712fcbc0fe7c579604616f5008507ec9f7582936596e54e8a311acf949fb031cd5ca')
prepare() {
cd "$pkgname-$pkgver"
# Adjust storage/cache paths to match systemd service
sed -e "s|FILE_STORAGE_ROOT_PATH = join(home, 'thumbor', 'storage' )|FILE_STORAGE_ROOT_PATH = '/var/lib/thumbor'|" \
-e "s|RESULT_STORAGE_FILE_STORAGE_ROOT_PATH = join(home, 'thumbor', 'result_storage')|RESULT_STORAGE_FILE_STORAGE_ROOT_PATH = '/var/cache/thumbor'|" \
-i $pkgname/$pkgname.conf
}
build() {
cd "$pkgname-$pkgver"
python setup.py build
}
package() {
cd "$pkgname-$pkgver"
python setup.py install --root="$pkgdir" --optimize=1 --skip-build
install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
install -Dm 644 $srcdir/thumbor.service -t "${pkgdir}"/usr/lib/systemd/system/
install -Dm 644 $pkgname/$pkgname.conf -t "${pkgdir}"/etc/
}

21
thumbor/thumbor.service Normal file
View File

@@ -0,0 +1,21 @@
[Unit]
Description=open-source photo thumbnail service
Documentation=https://github.com/thumbor/thumbor
After=network.target
[Service]
DynamicUser=true
CacheDirectory=thumbor
StateDirectory=thumbor
AmbientCapabilities=
CapabilityBoundingSet=
LockPersonality=true
ProtectControlGroups=true
ProtectKernelModules=true
ProtectKernelTunables=true
ExecStart=/usr/bin/thumbor --conf=/etc/thumbor.conf
[Install]
WantedBy=multi-user.target