[arch-commits] Commit in (7 files)

George Rawlinson grawlinson at gemini.archlinux.org
Wed Nov 17 21:24:49 UTC 2021


    Date: Wednesday, November 17, 2021 @ 21:24:48
  Author: grawlinson
Revision: 1051231

addpkg: drone-runner-docker 1.7.0-1

Added:
  drone-runner-docker/
  drone-runner-docker/repos/
  drone-runner-docker/trunk/
  drone-runner-docker/trunk/PKGBUILD
  drone-runner-docker/trunk/systemd.service
  drone-runner-docker/trunk/sysusers.conf
  drone-runner-docker/trunk/tmpfiles.conf

-----------------+
 PKGBUILD        |   77 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
 systemd.service |   14 +++++++++
 sysusers.conf   |    1 
 tmpfiles.conf   |    1 
 4 files changed, 93 insertions(+)

Added: drone-runner-docker/trunk/PKGBUILD
===================================================================
--- drone-runner-docker/trunk/PKGBUILD	                        (rev 0)
+++ drone-runner-docker/trunk/PKGBUILD	2021-11-17 21:24:48 UTC (rev 1051231)
@@ -0,0 +1,77 @@
+# Maintainer: George Rawlinson <grawlinson at archlinux.org>
+
+pkgname=drone-runner-docker
+pkgver=1.7.0
+pkgrel=1
+pkgdesc="Drone pipeline runner that executes builds inside Docker containers"
+arch=('x86_64')
+url="https://github.com/drone-runners/drone-runner-docker"
+license=('custom:Polyform-Small-Business-1.0.0' 'custom:Polyform-Free-Trial-1.0.0')
+depends=('glibc' 'docker')
+makedepends=('go' 'git')
+optdepends=('drone: for a local Drone instance')
+source=(
+  "$pkgname-$pkgver.tar.gz::$url/archive/v$pkgver.tar.gz"
+  'systemd.service'
+  'sysusers.conf'
+  'tmpfiles.conf'
+)
+sha512sums=('1bc1a88b6e645e7bd9285101387fa9490a5d8f6f6493efb5987349e8b00b9571bf52079ada3d3f314fa0e8fd63abcd89f5b5c2e6b030231968c340498ae9025b'
+            'eb92c3ad379153953adb07d064d1f33ba52015df2fb045412c57d38c5000f74ce1a0f8ea6042ffd1a5dcf3adbc5535b19067488cc5fd351d78c014effbbd17e8'
+            'fd328a189b7144e1cc519cf24863de2c4552c4df29ebb30cad3d100163577bd3083cdadb8eef7fa6970149f5a470490fd26a47ddf2a8d502cd38e977599159a1'
+            'e0d22286f58388e0393c0368bd5ea56099718ba772805913056c5251597d3887e013ba5fc9243d856d61d3b531dfd18087dd7aafe43c5857074ad6caceeee255')
+b2sums=('e7b749cf2c04f11ed9cb5e486a1bb7a39c85f060ee9448ee9206407788a058d8d829d1c54571699206de6a01a5546256d127f604e3a7948df31606dd43e31350'
+        'a76e0c190fcecbd99be68e9ead11c6cda27cf30045c9585356032982d1ecf053f2e8ed5b2a640403bd6a214eccfa50ec425bf34a284966a315a6754272133e99'
+        '327ef1f6158fc970d37b41d40e3b2f2c937f701ac4d7dda846b48ddf517d3f0e39ce360ae13aef8539587e71f861593941da3be32df032f6d65deb7927c8da9b'
+        '02b6ca4f1bdbaf968c81a2aab25efdb76d53590baadfa4c239239bc2b39bf09f8266775fc8addcf3a51fa48bd0a1ecfdb34c674b7355fbe5476cd53ae1780504')
+
+prepare() {
+  cd "$pkgname-$pkgver"
+
+  # create directory for build output
+  mkdir -p build
+
+  # download dependencies
+  go mod download
+}
+
+build() {
+  cd "$pkgname-$pkgver"
+
+  # set Go flags
+  export CGO_CPPFLAGS="${CPPFLAGS}"
+  export CGO_CFLAGS="${CFLAGS}"
+  export CGO_CXXFLAGS="${CXXFLAGS}"
+
+  go build -v \
+    -trimpath \
+    -buildmode=pie \
+    -mod=readonly \
+    -modcacherw \
+    -ldflags "-linkmode external -extldflags \"${LDFLAGS}\"" \
+    -o build \
+    .
+}
+
+check() {
+  cd "$pkgname-$pkgver"
+  go test -v ./...
+}
+
+package() {
+  # systemd integration
+  install -vDm644 systemd.service "$pkgdir/usr/lib/systemd/system/$pkgname.service"
+  install -vDm644 sysusers.conf "$pkgdir/usr/lib/sysusers.d/$pkgname.conf"
+  install -vDm644 tmpfiles.conf "$pkgdir/usr/lib/tmpfiles.d/$pkgname.conf"
+
+  cd "$pkgname-$pkgver"
+
+  # binary
+  install -vDm755 -t "$pkgdir/usr/bin" build/*
+
+  # licenses
+  install -vDm644 -t "$pkgdir/usr/share/licenses/$pkgname" licenses/* LICENSE.md
+
+  # documentation
+  install -vDm644 -t "$pkgdir/usr/share/doc/$pkgname" README.md CHANGELOG.md
+}

Added: drone-runner-docker/trunk/systemd.service
===================================================================
--- drone-runner-docker/trunk/systemd.service	                        (rev 0)
+++ drone-runner-docker/trunk/systemd.service	2021-11-17 21:24:48 UTC (rev 1051231)
@@ -0,0 +1,14 @@
+[Unit]
+Description=Drone Runner (Docker)
+Requires=network-online.target
+After=network-online.target
+
+[Service]
+User=drone-runner-docker
+Group=drone-runner-docker
+WorkingDirectory=/var/lib/drone-runner-docker
+ReadWritePaths=/var/lib/drone-runner-docker
+ExecStart=/usr/bin/drone-runner-docker
+
+[Install]
+WantedBy=multi-user.target

Added: drone-runner-docker/trunk/sysusers.conf
===================================================================
--- drone-runner-docker/trunk/sysusers.conf	                        (rev 0)
+++ drone-runner-docker/trunk/sysusers.conf	2021-11-17 21:24:48 UTC (rev 1051231)
@@ -0,0 +1 @@
+u drone-runner-docker - "Drone Runner Docker user"

Added: drone-runner-docker/trunk/tmpfiles.conf
===================================================================
--- drone-runner-docker/trunk/tmpfiles.conf	                        (rev 0)
+++ drone-runner-docker/trunk/tmpfiles.conf	2021-11-17 21:24:48 UTC (rev 1051231)
@@ -0,0 +1 @@
+d /var/lib/drone-runner-docker 0750 drone-runner-docker drone-runner-docker



More information about the arch-commits mailing list