Sorry for another email but this is what it looks like now - RUN sudo adduser --shell $USERSHELLPATH --disabled-password $USERNAME && \ However, I am still running into the same problem.
Thanks, Ishaan On Thu, Aug 4, 2022 at 10:53 PM Dan Ritter <d...@randomstring.org> wrote: > Ishaan Mahajan wrote: > > Hi, > > > > This is the line I have got - RUN sudo adduser --shell $USERSHELLPATH > > --disabled-password --gecos "" $USERNAME && \ > > echo "$USERNAME ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/$USERNAME && \ > > chmod 0440 /etc/sudoers.d/USERNAME > > However, I keep getting the error, > > adduser: Only one or two names allowed.-- > > How do I get around this? > > sudo adduser --shell $USERSHELLPATH --disabled-password --gecos "" > $USERNAME > > That's your first command line. --gecos expects a value. You are > literally supplying no value. > > Why don't you leave the --gecos "" out entirely, if you aren't > going to populate it with a human-readable name? > > -dsr- > > -- Have a great day ahead! Best, Ishaan Mahajan