diff options
author | Omar Vega Ramos <ovruni@gnu.org.pe> | 2021-05-29 19:30:30 -0500 |
---|---|---|
committer | Omar Vega Ramos <ovruni@gnu.org.pe> | 2021-05-29 19:30:30 -0500 |
commit | a07e01dc2f6ff50730c1bc5534e0c7f649a23fd8 (patch) | |
tree | 9ee90a99792686befaca90d6d8c9a49419b8e740 /libre/systemd/systemd-hook | |
parent | c58431561db196368bdaffcbdc7fb02c9f91b133 (diff) | |
download | abslibre-a07e01dc2f6ff50730c1bc5534e0c7f649a23fd8.tar.gz abslibre-a07e01dc2f6ff50730c1bc5534e0c7f649a23fd8.tar.bz2 abslibre-a07e01dc2f6ff50730c1bc5534e0c7f649a23fd8.zip |
systemd-248.3-2.parabola1: updating version
Diffstat (limited to 'libre/systemd/systemd-hook')
-rw-r--r-- | libre/systemd/systemd-hook | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libre/systemd/systemd-hook b/libre/systemd/systemd-hook index 00252cf79..d40fad3b9 100644 --- a/libre/systemd/systemd-hook +++ b/libre/systemd/systemd-hook @@ -1,6 +1,14 @@ #!/bin/sh -e +is_chrooted() { + if systemd-detect-virt --chroot; then + echo >&2 " Skipped: Running in chroot." + exit 0 + fi +} + systemd_live() { + is_chrooted if [ ! -d /run/systemd/system ]; then echo >&2 " Skipped: Current root is not booted." exit 0 |