ansible/roles/autofs/files/usercache.sh
Timo Makinen b317e5b12e autofs: Move users .cache directory out from home direcotry
No need to store users local .cache directory on NFS home directories.
Use tmpfs which is much faster.
2020-11-13 18:35:28 +00:00

6 lines
223 B
Bash

if [ $UID -gt 999 ] && [ "`/usr/bin/id -gn`" = "`/usr/bin/id -un`" ]; then
export XDG_CACHE_HOME="$XDG_RUNTIME_DIR/.cache"
if [ ! -d "$XDG_CACHE_HOME" ] ; then
install -d -m 0700 "$XDG_CACHE_HOME"
fi
fi