Initial commit
This commit is contained in:
17
overlay/usr/local/libexec/home-overlay.sh
Executable file
17
overlay/usr/local/libexec/home-overlay.sh
Executable file
@@ -0,0 +1,17 @@
|
||||
#!/bin/sh
|
||||
|
||||
if mountpoint -q "${HOME}"; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
upperdir="${XDG_RUNTIME_DIR}"/home/rw
|
||||
workdir="${XDG_RUNTIME_DIR}"/home/.work
|
||||
|
||||
mkdir -p "${upperdir}"
|
||||
mkdir -p "${workdir}"
|
||||
|
||||
mount overlay \
|
||||
-t overlay \
|
||||
-o lowerdir="${HOME}",upperdir="${upperdir}",workdir="${workdir}" \
|
||||
"${HOME}"
|
||||
chown "${PAM_USER}": "${HOME}"
|
||||
Reference in New Issue
Block a user