pam_namespace_helper.in 466 B

123456789101112131415
  1. #!/bin/sh
  2. CONF=@SCONFIGDIR@/namespace.conf
  3. # Match logic of process_line(), except lines with $HOME are ignored
  4. # skip the leading white space, rip off the comments, ignore empty lines
  5. sed -e 's/^[ ]*//g' -e 's/#.*//g' -e '/.*\$HOME.*/d' -e '/^$/d' < $CONF | \
  6. while read polydir instance_prefix method uids; do
  7. if [ ! -e "$instance_prefix" ]; then
  8. echo "mkdir $instance_prefix"
  9. mkdir --parents --mode=0 -Z "$instance_prefix"
  10. fi
  11. done
  12. exit 0