sys-cluster/k3s: various updates

This commit is contained in:
Stefan Reimer 2019-09-24 10:32:10 +01:00
parent be93652c07
commit 8db0cce13d
4 changed files with 52 additions and 4 deletions

View File

@ -1,3 +1,5 @@
AUX k3s.conf 195 BLAKE2B 5abbfc47597f37d41c741c9c06eb2eb465f03dcd418368f7e695368d831691dee94405c940b09e089b2874897f1508b3b333d05c21c0e2de0ff8f8f961497d12 SHA512 491331db354cd7db91107fa1503419b29baa14fcf726b3754a67b9aba0d2ae939f2e174cb48b581946a80b75d5d4dbac79b7f421b5a225b481be7884d53e26e7
AUX k3s.openrc 722 BLAKE2B 1fc39868fccd9163d73e3227700c9d349d71141e78f115e85437b344af8054a868076cee8987232a8fb65287701e425bea75f6b5f38f878a8e334cd83fc92c8a SHA512 1a2400c0d9a72e7d8a428f485ffafb1dfb7c1a78e068b184bf931c86fb3e09fe6e6c33ee4714132f7f0fc0353ba3a0c35125d6c69469353ec0fc5e5a9e85736c
DIST github.com-Microsoft-go-winio-v0.4.12.tar.gz 92439 BLAKE2B 7ce1539125742ab5d96586a8cbaddef90f1aeba8124430ee33c23374a3dc1a117fe8bd6d68591c83f0a8e4fb1633c74a19fcc8466567f89450056ea3843dca21 SHA512 3dfeb9f884aff5bb1b667a6558471274161ca7b4cd9402e47250903b74522f0bd6dec13ce32c8312eb8570f94dc061a5bf9ada5e0837d45a510cd4abf38c8211 DIST github.com-Microsoft-go-winio-v0.4.12.tar.gz 92439 BLAKE2B 7ce1539125742ab5d96586a8cbaddef90f1aeba8124430ee33c23374a3dc1a117fe8bd6d68591c83f0a8e4fb1633c74a19fcc8466567f89450056ea3843dca21 SHA512 3dfeb9f884aff5bb1b667a6558471274161ca7b4cd9402e47250903b74522f0bd6dec13ce32c8312eb8570f94dc061a5bf9ada5e0837d45a510cd4abf38c8211
DIST github.com-alexflint-go-filemutex-72bdc8eae2ae.tar.gz 3110 BLAKE2B 71924138332ea7609025d0f031212404131595bb79a11eb9e3a400ebcb1a3828a04d78fb20846d0af4d805986add9db0660c1503658bdb6035c39521d557d480 SHA512 ee78d132ecb8daa6502c532bff900b94909f59daac656fad1a39c4a7a524ef2eafde8378d54ce079ed6c58d71e70c5f591a11888492ed23fccf3949b4813fde9 DIST github.com-alexflint-go-filemutex-72bdc8eae2ae.tar.gz 3110 BLAKE2B 71924138332ea7609025d0f031212404131595bb79a11eb9e3a400ebcb1a3828a04d78fb20846d0af4d805986add9db0660c1503658bdb6035c39521d557d480 SHA512 ee78d132ecb8daa6502c532bff900b94909f59daac656fad1a39c4a7a524ef2eafde8378d54ce079ed6c58d71e70c5f591a11888492ed23fccf3949b4813fde9
DIST github.com-bhendo-go-powershell-219e7fb4e41e.tar.gz 5756 BLAKE2B b21030e20736251d73814c2a3e2aba192da4265c56f04ad44c2606f0fa82d34d049e402ac12ea0aea1a0f0607bfad0af29d2d654a0d38b1f90c9c942dfa6217b SHA512 229b262506e8ec1dae9c3af48a641ed3417976611a582a056313c31fb7719edadcebcc14fa8b04585515030108c9bb76a43d161f834ae1d774b47d44edf2f8b4 DIST github.com-bhendo-go-powershell-219e7fb4e41e.tar.gz 5756 BLAKE2B b21030e20736251d73814c2a3e2aba192da4265c56f04ad44c2606f0fa82d34d049e402ac12ea0aea1a0f0607bfad0af29d2d654a0d38b1f90c9c942dfa6217b SHA512 229b262506e8ec1dae9c3af48a641ed3417976611a582a056313c31fb7719edadcebcc14fa8b04585515030108c9bb76a43d161f834ae1d774b47d44edf2f8b4
@ -41,4 +43,4 @@ DIST github.com-xeipuuv-gojsonpointer-4e3ac2762d5f.tar.gz 7718 BLAKE2B 94b4c2ac9
DIST github.com-xeipuuv-gojsonreference-bd5ef7bd5415.tar.gz 6952 BLAKE2B 5390e11eaae7b3ef816f044874e665ce76cdf84cfdd19139a0923921f56e8cc24fc418952a0d1ec1ef56aa535fe314c131073ff0ae248f1c4b918bd70485d073 SHA512 e14f931af21c64ad4fd68e3f226d062938e747fc0107b00c41ffac489193b39874ed1ebe6dc24478f6979f9055ae4ca67c016c11952589c8a95ca3f3fc69c1ea DIST github.com-xeipuuv-gojsonreference-bd5ef7bd5415.tar.gz 6952 BLAKE2B 5390e11eaae7b3ef816f044874e665ce76cdf84cfdd19139a0923921f56e8cc24fc418952a0d1ec1ef56aa535fe314c131073ff0ae248f1c4b918bd70485d073 SHA512 e14f931af21c64ad4fd68e3f226d062938e747fc0107b00c41ffac489193b39874ed1ebe6dc24478f6979f9055ae4ca67c016c11952589c8a95ca3f3fc69c1ea
DIST github.com-xeipuuv-gojsonschema-1d523034197f.tar.gz 64953 BLAKE2B 4b9b3ceeb9bf6b7eeb040b5921101a9fbec82f282cb44e2a76b7b2c0b8666ddfc82d7afd83e3ec766b076fc30e43ddf05c0314393caf571e58fd61c728b843fd SHA512 422e777b208b300abf18ac4732a3f7fb4b72087fb2c8c6832d57bc9794206f266e896c5eba7ea5040639e3cdd7d85fd982e86d0661a534d33e37811651dfbea8 DIST github.com-xeipuuv-gojsonschema-1d523034197f.tar.gz 64953 BLAKE2B 4b9b3ceeb9bf6b7eeb040b5921101a9fbec82f282cb44e2a76b7b2c0b8666ddfc82d7afd83e3ec766b076fc30e43ddf05c0314393caf571e58fd61c728b843fd SHA512 422e777b208b300abf18ac4732a3f7fb4b72087fb2c8c6832d57bc9794206f266e896c5eba7ea5040639e3cdd7d85fd982e86d0661a534d33e37811651dfbea8
DIST k3s-0.9.0.tar.gz 17410789 BLAKE2B d178f556c3d0c18929fa2d7d1bf3e2ea9665e263e5a764b148191c09647640f683ba1f853f99511885ff67fce0e1a0d41f3f40047022763dfe49acee5c1a16cf SHA512 3a0a75989b8ccdb0d0d41eb82ec232f9a32749fef1e519d3a6be19b43d91f4fb166b64f4a5cb61b2b759f692d82d8ea47400c771ca14c8111fcc1a0bec447f65 DIST k3s-0.9.0.tar.gz 17410789 BLAKE2B d178f556c3d0c18929fa2d7d1bf3e2ea9665e263e5a764b148191c09647640f683ba1f853f99511885ff67fce0e1a0d41f3f40047022763dfe49acee5c1a16cf SHA512 3a0a75989b8ccdb0d0d41eb82ec232f9a32749fef1e519d3a6be19b43d91f4fb166b64f4a5cb61b2b759f692d82d8ea47400c771ca14c8111fcc1a0bec447f65
EBUILD k3s-0.9.0.ebuild 3978 BLAKE2B c8e5f5a358a69cb9a06ae2a035a763c36fe33eaa63abce2e2c9661c7f4287d2a002f07d8a4abfbd0c48f913ae16d1fb2453dcae649df80383e40b5b38e3ba9f2 SHA512 854c84cd665fc21be257f76fe1bf1ba9f597d9588d3e505a6174bd704812053692c91396171aebc5bd231c2c0a403f737d1c7126323710a6eaa40aaa5349d5c3 EBUILD k3s-0.9.0.ebuild 4103 BLAKE2B d67216947c188661aa43104299bb215c8b38f329df44a3d8679f36047fea221f952a29b321c47f3e0c336ff949d4fc1d20705f30cdbc1327cca466e0d9f69983 SHA512 bacd8bbdd770753dbf2d5d9cb63c484f8200db17c1223ead7936e8e057b47f82af49929d0bca833075f6851d867e19f8e7bb9d01233c00385987b01188fe7e2e

View File

@ -0,0 +1,9 @@
# /etc/init.d/k3s
# Source and details
# https://github.com/rancher/k3s/blob/76d685ae5ddfe128267f8f44d2f22bf8cbf3f666/install.sh
# Change here for server / agent
CMD_K3S=server
K3S_OPTIONS=""

View File

@ -0,0 +1,34 @@
#!/sbin/openrc-run
# Copyright 2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
depend() {
after net-online
need net
}
start_pre() {
rm -f /tmp/k3s.*
}
supervisor=supervise-daemon
SYSTEM_NAME=k3s
[ "${CMD_K3S}" = "server" ] || SYSTEM_NAME=k3s-${CMD_K3S}
LOG_FILE=/var/log/${SYSTEM_NAME}.log
name="k3s"
name="${SYSTEM_NAME}"
command="/usr/bin/k3s"
command_args="${CMD_K3S} ${K3S_OPTIONS} >>${LOG_FILE} 2>&1"
output_log="${LOG_FILE}"
error_log="${LOG_FILE}"
pidfile="/var/run/${SYSTEM_NAME}.pid"
respawn_delay=5
set -o allexport
if [ -f /etc/environment ]; then source /etc/environment; fi
if [ -f /etc/conf.d/k3s ]; then source /etc/conf.d/k3s; fi
set +o allexport

View File

@ -54,7 +54,7 @@ inherit eutils golang-build golang-vcs-snapshot
ARCHIVE_URI="https://${EGO_PN}/archive/${EGIT_COMMIT}.tar.gz -> ${P}.tar.gz" ARCHIVE_URI="https://${EGO_PN}/archive/${EGIT_COMMIT}.tar.gz -> ${P}.tar.gz"
KEYWORDS="~amd64" KEYWORDS="~amd64"
IUSE="+rootless" IUSE="+rootless +traefik"
DESCRIPTION="Lightweight Kubernetes. 5 less than k8s." DESCRIPTION="Lightweight Kubernetes. 5 less than k8s."
HOMEPAGE="https://k3s.io" HOMEPAGE="https://k3s.io"
@ -92,6 +92,8 @@ EOF
# Disable go generate, create codegen only # Disable go generate, create codegen only
sed -i -e 's|go generate|go run pkg/codegen/main.go|' scripts/package-cli sed -i -e 's|go generate|go run pkg/codegen/main.go|' scripts/package-cli
use traefik || rm -f manifests/traefik.yaml
} }
@ -116,9 +118,10 @@ src_install() {
dobin dist/artifacts/k3s dobin dist/artifacts/k3s
keepdir /var/lib/rancher newinitd "${FILESDIR}/k3s.openrc" k3s
newconfd "${FILESDIR}/k3s.conf" k3s
popd keepdir /var/lib/rancher
} }
pkg_preinst() { pkg_preinst() {