title: "groupadd: Command not found" in docker container even though I install it and I am root
body: <p>I have the below Dockerfile which I want to build. It's basically just the normal jboss/wildfly base image, but built with amazonlinux instead of centOS.</p>
  
  <p>The build error's out with the line "groupadd: Command not found"</p>
  
  <p>After this happened the first time I added the "epel" repo and tried installing it manually as you can see in the first RUN instruction. I have read a few forums and seems like sometimes you get that error message when you're not running as root. I did a "whoami" and I am running as root, so it shouldn't be an issue.</p>
  
  <p>Anyone got any idea why I'm still getting an error?</p>
  
  <pre><code>FROM amazonlinux:2017.03
  
  # Install packages necessary to run EAP
  RUN yum-config-manager --enable epel &amp;&amp; yum update -y &amp;&amp; yum -y install      groupadd xmlstarlet saxon augeas bsdtar unzip &amp;&amp; yum clean all
  
  # Create a user and group used to launch processes
  # The user ID 1000 is the default for the first "regular" user on Fedora/RHEL,
  # so there is a high chance that this ID will be equal to the current user
  # making it easier to use volumes (no permission issues)
  RUN groupadd -r jboss -g 1000 &amp;&amp; useradd -u 1000 -r -g jboss -m -d /opt/jboss -s /sbin/nologin -c "JBoss user" jboss &amp;&amp; \
  chmod 755 /opt/jboss
  
  # Set the working directory to jboss' user home directory
  WORKDIR /opt/jboss
  
  # Specify the user which should be used to execute all commands below
  USER jboss
  </code></pre>
  
  <p>Thanks in advance!</p>