[arch-commits] Commit in (7 files)

George Rawlinson grawlinson at archlinux.org
Fri Jun 11 08:50:51 UTC 2021


    Date: Friday, June 11, 2021 @ 08:50:51
  Author: grawlinson
Revision: 962041

addpkg: nomad 1.1.1-1

Initial info-dump

Added:
  nomad/
  nomad/repos/
  nomad/trunk/
  nomad/trunk/PKGBUILD
  nomad/trunk/nomad.hcl
  nomad/trunk/systemd.service
  nomad/trunk/tmpfiles.conf

-----------------+
 PKGBUILD        |   73 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
 nomad.hcl       |    1 
 systemd.service |   20 ++++++++++++++
 tmpfiles.conf   |    1 
 4 files changed, 95 insertions(+)

Added: nomad/trunk/PKGBUILD
===================================================================
--- nomad/trunk/PKGBUILD	                        (rev 0)
+++ nomad/trunk/PKGBUILD	2021-06-11 08:50:51 UTC (rev 962041)
@@ -0,0 +1,73 @@
+# Maintainer: George Rawlinson <grawlinson at archlinux.org>
+
+pkgname=nomad
+pkgver=1.1.1
+pkgrel=1
+pkgdesc="A simple and flexible workload orchestrator"
+arch=('x86_64')
+url="https://www.nomadproject.io"
+license=('MPL2')
+depends=('glibc' 'iptables')
+makedepends=('go' 'git')
+# additonal drivers:
+# podman: https://github.com/hashicorp/nomad-driver-podman
+# containerd: https://github.com/Roblox/nomad-driver-containerd
+# firecracker: https://github.com/firecracker-microvm/firecracker
+# lxc: https://github.com/hashicorp/nomad-driver-lxc
+# amazon-ecs (experimental): https://github.com/hashicorp/nomad-driver-ecs
+# singularity: https://github.com/hpcng/nomad-driver-singularity
+# systemd-nspawn: https://github.com/JanMa/nomad-driver-nspawn
+optdepends=(
+  'docker: for docker driver'
+  'java-runtime: for java driver'
+  'qemu: for qemu driver'
+)
+backup=(etc/nomad.d/nomad.hcl)
+source=(
+  "$pkgname-$pkgver.tar.gz::https://github.com/hashicorp/nomad/archive/v$pkgver.tar.gz"
+  'systemd.service'
+  'tmpfiles.conf'
+  'nomad.hcl'
+)
+b2sums=('85384697dc3da8846804e1e116b9048a662b90c1942254959f564da806a9cab7f42140f4c6947a5ccb02550b0b6902bde15c0fc607b32894ee5efb0f1ca95062'
+        '0f931868e9d7465f3be176ab789b7c7b5a4c35713a82e4d3bb94460254011779d814d4708f4f8cc76ba0dd1928ac7eeda42e01ed43be675a5d26d0b75ba986b9'
+        '464963ce700e41b081af414e36e0c255cfea9b4fa55cb34d892bfd70da6ece92d273dfee9cd542918bb2852b99bdc9cde1b082a8c4de6f1ce0024b534843c3d2'
+        '6050c07db88d1c3433915ad5733b43d7c4f4b32172e65915e0421693f8b78012ae7bb8b2e3cfa0bb9d49101db4f0ec2ca3d460ba984382ff4d48dd0b6ddc600d')
+
+prepare() {
+	cd "$pkgname-$pkgver"
+  mkdir build
+  go mod vendor
+}
+
+# README: https://www.nomadproject.io/docs/install/production/requirements
+# TODO find out what kind of 'upstream' configuration goes into /etc/nomad.d ?
+# REFERENCE: https://salsa.debian.org/go-team/packages/nomad
+
+build() {
+  # TODO find out if `make bootstrap` is actually required
+  # FIXME remove nonvidia for actual releases ...
+  # TODO find out what codegen_generated actually does
+  local GO_TAGS="ui release codegen_generated nonvidia"
+	cd "$pkgname-$pkgver"
+  CGO_ENABLED=1 go build -v \
+    -buildmode=pie \
+    -trimpath \
+    -mod=vendor \
+    -modcacherw \
+    -ldflags "-extldflags $LDFLAGS -X "main.GitCommit=${pkgver}"" \
+    -tags "$GO_TAGS" \
+    -o build .
+}
+
+package() {
+  # binary
+  install -vDm755 -t "$pkgdir/usr/bin" "$pkgname-$pkgver/build/$pkgname"
+
+  # configuration
+  install -vDm644 -t "$pkgdir/etc/nomad.d" nomad.hcl
+
+  # systemd integration
+  install -vDm644 systemd.service "$pkgdir/usr/lib/systemd/system/$pkgname.service"
+  install -vDm644 tmpfiles.conf "$pkgdir/usr/lib/tmpfiles.d/$pkgname.conf"
+}

Added: nomad/trunk/nomad.hcl
===================================================================
--- nomad/trunk/nomad.hcl	                        (rev 0)
+++ nomad/trunk/nomad.hcl	2021-06-11 08:50:51 UTC (rev 962041)
@@ -0,0 +1 @@
+data_dir = "/var/lib/nomad"

Added: nomad/trunk/systemd.service
===================================================================
--- nomad/trunk/systemd.service	                        (rev 0)
+++ nomad/trunk/systemd.service	2021-06-11 08:50:51 UTC (rev 962041)
@@ -0,0 +1,20 @@
+[Unit]
+Description=Nomad
+Documentation=https://www.nomadproject.io/docs/
+Wants=network-online.target consul.service
+After=network-online.target consul.service
+
+[Service]
+ExecReload=/bin/kill -HUP $MAINPID
+ExecStart=/usr/bin/nomad agent -config /etc/nomad.d
+KillMode=process
+KillSignal=SIGINT
+LimitNOFILE=65536
+LimitNPROC=infinity
+Restart=on-failure
+RestartSec=2
+TasksMax=infinity
+OOMScoreAdjust=-1000
+
+[Install]
+WantedBy=multi-user.target

Added: nomad/trunk/tmpfiles.conf
===================================================================
--- nomad/trunk/tmpfiles.conf	                        (rev 0)
+++ nomad/trunk/tmpfiles.conf	2021-06-11 08:50:51 UTC (rev 962041)
@@ -0,0 +1 @@
+d /var/lib/nomad 0700



More information about the arch-commits mailing list