From 121257c6bb27a59beb39c0989343dfda02174a1e Mon Sep 17 00:00:00 2001 From: Fred Clausen <43556888+fredclausen@users.noreply.github.com> Date: Mon, 28 Aug 2023 17:13:55 -0600 Subject: [PATCH] S6 (#175) * initial * fix service --- .../s6-rc.d/01-show-rbfeeder-changelog/type | 1 + .../s6-rc.d/01-show-rbfeeder-changelog/up | 2 ++ rootfs/etc/s6-overlay/s6-rc.d/02-rbfeeder/type | 1 + rootfs/etc/s6-overlay/s6-rc.d/02-rbfeeder/up | 2 ++ .../s6-rc.d/03-show-architecture/type | 1 + .../s6-overlay/s6-rc.d/03-show-architecture/up | 2 ++ .../dependencies.d/01-show-rbfeeder-changelog | 0 .../dependencies.d/02-rbfeeder | 0 .../dependencies.d/03-show-architecture | 0 .../s6-overlay/s6-rc.d/978json-splitter/run | 2 ++ .../s6-overlay/s6-rc.d/978json-splitter/type | 1 + .../dependencies.d/01-show-rbfeeder-changelog | 0 .../rbfeeder-log/dependencies.d/02-rbfeeder | 0 .../dependencies.d/03-show-architecture | 0 .../rbfeeder-log/dependencies.d/rbfeeder | 0 rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/run | 2 ++ .../etc/s6-overlay/s6-rc.d/rbfeeder-log/type | 1 + .../dependencies.d/01-show-rbfeeder-changelog | 0 .../rbfeeder/dependencies.d/02-rbfeeder | 0 .../dependencies.d/03-show-architecture | 0 rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/run | 2 ++ rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/type | 1 + .../dependencies.d/01-show-rbfeeder-changelog | 0 .../s6-rc.d/stats/dependencies.d/02-rbfeeder | 0 .../stats/dependencies.d/03-show-architecture | 0 rootfs/etc/s6-overlay/s6-rc.d/stats/run | 2 ++ rootfs/etc/s6-overlay/s6-rc.d/stats/type | 1 + .../user/contents.d/01-show-rbfeeder-changelog | 0 .../s6-rc.d/user/contents.d/02-rbfeeder | 0 .../user/contents.d/03-show-architecture | 0 .../s6-rc.d/user/contents.d/978json-splitter | 0 .../s6-rc.d/user/contents.d/rbfeeder | 0 .../s6-rc.d/user/contents.d/rbfeeder-log | 0 .../s6-overlay/s6-rc.d/user/contents.d/stats | 0 .../scripts/01-show-rbfeeder-changelog} | 0 .../scripts/02-rbfeeder} | 2 +- .../scripts/03-show-architecture} | 0 .../scripts/978json-splitter} | 2 +- .../run => s6-overlay/scripts/rbfeeder} | 2 +- .../run => s6-overlay/scripts/rbfeeder-log} | 0 .../stats/run => s6-overlay/scripts/stats} | 2 +- .../cpu-serial-workaround-checker/run | 18 ------------------ 42 files changed, 25 insertions(+), 22 deletions(-) create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/01-show-rbfeeder-changelog/type create mode 100755 rootfs/etc/s6-overlay/s6-rc.d/01-show-rbfeeder-changelog/up create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/02-rbfeeder/type create mode 100755 rootfs/etc/s6-overlay/s6-rc.d/02-rbfeeder/up create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/03-show-architecture/type create mode 100755 rootfs/etc/s6-overlay/s6-rc.d/03-show-architecture/up create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/dependencies.d/01-show-rbfeeder-changelog create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/dependencies.d/02-rbfeeder create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/dependencies.d/03-show-architecture create mode 100755 rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/run create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/type create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/dependencies.d/01-show-rbfeeder-changelog create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/dependencies.d/02-rbfeeder create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/dependencies.d/03-show-architecture create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/dependencies.d/rbfeeder create mode 100755 rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/run create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/type create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/dependencies.d/01-show-rbfeeder-changelog create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/dependencies.d/02-rbfeeder create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/dependencies.d/03-show-architecture create mode 100755 rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/run create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/type create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/stats/dependencies.d/01-show-rbfeeder-changelog create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/stats/dependencies.d/02-rbfeeder create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/stats/dependencies.d/03-show-architecture create mode 100755 rootfs/etc/s6-overlay/s6-rc.d/stats/run create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/stats/type create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/01-show-rbfeeder-changelog create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/02-rbfeeder create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/03-show-architecture create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/978json-splitter create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/rbfeeder create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/rbfeeder-log create mode 100644 rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/stats rename rootfs/etc/{cont-init.d/01-show-rbfeeder-changelog.sh => s6-overlay/scripts/01-show-rbfeeder-changelog} (100%) rename rootfs/etc/{cont-init.d/02-rbfeeder.sh => s6-overlay/scripts/02-rbfeeder} (98%) rename rootfs/etc/{cont-init.d/03-show-architecture.sh => s6-overlay/scripts/03-show-architecture} (100%) rename rootfs/etc/{services.d/978json-splitter/run => s6-overlay/scripts/978json-splitter} (91%) rename rootfs/etc/{services.d/rbfeeder/run => s6-overlay/scripts/rbfeeder} (96%) rename rootfs/etc/{services.d/rbfeeder/log/run => s6-overlay/scripts/rbfeeder-log} (100%) rename rootfs/etc/{services.d/stats/run => s6-overlay/scripts/stats} (97%) delete mode 100755 rootfs/etc/services.d.disabled/cpu-serial-workaround-checker/run diff --git a/rootfs/etc/s6-overlay/s6-rc.d/01-show-rbfeeder-changelog/type b/rootfs/etc/s6-overlay/s6-rc.d/01-show-rbfeeder-changelog/type new file mode 100644 index 0000000..bdd22a1 --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/01-show-rbfeeder-changelog/type @@ -0,0 +1 @@ +oneshot diff --git a/rootfs/etc/s6-overlay/s6-rc.d/01-show-rbfeeder-changelog/up b/rootfs/etc/s6-overlay/s6-rc.d/01-show-rbfeeder-changelog/up new file mode 100755 index 0000000..c172067 --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/01-show-rbfeeder-changelog/up @@ -0,0 +1,2 @@ +#!/bin/sh +exec /etc/s6-overlay/scripts/01-show-rbfeeder-changelog diff --git a/rootfs/etc/s6-overlay/s6-rc.d/02-rbfeeder/type b/rootfs/etc/s6-overlay/s6-rc.d/02-rbfeeder/type new file mode 100644 index 0000000..bdd22a1 --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/02-rbfeeder/type @@ -0,0 +1 @@ +oneshot diff --git a/rootfs/etc/s6-overlay/s6-rc.d/02-rbfeeder/up b/rootfs/etc/s6-overlay/s6-rc.d/02-rbfeeder/up new file mode 100755 index 0000000..8fc3b94 --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/02-rbfeeder/up @@ -0,0 +1,2 @@ +#!/bin/sh +exec /etc/s6-overlay/scripts/02-rbfeeder diff --git a/rootfs/etc/s6-overlay/s6-rc.d/03-show-architecture/type b/rootfs/etc/s6-overlay/s6-rc.d/03-show-architecture/type new file mode 100644 index 0000000..bdd22a1 --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/03-show-architecture/type @@ -0,0 +1 @@ +oneshot diff --git a/rootfs/etc/s6-overlay/s6-rc.d/03-show-architecture/up b/rootfs/etc/s6-overlay/s6-rc.d/03-show-architecture/up new file mode 100755 index 0000000..f818d83 --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/03-show-architecture/up @@ -0,0 +1,2 @@ +#!/bin/sh +exec /etc/s6-overlay/scripts/03-show-architecture diff --git a/rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/dependencies.d/01-show-rbfeeder-changelog b/rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/dependencies.d/01-show-rbfeeder-changelog new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/dependencies.d/02-rbfeeder b/rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/dependencies.d/02-rbfeeder new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/dependencies.d/03-show-architecture b/rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/dependencies.d/03-show-architecture new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/run b/rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/run new file mode 100755 index 0000000..e6f9327 --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/run @@ -0,0 +1,2 @@ +#!/bin/sh +exec /etc/s6-overlay/scripts/978json-splitter diff --git a/rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/type b/rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/type new file mode 100644 index 0000000..5883cff --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/978json-splitter/type @@ -0,0 +1 @@ +longrun diff --git a/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/dependencies.d/01-show-rbfeeder-changelog b/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/dependencies.d/01-show-rbfeeder-changelog new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/dependencies.d/02-rbfeeder b/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/dependencies.d/02-rbfeeder new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/dependencies.d/03-show-architecture b/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/dependencies.d/03-show-architecture new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/dependencies.d/rbfeeder b/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/dependencies.d/rbfeeder new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/run b/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/run new file mode 100755 index 0000000..197b7a8 --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/run @@ -0,0 +1,2 @@ +#!/bin/sh +exec /etc/s6-overlay/scripts/rbfeeder-log diff --git a/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/type b/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/type new file mode 100644 index 0000000..5883cff --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder-log/type @@ -0,0 +1 @@ +longrun diff --git a/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/dependencies.d/01-show-rbfeeder-changelog b/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/dependencies.d/01-show-rbfeeder-changelog new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/dependencies.d/02-rbfeeder b/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/dependencies.d/02-rbfeeder new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/dependencies.d/03-show-architecture b/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/dependencies.d/03-show-architecture new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/run b/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/run new file mode 100755 index 0000000..ea8f17f --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/run @@ -0,0 +1,2 @@ +#!/bin/sh +exec /etc/s6-overlay/scripts/rbfeeder diff --git a/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/type b/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/type new file mode 100644 index 0000000..5883cff --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/rbfeeder/type @@ -0,0 +1 @@ +longrun diff --git a/rootfs/etc/s6-overlay/s6-rc.d/stats/dependencies.d/01-show-rbfeeder-changelog b/rootfs/etc/s6-overlay/s6-rc.d/stats/dependencies.d/01-show-rbfeeder-changelog new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/stats/dependencies.d/02-rbfeeder b/rootfs/etc/s6-overlay/s6-rc.d/stats/dependencies.d/02-rbfeeder new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/stats/dependencies.d/03-show-architecture b/rootfs/etc/s6-overlay/s6-rc.d/stats/dependencies.d/03-show-architecture new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/stats/run b/rootfs/etc/s6-overlay/s6-rc.d/stats/run new file mode 100755 index 0000000..fd5c86e --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/stats/run @@ -0,0 +1,2 @@ +#!/bin/sh +exec /etc/s6-overlay/scripts/stats diff --git a/rootfs/etc/s6-overlay/s6-rc.d/stats/type b/rootfs/etc/s6-overlay/s6-rc.d/stats/type new file mode 100644 index 0000000..5883cff --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/stats/type @@ -0,0 +1 @@ +longrun diff --git a/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/01-show-rbfeeder-changelog b/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/01-show-rbfeeder-changelog new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/02-rbfeeder b/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/02-rbfeeder new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/03-show-architecture b/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/03-show-architecture new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/978json-splitter b/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/978json-splitter new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/rbfeeder b/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/rbfeeder new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/rbfeeder-log b/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/rbfeeder-log new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/stats b/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/stats new file mode 100644 index 0000000..e69de29 diff --git a/rootfs/etc/cont-init.d/01-show-rbfeeder-changelog.sh b/rootfs/etc/s6-overlay/scripts/01-show-rbfeeder-changelog similarity index 100% rename from rootfs/etc/cont-init.d/01-show-rbfeeder-changelog.sh rename to rootfs/etc/s6-overlay/scripts/01-show-rbfeeder-changelog diff --git a/rootfs/etc/cont-init.d/02-rbfeeder.sh b/rootfs/etc/s6-overlay/scripts/02-rbfeeder similarity index 98% rename from rootfs/etc/cont-init.d/02-rbfeeder.sh rename to rootfs/etc/s6-overlay/scripts/02-rbfeeder index d9b5e52..69e5aa0 100755 --- a/rootfs/etc/cont-init.d/02-rbfeeder.sh +++ b/rootfs/etc/s6-overlay/scripts/02-rbfeeder @@ -1,4 +1,4 @@ -#!/usr/bin/with-contenv bash +#!/command/with-contenv bash # shellcheck shell=bash # Check to make sure the correct command line arguments have been set diff --git a/rootfs/etc/cont-init.d/03-show-architecture.sh b/rootfs/etc/s6-overlay/scripts/03-show-architecture similarity index 100% rename from rootfs/etc/cont-init.d/03-show-architecture.sh rename to rootfs/etc/s6-overlay/scripts/03-show-architecture diff --git a/rootfs/etc/services.d/978json-splitter/run b/rootfs/etc/s6-overlay/scripts/978json-splitter similarity index 91% rename from rootfs/etc/services.d/978json-splitter/run rename to rootfs/etc/s6-overlay/scripts/978json-splitter index 156b890..79e0edf 100755 --- a/rootfs/etc/services.d/978json-splitter/run +++ b/rootfs/etc/s6-overlay/scripts/978json-splitter @@ -1,4 +1,4 @@ -#!/usr/bin/with-contenv bash +#!/command/with-contenv bash # shellcheck shell=bash set -eo pipefail diff --git a/rootfs/etc/services.d/rbfeeder/run b/rootfs/etc/s6-overlay/scripts/rbfeeder similarity index 96% rename from rootfs/etc/services.d/rbfeeder/run rename to rootfs/etc/s6-overlay/scripts/rbfeeder index 26eb8b4..168acec 100755 --- a/rootfs/etc/services.d/rbfeeder/run +++ b/rootfs/etc/s6-overlay/scripts/rbfeeder @@ -1,4 +1,4 @@ -#!/usr/bin/with-contenv bash +#!/command/with-contenv bash #shellcheck shell=bash #shellcheck disable=SC2016 diff --git a/rootfs/etc/services.d/rbfeeder/log/run b/rootfs/etc/s6-overlay/scripts/rbfeeder-log similarity index 100% rename from rootfs/etc/services.d/rbfeeder/log/run rename to rootfs/etc/s6-overlay/scripts/rbfeeder-log diff --git a/rootfs/etc/services.d/stats/run b/rootfs/etc/s6-overlay/scripts/stats similarity index 97% rename from rootfs/etc/services.d/stats/run rename to rootfs/etc/s6-overlay/scripts/stats index 4d0b7c8..90bcf87 100755 --- a/rootfs/etc/services.d/stats/run +++ b/rootfs/etc/s6-overlay/scripts/stats @@ -1,4 +1,4 @@ -#!/usr/bin/with-contenv bash +#!/command/with-contenv bash #shellcheck shell=bash sleep $((STATS_INTERVAL_MINUTES * 60)) diff --git a/rootfs/etc/services.d.disabled/cpu-serial-workaround-checker/run b/rootfs/etc/services.d.disabled/cpu-serial-workaround-checker/run deleted file mode 100755 index 2aec387..0000000 --- a/rootfs/etc/services.d.disabled/cpu-serial-workaround-checker/run +++ /dev/null @@ -1,18 +0,0 @@ -#!/usr/bin/with-contenv bash -#shellcheck shell=bash -#shellcheck disable=SC2016 - -sleep 10 - -if tail -20 /var/log/rbfeeder.log | grep "CPU Serial empty" > /dev/null 2>&1; then - echo "" - echo "************ ATTENTION! ************" - echo "" - echo "In order to fix the 'CPU Serial empty' issue you are experiencing," - echo "please see: https://github.com/mikenye/docker-radarbox/blob/master/README.md#workaround-for-cpu-serial" - echo "" - echo "************************************" - echo "" -fi - -sleep 50