diff --git a/hooks/900-cleanup-etc-var.chroot b/hooks/900-cleanup-etc-var.chroot index 048fc22..ad8d126 100755 --- a/hooks/900-cleanup-etc-var.chroot +++ b/hooks/900-cleanup-etc-var.chroot @@ -17,8 +17,14 @@ rm -rvf /etc/selinux rm -rvf /etc/binfmt.d rm /etc/gai.conf rm /etc/debian_version + +# pam stuff, move pam.d files into /usr/lib/pam.d instead of +# /etc/pam.d to allow snaps to mount their own pam.d files as well rm /etc/pam.conf +# we cannot move the common-* files, as they are expected only in /etc/pam.d +find /etc/pam.d/ -type f ! -name "common-*" -exec mv {} /usr/lib/pam.d \; + # cloud-init adds stuff here rm -rvf /etc/profile.d/Z99-cloud*