Skip to content

Instantly share code, notes, and snippets.

@iandark
Created April 1, 2025 12:43
Show Gist options
  • Select an option

  • Save iandark/7788dc80b6005102a5b9715f1cc308d5 to your computer and use it in GitHub Desktop.

Select an option

Save iandark/7788dc80b6005102a5b9715f1cc308d5 to your computer and use it in GitHub Desktop.
Add User to Sudoers in Debian
1 - Adding a User to the sudo Group
The easiest way to give a user sudo access is to add them to the sudo group. By default, Debian is configured in a way that members of the sudo group are permitted to use the sudo command.
sudo usermod -aG sudo username
Replace username with the name of the user you want to grant sudo privileges.
2 - Verify the User is Part of the sudo Group
To ensure the user has been added to the group, you can use the groups command:
groups username
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment