On Fri, May 12, 2023 at 07:27:25PM +0800, Tom Reed wrote: > Hello > > what's the right way to add an user to run sudo without password? > I have to edit /etc/sudoers by manual. But I don't think it's a grace way. > > Thanks. > Tom >
As others have said: sudo is *designed* this way - you have to prove your identity once and then you get some time in the session before you would have to reinput a password. If you don't appreciate why this is important, I would respectfully suggest that you go and read up on computer security. It is also worth reading up on restrictions on commands and forced commands: you can create a group such that users can only perform one command. For example, backupusers as a group and then configure sudo to *only* allow the members of that group to use a backup command. Hope this helps, Andy Cater