mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-24 19:55:26 +03:00
47 lines
1.5 KiB
Text
47 lines
1.5 KiB
Text
# Contributor: Michał Polański <michal@polanski.me>
|
|
# Maintainer: Michał Polański <michal@polanski.me>
|
|
pkgname=caddy
|
|
pkgver=2.6.4
|
|
pkgrel=1
|
|
pkgdesc="Fast, multi-platform web server with automatic HTTPS"
|
|
url="https://caddyserver.com/"
|
|
license="Apache-2.0"
|
|
arch="all"
|
|
depends="ca-certificates"
|
|
makedepends="go libcap-utils"
|
|
subpackages="$pkgname-openrc"
|
|
pkgusers="$pkgname"
|
|
pkggroups="$pkgname"
|
|
install="$pkgname.pre-install"
|
|
source="https://github.com/caddyserver/caddy/archive/v$pkgver/caddy-$pkgver.tar.gz
|
|
$pkgname.initd
|
|
Caddyfile
|
|
"
|
|
options="net" # for downloading Go modules
|
|
|
|
export CGO_ENABLED=0
|
|
export GOCACHE="${GOCACHE:-"$srcdir/go-cache"}"
|
|
export GOTMPDIR="${GOTMPDIR:-"$srcdir"}"
|
|
export GOMODCACHE="${GOMODCACHE:-"$srcdir/go"}"
|
|
|
|
build() {
|
|
go build -o bin/caddy ./cmd/caddy
|
|
}
|
|
|
|
check() {
|
|
go test ./...
|
|
}
|
|
|
|
package() {
|
|
install -Dm755 bin/caddy "$pkgdir"/usr/sbin/caddy
|
|
setcap cap_net_bind_service=+ep "$pkgdir"/usr/sbin/caddy
|
|
|
|
install -Dm755 "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname
|
|
install -Dm644 "$srcdir"/Caddyfile "$pkgdir"/etc/$pkgname/Caddyfile
|
|
}
|
|
|
|
sha512sums="
|
|
438869a24c0f68e8d742752d3573cf7894c566344f85d0e262ddf26d91c711dd27a0422396bfdd94823c8ee4c7fd24ce222938f3339f1c19e706e64207fc483f caddy-2.6.4.tar.gz
|
|
919a7a4158dc38e56aad1ae6e2d65416f7267c03f429738a7d5d9831b34dc5f01a29d69a6d44677dd9bb96c56fee9b0d3dc0f7e4416925f4fe46d34aef88a2d7 caddy.initd
|
|
d3110dd79f7d5e602a34d42569104dc97603994e42daf5f6b105303a3d034b52b91ef5fb156d5bf7b7a3a58ec0aeff58afc402618d0555af053771952a866f76 Caddyfile
|
|
"
|