# Contributor: Joe Holden # Contributor: Michał Polański # Maintainer: Francesco Colista pkgname=traefik pkgver=2.10.4 pkgrel=1 pkgdesc="The Cloud Native Edge Router" url="https://traefik.io/" arch="all" arch="$arch !x86 !armhf !armv7 !s390x !ppc64le !riscv64" # failing tests license="MIT" makedepends="go go-bindata" checkdepends="tzdata" install="$pkgname.pre-install" pkgusers="$pkgname" pkggroups="$pkgname" subpackages="$pkgname-openrc" options="net setcap chmod-clean" source="$pkgname-$pkgver.tar.gz::https://github.com/containous/traefik/releases/download/v$pkgver/traefik-v$pkgver.src.tar.gz traefik.initd traefik.confd traefik.yaml " builddir="$srcdir" # secfixes: # 2.9.10-r0: # - CVE-2023-29013 # - CVE-2023-24534 # 2.9.6-r0: # - CVE-2022-23469 # - CVE-2022-46153 # 2.2.8-r0: # - CVE-2020-15129 export GOCACHE="${GOCACHE:-"$srcdir/go-cache"}" export GOTMPDIR="${GOTMPDIR:-"$srcdir"}" export GOMODCACHE="${GOMODCACHE:-"$srcdir/go"}" build() { go generate -v go build \ -ldflags "-X github.com/traefik/traefik/v2/pkg/version.Version=$pkgver" \ -v -o bin/$pkgname \ ./cmd/$pkgname } check() { # shellcheck disable=2046 CI=1 \ go test $(go list ./pkg/... | grep -Ev '(pkg/server)') } package() { install -Dm755 bin/$pkgname "$pkgdir"/usr/sbin/$pkgname install -Dm755 "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname install -Dm644 "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname install -dm750 -o $pkgname -g $pkgname "$pkgdir"/etc/$pkgname install -m644 -o $pkgname -g $pkgname "$srcdir"/traefik.yaml \ "$pkgdir"/etc/$pkgname/$pkgname.yaml } sha512sums=" cee01438cd5a5a5731875ebda3ab273d222969f2ec705875d7929d6e65cdf5ac1f309bc559f9e69ed86ff4df7e681159eba8fc465629eb9e7765f729c6042d75 traefik-2.10.4.tar.gz d5a64e46ebafebd1352fda2fae5c3b6ccb58d3191583b06efbba9eaf0b444d4a7b6743a347a13ad79ca207ddeda7ab8d7387ffd7d4f9160ec80b5f2521bf8808 traefik.initd bbc0bb6825f8847ef0ee18b7194afc4e1443041727022e435e48249744b1230b3422ff9d20a6b42d2e3615e57c10254611fe1e999b847e7b4a4d5954bd677cf2 traefik.confd ae87af859fa64aa35a5f8493dd29630d4ed8c6c8e6e70083bb03b2eded5cd1ab46979901fca5d495d2dd918bf1bbf0a553a43da38b9507a2437874bfcf09bc1a traefik.yaml "