diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-15 20:46:56 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-15 20:46:56 +0000 |
commit | 2dd01f6cc0c6333b58c3e77f3d8a3dca116a1c8b (patch) | |
tree | 96185c3fd8772392c9989835f1b9954b5aadb9d8 /debian/login.postinst | |
parent | Adding upstream version 1:4.13+dfsg1. (diff) | |
download | shadow-2dd01f6cc0c6333b58c3e77f3d8a3dca116a1c8b.tar.xz shadow-2dd01f6cc0c6333b58c3e77f3d8a3dca116a1c8b.zip |
Adding debian version 1:4.13+dfsg1-4.debian/1%4.13+dfsg1-4
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian/login.postinst')
-rw-r--r-- | debian/login.postinst | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/debian/login.postinst b/debian/login.postinst new file mode 100644 index 0000000..2261e1b --- /dev/null +++ b/debian/login.postinst @@ -0,0 +1,30 @@ +#!/bin/sh + +set -e + + +if [ "$1" = "configure" ]; then + # Install faillog during initial installs only + if [ "$2" = "" ] && [ ! -f "$DPKG_ROOT/var/log/faillog" ] ; then + touch "$DPKG_ROOT/var/log/faillog" + chown 0:0 "$DPKG_ROOT/var/log/faillog" + chmod 644 "$DPKG_ROOT/var/log/faillog" + fi + + # Create subuid/subgid if missing + if [ ! -e "$DPKG_ROOT/etc/subuid" ]; then + touch "$DPKG_ROOT/etc/subuid" + chown 0:0 "$DPKG_ROOT/etc/subuid" + chmod 644 "$DPKG_ROOT/etc/subuid" + fi + + if [ ! -e "$DPKG_ROOT/etc/subgid" ]; then + touch "$DPKG_ROOT/etc/subgid" + chown 0:0 "$DPKG_ROOT/etc/subgid" + chmod 644 "$DPKG_ROOT/etc/subgid" + fi +fi + +#DEBHELPER# + +exit 0 |