blob: 1718decef7878ea61d4e12b9c99f28c35f561fc4 (
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
|
# Maintainer: Rob Bailey <actioninja@criticalaction.net>
pkgname=docker-etchosts
pkgver=0.1.5
pkgrel=1
pkgdesc="Automatically update your /etc/hosts file with the names of docker containers"
arch=('i686' 'x86_64' 'armv7h' 'aarch64')
url="https://github.com/costela/docker-etchosts"
license=('GPL-3.0-or-later')
depends=('go')
makedepends=('git')
source=("git+$url.git#tag=$pkgver" "docker-etchosts.service")
sha512sums=('SKIP' 'SKIP')
build() {
cd "$pkgname"
export CGO_CPPFLAGS="${CPPFLAGS}"
export CGO_CFLAGS="${CFLAGS}"
export CGO_CXXFLAGS="${CXXFLAGS}"
export CGO_LDFLAGS="${LDFLAGS}"
export GOFLAGS="-buildmode=pie -trimpath -modcacherw"
go build -o docker-etchosts
}
package() {
cd "$pkgname"
install -Dm755 "./docker-etchosts" "$pkgdir/usr/bin/docker-etchosts"
install -Dm644 "$srcdir/docker-etchosts.service" "$pkgdir/usr/lib/systemd/system/docker-etchosts.service"
}
|