alexheretic / aurto

Arch Linux AUR tool for managing an auto-updating local 'aurto' package repository
MIT License
137 stars 9 forks source link

sudo still asks for password #75

Open bjo81 opened 2 years ago

bjo81 commented 2 years ago

As I use the wheelgroup for myself, I changed /etc/sudoers.d/50_aurto_passwordless to:

build ALL=(ALL) NOPASSWD: /usr/bin/arch-nspawn
build ALL=(ALL) NOPASSWD: /usr/bin/pacsync aurto
build ALL=(ALL) NOPASSWD:SETENV: /usr/bin/makechrootpkg

But something still want's to use another command then in the config?

[1/2] env -C /data/build/.cache/aurutils/sync/aurutils '--' 'aur' 'build' '--...to' '--root' '/var/cache/pacman/aurto' && date --rfc-3339=ns > aurutils.stamp
Running aur chroot --create --update --pacman-conf /etc/aurto/pacman-chroot.conf --makepkg-conf /etc/aurto/makepkg-chroot.conf

We trust you have received the usual lecture from the local System
Administrator. It usually boils down to these three things:

    #1) Respect the privacy of others.
    #2) Think before you type.
    #3) With great power comes great responsibility.

[sudo] password for build: 
AladW commented 2 years ago

Likely from the sudo install call https://github.com/AladW/aurutils/blob/master/lib/aur-chroot#L143

Gr3q commented 1 year ago

I have the same problem for a couple of months now.

I had some time, the file /etc/sudoers.d/50_aurto_passwordless is correct, but with the new sudo package changes there is another file.../etc/sudoers.d/99-sudo-group with the contents of:

%sudo ALL=(ALL:ALL) ALL 

This seems to make sudo ignore all configs regarding %wheel.

This is my id is someone smarter than me can tell why is this happening. What I know:

My ID: uid=1000(gr3q) gid=1000(gr3q) groups=1000(gr3q),962(autologin),974(docker),994(disk),998(wheel),1001(sudo)