hello maybe, and list,

may be the most coherent form to do that is modifying the live-initramfs 
package, when it creates the live user

developping that idea,
add a variable in live.conf

USER_DEFAULT_GROUPS="audio cdrom dialout floppy video plugdev netdev powerdev"
export USER_DEFAULT_GROUPS
and modify the script
live-initramfs/scripts/live-bottom/10adduser

with some code like that:

user_crypted="8Ab05sVQ4LLps" # as in $(echo "live" | mkpasswd -s)
[ -n "${USER_DEFAULT_GROUPS}" ] && user_default_groups="set 
passwd/user-default-groups $(echo "${USER_DEFAULT_GROUPS}" | tr -s "," " ")"

# U6aMy0wojraho is just a blank password
chroot /root debconf-communicate -fnoninteractive live-initramfs > /dev/null << 
EOF
set passwd/make-user true
set passwd/root-password-crypted *
set passwd/user-password-crypted ${user_crypted}
set passwd/user-fullname ${USERFULLNAME}
set passwd/username ${USERNAME}
set passwd/user-uid 999
${user_default_groups}
EOF

chroot /root /usr/bin/env -i HOME="/root" \
        TERM="${TERM}" PATH="/usr/sbin:/usr/bin:/sbin:/bin" \
        /usr/lib/user-setup/user-setup-apply > /dev/null

# Clear out debconf database again to avoid confusing ubiquity later.
[ -n "${user_default_groups}" ] && user_default_groups="set 
passwd/user-default-groups audio cdrom dialout floppy video plugdev netdev 
powerdev"
chroot /root debconf-communicate -fnoninteractive live-initramfs > /dev/null << 
EOF
set passwd/make-user
set passwd/root-password-crypted
set passwd/user-password-crypted
set passwd/user-fullname
set passwd/username
set passwd/user-uid
${user_default_groups}
EOF

Don't specify the variable if you want the default user groups,
and specify all the user groups you want when changing that.

Regards,

Jordi Pujol


El Sunday 10 February 2008 18:40:23 maybeway36 va escriure:
> I am making a live CD based on debian-live, and wanted to include
> sshfs (for transferring large files over an ssh connection.) However,
> this means the live CD user must be in the "fuse" group, and I haven't
> found a way to make that happen automatically. I've tried
> chroot_local-hooks and
> chroot_local-includes/usr/share/initramfs-tools/scripts/99something,
> but to no avail.
>
> _______________________________________________
> debian-live-devel mailing list
> [email protected]
> http://lists.alioth.debian.org/mailman/listinfo/debian-live-devel


_______________________________________________
debian-live-devel mailing list
[email protected]
http://lists.alioth.debian.org/mailman/listinfo/debian-live-devel

Reply via email to