diff options
Diffstat (limited to 'sys-cluster/nomad')
-rw-r--r-- | sys-cluster/nomad/Manifest | 8 | ||||
-rw-r--r-- | sys-cluster/nomad/files/nomad.service | 29 | ||||
-rw-r--r-- | sys-cluster/nomad/metadata.xml | 2 | ||||
-rw-r--r-- | sys-cluster/nomad/nomad-1.2.6.ebuild (renamed from sys-cluster/nomad/nomad-1.0.9.ebuild) | 24 |
4 files changed, 50 insertions, 13 deletions
diff --git a/sys-cluster/nomad/Manifest b/sys-cluster/nomad/Manifest index aaaacb9646da..d6c8cee4a2b7 100644 --- a/sys-cluster/nomad/Manifest +++ b/sys-cluster/nomad/Manifest @@ -1,6 +1,8 @@ AUX nomad.confd 70 BLAKE2B e7cd65e529d1a8d99212a3267d3dc8d6f6d8b310f7cbda77e31f6c6e26af41fe6866ea1c9dd579caa89b39edff2e7f70553d70d600e84cdc04dea25d50ed8883 SHA512 c4e646b97335123c6411b0a556eefb4a59198db3277ed5a833410b25a7ab9601548a5cb7dd041e031e55098e4d4c022d4b16b0ae9ba1a32358eb5d9403f4d7e9 AUX nomad.initd 534 BLAKE2B 392ba0c199a401c278d47f2fb068831f331485d34eb6d81d7e14df60cbcc62f3ecc01a200e5a8ac00ab734789c07d6bcd73391e67d5141f04365c08935c07d62 SHA512 63920465cc4346e6d79b54afd0c0ad418a06c5f977edf8a49adb8b2895390cc13d48a18fc377de91c92449af5095347c36aecf67eda528da76209e77130f2b98 AUX nomad.logrotated 83 BLAKE2B 2c970621c10520b2aaa17172d9c99a741737393db9a6424278e12d8b6676492c97b628d4be419ab921f7cf7685bae1a5e93eb04efa2ca6242012cfde203e02da SHA512 0ebdbeab15b01145eb2b33e0c6fd43dde3e4ac8eae9d8aff81797688276530732f613a39cd658fa4f5c2e8c99d70e6255f814ca5f3cd2bc5de259be324ab2851 -DIST nomad-1.0.9.tar.gz 40563203 BLAKE2B 5db3bce093ae873907572e5f67640fac162e4c4ffe436f2acd3ac9fe8da509f451ff73c948dcd49d10eb101afdfe5285b2906986983b938034c64aab8d0cab4d SHA512 66a00f15a16b57e8a3f97c43301bd9aaab76e185b56fe45193eb0e7c25e83fbcf1a7072f2d5fe4c533a00e63c71f3ec941a05cf6aa50f5051b8f3b5588b50463 -EBUILD nomad-1.0.9.ebuild 1189 BLAKE2B ba8a834564e39b12c47c6314d37ace0db1570f93014c99a84777f3eb66bc83b9f5cde0bf2392ea2d3529d5de0923470c1c7f04282da556db0f0947b1750d8caf SHA512 d7990eaeadb03bbba59d343ffe428715250655a18d9ad2d6165abf6d5a2a9bd49ea3a2269f0a638cbe1e989b14e24f4154276940ae1736566172579d0f2fba1f -MISC metadata.xml 325 BLAKE2B 37a27a523ca3a22207bf99f1febe5c08413572209df3b61fc76404ae1e0546a34a81f95f9cba7ec14856b01d939eb3e3d1a23f85f22c785c152ec0f713096776 SHA512 ba7e36dfc8098335f3b3581adf8ccf2c30742777b5066301d5b1afe846ee49ea6a5cb6de41735a18593b17bb801e829bdce5cb066a4b9d70656f2346a7f182b2 +AUX nomad.service 726 BLAKE2B 68e67299c15e096e0fca66a9cf87d6d2bd6e0339be8c8489e59c401f84b5aec86e3b55d566e7b6b0598afb17918c9a03a7b7c36851fd8486511955de2f9a12cb SHA512 c8959bfba81b48116ce4a0fc4b0cb439a7f289b27c3d9fc4a08a5c0d3fa7e1652642cb8b459f3ec96bbabf66a12010be190c7484060ebfae39bc8d0e82ecf442 +DIST nomad-1.2.6-vendor.tar.xz 8019208 BLAKE2B f972a84d201328f95e13a68fdc6dc0f0db5aff6d7ff98f5478ef310c6349fb4c0d9e5aa9c638ae81fb9f2776fa4d252c3b1daed091d3b9ae6d86a75d79e2ac0e SHA512 8d53eaa771847d862f14c3fad286fe42b5c4426b242b18d2b900e4807221e6624b8bb129f34c560078d8863ce19b58c6637d2cc806950fffb5140b8d44f44c8f +DIST nomad-1.2.6.tar.gz 29585632 BLAKE2B 1b9ecbb11ddc59f8078831c6d41b8547a572c3b8475a21d65b8333204bdd2a6ee646cc7c5ec2bdffaee6c1b3cdf2dc30a667464695057e49c2bca41128b61452 SHA512 93a3ed9b0d992ba25cb126496cb9ed250195d8b8011312ebc4cffdf5f9f8786bc43cbe18cefc820597b8a117a05f6118e2e4a88e25e738c1bd309c5504e93ed9 +EBUILD nomad-1.2.6.ebuild 1242 BLAKE2B 3a4d6982d3d91e3f43548fb594c48989afc55c10b3f62022826cf0c6c42e0056858219de8400f7e2fedb5868fb24175870b7d10d460ab9d4087b60821d234736 SHA512 d8aa9f9f44c07e9c46a6ace0f173f9b25812d01ee995b7f4ff48bc359f64c989a160c43d1e94470669dfa459085e15118eec90dafff9993fd34395509842d4f2 +MISC metadata.xml 325 BLAKE2B 00faa3d3eaaa071810bfe35c43e2a956c304098234e54a27ffd6630f4696323c29fdd9dfce086fb40d9432bd1ffabfebaa470da67566ddd8bdf5ec700a0a548d SHA512 dbbb8f548227eb2f79b51c02eb8e2ed6b45eb30e1b5808c60f6527fbf0c0504b20a1f51b556c97450e2837e05e5cea7179fc26548cc6e0dbf9a8c78c40768ca9 diff --git a/sys-cluster/nomad/files/nomad.service b/sys-cluster/nomad/files/nomad.service new file mode 100644 index 000000000000..08b243206d1b --- /dev/null +++ b/sys-cluster/nomad/files/nomad.service @@ -0,0 +1,29 @@ +[Unit] +Description=Nomad +Documentation=https://nomadproject.io/docs/ +Wants=network-online.target +After=network-online.target + +# When using Nomad with Consul it is not necessary to start Consul first. These +# lines start Consul before Nomad as an optimization to avoid Nomad logging +# that Consul is unavailable at startup. +#Wants=consul.service +#After=consul.service + +[Service] +EnvironmentFile=/etc/nomad.d/nomad.env +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 +StartLimitBurst=3 +StartLimitInterval=10 +TasksMax=infinity +OOMScoreAdjust=-1000 + +[Install] +WantedBy=multi-user.target diff --git a/sys-cluster/nomad/metadata.xml b/sys-cluster/nomad/metadata.xml index 162e602228fe..35a7a677df6a 100644 --- a/sys-cluster/nomad/metadata.xml +++ b/sys-cluster/nomad/metadata.xml @@ -6,6 +6,6 @@ <name>William Hubbs</name> </maintainer> <use> - <flag name="nvidia">build with nvidia integration</flag> + <flag name="ui">do not embed the ui in the binary</flag> </use> </pkgmetadata> diff --git a/sys-cluster/nomad/nomad-1.0.9.ebuild b/sys-cluster/nomad/nomad-1.2.6.ebuild index 1a271c9eabe7..c4e5fd6850ed 100644 --- a/sys-cluster/nomad/nomad-1.0.9.ebuild +++ b/sys-cluster/nomad/nomad-1.2.6.ebuild @@ -1,29 +1,37 @@ -# Copyright 2020-2021 Gentoo Authors +# Copyright 2020-2022 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 inherit go-module systemd -GIT_COMMIT=958556d77ee6f32d9a92cfbe39ec9d33781b1cdc +GIT_COMMIT=95514d569610f15ce49b4a7a1a6bfd3e7b3e7b4f DESCRIPTION="A simple and flexible workload orchestrator" HOMEPAGE="https://nomadproject.io" SRC_URI="https://github.com/hashicorp/nomad/archive/v${PV}.tar.gz -> ${P}.tar.gz" +SRC_URI+=" https://dev.gentoo.org/~williamh/dist/${P}-vendor.tar.xz" LICENSE="MPL-2.0" SLOT="0" KEYWORDS="~amd64" -IUSE="nvidia" +IUSE="ui" RESTRICT=" test" +src_prepare() { + default + if [[ -d ../vendor ]]; then + mv ../vendor . || die + fi +} + src_compile() { local go_ldflags go_tags go_ldflags="-X github.com/hashicorp/nomad/version.GitCommit=${GIT_COMMIT}" - go_tags="codegen_generated $(usex nvidia '' 'nonvidia')" + go_tags="codegen_generated" + go_tags+="$(usex ui ',ui' '' )" CGO_ENABLED=1 \ go build \ -ldflags "${go_ldflags}" \ - -mod=vendor \ -tags "${go_tags}" \ -trimpath \ -o bin/${PN} || die "compile failed" @@ -31,10 +39,8 @@ src_compile() { src_install() { dobin bin/${PN} - systemd_dounit dist/systemd/nomad.service - insinto /etc/nomad.d - newins dist/client.hcl client.hcl.example - newins dist/server.hcl server.hcl.example + systemd_dounit "${FILESDIR}"/nomad.service + keepdir /etc/nomad.d einstalldocs dodoc CHANGELOG.md keepdir /var/lib/nomad /var/log/nomad |