Add non root user

Suggestions for features and software you would like to see in DietPi, goes here.
Post Reply
keithellis
Posts: 41
Joined: Mon May 23, 2016 2:55 pm

Add non root user

Post by keithellis »

Hi there,

I setup DietPi last night with LAMP stack and openVPN on a Raspberry Pi. So quick and easy. Thanks very much.

However I think a nice option would be to add a non-root user so the distro can be used without logging in as root for day to day stuff.

Cheers,
Keith.
User avatar
k-plan
Posts: 416
Joined: Sun Feb 28, 2016 5:28 pm

Re: Add non root user

Post by k-plan »

Hi Keith

if you need it, you can do this really simple:

Code: Select all

root@DietPi:~#  adduser Keith

root@DietPi:~#  adduser Keith sudo
If you find our project or support useful, then we’d really appreciate it if you’d consider contributing to the project however you can.
Donating is the easiest – you can use PayPal and Bitcoin.
keithellis
Posts: 41
Joined: Mon May 23, 2016 2:55 pm

Re: Add non root user

Post by keithellis »

k-plan wrote:Hi Keith

if you need it, you can do this really simple:

Code: Select all

root@DietPi:~#  adduser Keith

root@DietPi:~#  adduser Keith sudo
Thanks, yes it's not hard, I would have had to google it, its not something I do a lot. Thought it would be nice to have it as an option.

Cheers,
Keith.
scargill
Posts: 16
Joined: Sat Oct 15, 2016 11:03 pm

Re: Add non root user

Post by scargill »

As the program is called dietPI - it would make sense if the default non-root user (with sudo access) were PI - that would help when using scripts meant for the Pi.
jarjargeek
Posts: 3
Joined: Wed Mar 08, 2017 1:18 pm

Re: Add non root user

Post by jarjargeek »

I also had to do this to get sudo on my 'user

chown root:root /usr/bin/sudo && chmod 4755 /usr/bin/sudo'
Post Reply