From 7beb37b14dfb8465a8a36722b0d6afe3b0643263 Mon Sep 17 00:00:00 2001 From: Matthias Wirth Date: Wed, 20 Mar 2024 13:41:33 +0000 Subject: [PATCH 1/4] replace 02-remove-prometheus-data 02-remove-prometheus-data deletes /run/readsb-prometheus.prom when the container stops As this file is created by readsb, remove it instead in a finish script for readsb which is run when the readsb service is stopped --- .../dependencies.d/01-print-container-version | 0 .../etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/down | 2 -- .../etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/type | 1 - rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/up | 2 -- .../dependencies.d/02-remove-prometheus-data | 0 .../50-store-uuid/dependencies.d/02-remove-prometheus-data | 0 .../dependencies.d/02-remove-prometheus-data | 0 .../adsbx-stats/dependencies.d/02-remove-prometheus-data | 0 .../mlat-client/dependencies.d/02-remove-prometheus-data | 0 .../mlathub/dependencies.d/02-remove-prometheus-data | 0 .../dependencies.d/02-remove-prometheus-data | 0 .../readsb/dependencies.d/02-remove-prometheus-data | 0 rootfs/etc/s6-overlay/s6-rc.d/readsb/finish | 2 ++ .../s6-rc.d/user/contents.d/02-remove-prometheus-data | 0 .../etc/s6-overlay/scripts/02-remove-prometheus-data-init | 7 ------- .../{02-remove-prometheus-data-down => readsb-finish} | 0 16 files changed, 2 insertions(+), 12 deletions(-) delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/dependencies.d/01-print-container-version delete mode 100755 rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/down delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/type delete mode 100755 rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/up delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/dependencies.d/02-remove-prometheus-data delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/dependencies.d/02-remove-prometheus-data delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/dependencies.d/02-remove-prometheus-data delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/adsbx-stats/dependencies.d/02-remove-prometheus-data delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/02-remove-prometheus-data delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/02-remove-prometheus-data delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/02-remove-prometheus-data delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/02-remove-prometheus-data create mode 100755 rootfs/etc/s6-overlay/s6-rc.d/readsb/finish delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/02-remove-prometheus-data delete mode 100755 rootfs/etc/s6-overlay/scripts/02-remove-prometheus-data-init rename rootfs/etc/s6-overlay/scripts/{02-remove-prometheus-data-down => readsb-finish} (100%) diff --git a/rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/dependencies.d/01-print-container-version b/rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/dependencies.d/01-print-container-version deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/down b/rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/down deleted file mode 100755 index 12913e6..0000000 --- a/rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/down +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -exec /etc/s6-overlay/scripts/02-remove-prometheus-data-down diff --git a/rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/type b/rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/type deleted file mode 100644 index bdd22a1..0000000 --- a/rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/type +++ /dev/null @@ -1 +0,0 @@ -oneshot diff --git a/rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/up b/rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/up deleted file mode 100755 index 7bdc184..0000000 --- a/rootfs/etc/s6-overlay/s6-rc.d/02-remove-prometheus-data/up +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -exec /etc/s6-overlay/scripts/02-remove-prometheus-data-init diff --git a/rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/dependencies.d/02-remove-prometheus-data b/rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/dependencies.d/02-remove-prometheus-data deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/dependencies.d/02-remove-prometheus-data b/rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/dependencies.d/02-remove-prometheus-data deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/dependencies.d/02-remove-prometheus-data b/rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/dependencies.d/02-remove-prometheus-data deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/adsbx-stats/dependencies.d/02-remove-prometheus-data b/rootfs/etc/s6-overlay/s6-rc.d/adsbx-stats/dependencies.d/02-remove-prometheus-data deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/02-remove-prometheus-data b/rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/02-remove-prometheus-data deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/02-remove-prometheus-data b/rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/02-remove-prometheus-data deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/02-remove-prometheus-data b/rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/02-remove-prometheus-data deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/02-remove-prometheus-data b/rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/02-remove-prometheus-data deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/readsb/finish b/rootfs/etc/s6-overlay/s6-rc.d/readsb/finish new file mode 100755 index 0000000..23065e6 --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/readsb/finish @@ -0,0 +1,2 @@ +#!/bin/sh +exec /etc/s6-overlay/scripts/readsb-finish diff --git a/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/02-remove-prometheus-data b/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/02-remove-prometheus-data deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/scripts/02-remove-prometheus-data-init b/rootfs/etc/s6-overlay/scripts/02-remove-prometheus-data-init deleted file mode 100755 index 7798ea9..0000000 --- a/rootfs/etc/s6-overlay/scripts/02-remove-prometheus-data-init +++ /dev/null @@ -1,7 +0,0 @@ -#!/command/with-contenv bash -# shellcheck shell=bash disable=SC1091 - -# dummy file to allow for graceful shutdown -# I don't know if we need this, but it won't hurt anything - -exit 0 diff --git a/rootfs/etc/s6-overlay/scripts/02-remove-prometheus-data-down b/rootfs/etc/s6-overlay/scripts/readsb-finish similarity index 100% rename from rootfs/etc/s6-overlay/scripts/02-remove-prometheus-data-down rename to rootfs/etc/s6-overlay/scripts/readsb-finish From 916f045f4caa175d9b82c0f8e08d145b3887ddcc Mon Sep 17 00:00:00 2001 From: Matthias Wirth Date: Wed, 20 Mar 2024 15:04:15 +0000 Subject: [PATCH 2/4] replace 03-remove-mlathub-up 03-remove-mlathub-up deletes /run/mlathub_up when the container stops As this file is created by the mlat-client service, remove it instead in a finish script for mlat-client which is run when the mlat-client service is stopped --- .../dependencies.d/01-print-container-version | 0 .../s6-rc.d/03-remove-mlathub-up/down | 2 -- .../s6-rc.d/03-remove-mlathub-up/type | 1 - .../s6-rc.d/03-remove-mlathub-up/up | 2 -- .../dependencies.d/03-remove-mlathub-up | 0 .../dependencies.d/03-remove-mlathub-up | 0 .../dependencies.d/03-remove-mlathub-up | 0 .../dependencies.d/03-remove-mlathub-up | 0 .../etc/s6-overlay/s6-rc.d/mlat-client/finish | 2 ++ .../dependencies.d/03-remove-mlathub-up | 0 .../dependencies.d/03-remove-mlathub-up | 0 .../dependencies.d/03-remove-mlathub-up | 0 .../user/contents.d/03-remove-mlathub-up | 0 .../scripts/03-remove-mlathub-up-init | 21 ------------------- ...ove-mlathub-up-down => mlat-client-finish} | 0 15 files changed, 2 insertions(+), 26 deletions(-) delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/dependencies.d/01-print-container-version delete mode 100755 rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/down delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/type delete mode 100755 rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/up delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/dependencies.d/03-remove-mlathub-up delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/dependencies.d/03-remove-mlathub-up delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/adsbx-stats/dependencies.d/03-remove-mlathub-up delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/03-remove-mlathub-up create mode 100755 rootfs/etc/s6-overlay/s6-rc.d/mlat-client/finish delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/03-remove-mlathub-up delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/03-remove-mlathub-up delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/03-remove-mlathub-up delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/03-remove-mlathub-up delete mode 100755 rootfs/etc/s6-overlay/scripts/03-remove-mlathub-up-init rename rootfs/etc/s6-overlay/scripts/{03-remove-mlathub-up-down => mlat-client-finish} (100%) diff --git a/rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/dependencies.d/01-print-container-version b/rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/dependencies.d/01-print-container-version deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/down b/rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/down deleted file mode 100755 index 11cbcdd..0000000 --- a/rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/down +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -exec /etc/s6-overlay/scripts/03-remove-mlathub-up-down diff --git a/rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/type b/rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/type deleted file mode 100644 index bdd22a1..0000000 --- a/rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/type +++ /dev/null @@ -1 +0,0 @@ -oneshot diff --git a/rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/up b/rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/up deleted file mode 100755 index 4c24c2e..0000000 --- a/rootfs/etc/s6-overlay/s6-rc.d/03-remove-mlathub-up/up +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -exec /etc/s6-overlay/scripts/03-remove-mlathub-up-init diff --git a/rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/dependencies.d/03-remove-mlathub-up b/rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/dependencies.d/03-remove-mlathub-up deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/dependencies.d/03-remove-mlathub-up b/rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/dependencies.d/03-remove-mlathub-up deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/adsbx-stats/dependencies.d/03-remove-mlathub-up b/rootfs/etc/s6-overlay/s6-rc.d/adsbx-stats/dependencies.d/03-remove-mlathub-up deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/03-remove-mlathub-up b/rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/03-remove-mlathub-up deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/mlat-client/finish b/rootfs/etc/s6-overlay/s6-rc.d/mlat-client/finish new file mode 100755 index 0000000..e61031a --- /dev/null +++ b/rootfs/etc/s6-overlay/s6-rc.d/mlat-client/finish @@ -0,0 +1,2 @@ +#!/bin/sh +exec /etc/s6-overlay/scripts/mlat-client-finish diff --git a/rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/03-remove-mlathub-up b/rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/03-remove-mlathub-up deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/03-remove-mlathub-up b/rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/03-remove-mlathub-up deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/03-remove-mlathub-up b/rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/03-remove-mlathub-up deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/03-remove-mlathub-up b/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/03-remove-mlathub-up deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/scripts/03-remove-mlathub-up-init b/rootfs/etc/s6-overlay/scripts/03-remove-mlathub-up-init deleted file mode 100755 index e66b2d2..0000000 --- a/rootfs/etc/s6-overlay/scripts/03-remove-mlathub-up-init +++ /dev/null @@ -1,21 +0,0 @@ -#!/command/with-contenv bash -#shellcheck shell=bash disable=SC2015,SC1091 - -# Remove MLATHub Up -#--------------------------------------------------------------------------------------------- -# Copyright (C) 2023, Ramon F. Kolb (kx1t) -# -# This program is free software: you can redistribute it and/or modify it -# under the terms of the GNU General Public License as published by the -# Free Software Foundation, either version 3 of the License, or (at your option) -# any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License along with this program. -# If not, see . -#--------------------------------------------------------------------------------------------- - -exit 0 diff --git a/rootfs/etc/s6-overlay/scripts/03-remove-mlathub-up-down b/rootfs/etc/s6-overlay/scripts/mlat-client-finish similarity index 100% rename from rootfs/etc/s6-overlay/scripts/03-remove-mlathub-up-down rename to rootfs/etc/s6-overlay/scripts/mlat-client-finish From 66777d5f99889a8297d1798e9473cd134322c2dd Mon Sep 17 00:00:00 2001 From: Matthias Wirth Date: Wed, 20 Mar 2024 15:11:47 +0000 Subject: [PATCH 3/4] Simplify startup and dependencies Move startup scripts to /etc/s6-overlay/startup.d oneshot service named "startup" from underlying image executes all files in /etc/s6-overlay/startup.d in alphabetical order Remove various oneshot scripts from longrun service dependencies Add "startup" oneshot service to longrun service dependencies --- rootfs/etc/s6-overlay/s6-rc.d/01-print-container-version/type | 1 - rootfs/etc/s6-overlay/s6-rc.d/01-print-container-version/up | 2 -- rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/type | 1 - rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/up | 2 -- rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/type | 1 - rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/up | 2 -- .../s6-rc.d/adsbx-stats/dependencies.d/60-mlathub-prep | 0 .../dependencies.d/startup} | 0 .../mlat-client/dependencies.d/01-print-container-version | 0 .../s6-overlay/s6-rc.d/mlat-client/dependencies.d/50-store-uuid | 0 .../s6-rc.d/mlat-client/dependencies.d/60-mlathub-prep | 0 .../dependencies.d/startup} | 0 .../s6-rc.d/mlathub/dependencies.d/01-print-container-version | 0 .../etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/50-store-uuid | 0 .../s6-overlay/s6-rc.d/mlathub/dependencies.d/60-mlathub-prep | 0 .../50-store-uuid => mlathub/dependencies.d/startup} | 0 .../prometheus-readsb/dependencies.d/01-print-container-version | 0 .../s6-rc.d/prometheus-readsb/dependencies.d/50-store-uuid | 0 .../s6-rc.d/prometheus-readsb/dependencies.d/60-mlathub-prep | 0 .../dependencies.d/startup} | 0 .../s6-rc.d/readsb/dependencies.d/01-print-container-version | 0 .../etc/s6-overlay/s6-rc.d/readsb/dependencies.d/50-store-uuid | 0 .../s6-overlay/s6-rc.d/readsb/dependencies.d/60-mlathub-prep | 0 .../50-store-uuid => readsb/dependencies.d/startup} | 0 .../s6-rc.d/user/contents.d/01-print-container-version | 0 rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/50-store-uuid | 0 rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/60-mlathub-prep | 0 .../{scripts => startup.d}/01-print-container-version | 0 rootfs/etc/s6-overlay/{scripts => startup.d}/50-store-uuid | 0 rootfs/etc/s6-overlay/{scripts => startup.d}/60-mlathub-prep | 0 30 files changed, 9 deletions(-) delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/01-print-container-version/type delete mode 100755 rootfs/etc/s6-overlay/s6-rc.d/01-print-container-version/up delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/type delete mode 100755 rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/up delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/type delete mode 100755 rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/up delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/adsbx-stats/dependencies.d/60-mlathub-prep rename rootfs/etc/s6-overlay/s6-rc.d/{50-store-uuid/dependencies.d/01-print-container-version => adsbx-stats/dependencies.d/startup} (100%) delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/01-print-container-version delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/50-store-uuid delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/60-mlathub-prep rename rootfs/etc/s6-overlay/s6-rc.d/{60-mlathub-prep/dependencies.d/01-print-container-version => mlat-client/dependencies.d/startup} (100%) delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/01-print-container-version delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/50-store-uuid delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/60-mlathub-prep rename rootfs/etc/s6-overlay/s6-rc.d/{60-mlathub-prep/dependencies.d/50-store-uuid => mlathub/dependencies.d/startup} (100%) delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/01-print-container-version delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/50-store-uuid delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/60-mlathub-prep rename rootfs/etc/s6-overlay/s6-rc.d/{adsbx-stats/dependencies.d/01-print-container-version => prometheus-readsb/dependencies.d/startup} (100%) delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/01-print-container-version delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/50-store-uuid delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/60-mlathub-prep rename rootfs/etc/s6-overlay/s6-rc.d/{adsbx-stats/dependencies.d/50-store-uuid => readsb/dependencies.d/startup} (100%) delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/01-print-container-version delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/50-store-uuid delete mode 100644 rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/60-mlathub-prep rename rootfs/etc/s6-overlay/{scripts => startup.d}/01-print-container-version (100%) rename rootfs/etc/s6-overlay/{scripts => startup.d}/50-store-uuid (100%) rename rootfs/etc/s6-overlay/{scripts => startup.d}/60-mlathub-prep (100%) diff --git a/rootfs/etc/s6-overlay/s6-rc.d/01-print-container-version/type b/rootfs/etc/s6-overlay/s6-rc.d/01-print-container-version/type deleted file mode 100644 index bdd22a1..0000000 --- a/rootfs/etc/s6-overlay/s6-rc.d/01-print-container-version/type +++ /dev/null @@ -1 +0,0 @@ -oneshot diff --git a/rootfs/etc/s6-overlay/s6-rc.d/01-print-container-version/up b/rootfs/etc/s6-overlay/s6-rc.d/01-print-container-version/up deleted file mode 100755 index 984224c..0000000 --- a/rootfs/etc/s6-overlay/s6-rc.d/01-print-container-version/up +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -exec /etc/s6-overlay/scripts/01-print-container-version diff --git a/rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/type b/rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/type deleted file mode 100644 index bdd22a1..0000000 --- a/rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/type +++ /dev/null @@ -1 +0,0 @@ -oneshot diff --git a/rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/up b/rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/up deleted file mode 100755 index 2f8e03c..0000000 --- a/rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/up +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -exec /etc/s6-overlay/scripts/50-store-uuid diff --git a/rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/type b/rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/type deleted file mode 100644 index bdd22a1..0000000 --- a/rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/type +++ /dev/null @@ -1 +0,0 @@ -oneshot diff --git a/rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/up b/rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/up deleted file mode 100755 index fe58c47..0000000 --- a/rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/up +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -exec /etc/s6-overlay/scripts/60-mlathub-prep diff --git a/rootfs/etc/s6-overlay/s6-rc.d/adsbx-stats/dependencies.d/60-mlathub-prep b/rootfs/etc/s6-overlay/s6-rc.d/adsbx-stats/dependencies.d/60-mlathub-prep deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/dependencies.d/01-print-container-version b/rootfs/etc/s6-overlay/s6-rc.d/adsbx-stats/dependencies.d/startup similarity index 100% rename from rootfs/etc/s6-overlay/s6-rc.d/50-store-uuid/dependencies.d/01-print-container-version rename to rootfs/etc/s6-overlay/s6-rc.d/adsbx-stats/dependencies.d/startup diff --git a/rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/01-print-container-version b/rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/01-print-container-version deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/50-store-uuid b/rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/50-store-uuid deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/60-mlathub-prep b/rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/60-mlathub-prep deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/dependencies.d/01-print-container-version b/rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/startup similarity index 100% rename from rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/dependencies.d/01-print-container-version rename to rootfs/etc/s6-overlay/s6-rc.d/mlat-client/dependencies.d/startup diff --git a/rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/01-print-container-version b/rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/01-print-container-version deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/50-store-uuid b/rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/50-store-uuid deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/60-mlathub-prep b/rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/60-mlathub-prep deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/dependencies.d/50-store-uuid b/rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/startup similarity index 100% rename from rootfs/etc/s6-overlay/s6-rc.d/60-mlathub-prep/dependencies.d/50-store-uuid rename to rootfs/etc/s6-overlay/s6-rc.d/mlathub/dependencies.d/startup diff --git a/rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/01-print-container-version b/rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/01-print-container-version deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/50-store-uuid b/rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/50-store-uuid deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/60-mlathub-prep b/rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/60-mlathub-prep deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/adsbx-stats/dependencies.d/01-print-container-version b/rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/startup similarity index 100% rename from rootfs/etc/s6-overlay/s6-rc.d/adsbx-stats/dependencies.d/01-print-container-version rename to rootfs/etc/s6-overlay/s6-rc.d/prometheus-readsb/dependencies.d/startup diff --git a/rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/01-print-container-version b/rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/01-print-container-version deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/50-store-uuid b/rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/50-store-uuid deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/60-mlathub-prep b/rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/60-mlathub-prep deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/adsbx-stats/dependencies.d/50-store-uuid b/rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/startup similarity index 100% rename from rootfs/etc/s6-overlay/s6-rc.d/adsbx-stats/dependencies.d/50-store-uuid rename to rootfs/etc/s6-overlay/s6-rc.d/readsb/dependencies.d/startup diff --git a/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/01-print-container-version b/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/01-print-container-version deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/50-store-uuid b/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/50-store-uuid deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/60-mlathub-prep b/rootfs/etc/s6-overlay/s6-rc.d/user/contents.d/60-mlathub-prep deleted file mode 100644 index e69de29..0000000 diff --git a/rootfs/etc/s6-overlay/scripts/01-print-container-version b/rootfs/etc/s6-overlay/startup.d/01-print-container-version similarity index 100% rename from rootfs/etc/s6-overlay/scripts/01-print-container-version rename to rootfs/etc/s6-overlay/startup.d/01-print-container-version diff --git a/rootfs/etc/s6-overlay/scripts/50-store-uuid b/rootfs/etc/s6-overlay/startup.d/50-store-uuid similarity index 100% rename from rootfs/etc/s6-overlay/scripts/50-store-uuid rename to rootfs/etc/s6-overlay/startup.d/50-store-uuid diff --git a/rootfs/etc/s6-overlay/scripts/60-mlathub-prep b/rootfs/etc/s6-overlay/startup.d/60-mlathub-prep similarity index 100% rename from rootfs/etc/s6-overlay/scripts/60-mlathub-prep rename to rootfs/etc/s6-overlay/startup.d/60-mlathub-prep From ab0e9a3e546815a1298574cebfaca24fd06f6589 Mon Sep 17 00:00:00 2001 From: Matthias Wirth Date: Wed, 20 Mar 2024 15:21:44 +0000 Subject: [PATCH 4/4] remove double s6wrap for container-version --- rootfs/etc/s6-overlay/startup.d/01-print-container-version | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rootfs/etc/s6-overlay/startup.d/01-print-container-version b/rootfs/etc/s6-overlay/startup.d/01-print-container-version index a1d01c5..ef0fccc 100755 --- a/rootfs/etc/s6-overlay/startup.d/01-print-container-version +++ b/rootfs/etc/s6-overlay/startup.d/01-print-container-version @@ -20,4 +20,4 @@ source /scripts/common # If not, see . #--------------------------------------------------------------------------------------------- -[[ -f /.CONTAINER_VERSION ]] && s6wrap --quiet --prepend=01-print-container-version --timestamps --args echo "Container Version: $(cat /.CONTAINER_VERSION), build date $(stat -c '%y' /.CONTAINER_VERSION |sed 's|\(.*\)\.[0-9]* \(.*\)|\1 \2|g')" || true +[[ -f /.CONTAINER_VERSION ]] && echo "Container Version: $(cat /.CONTAINER_VERSION), build date $(stat -c '%y' /.CONTAINER_VERSION |sed 's|\(.*\)\.[0-9]* \(.*\)|\1 \2|g')" || true