Guest User

Untitled

a guest
Jun 18th, 2018
142
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.54 KB | None | 0 0
  1. RUN apk update &&
  2. apk add bash git openssh rsync augeas &&
  3. deluser $(getent passwd 33 | cut -d: -f1) &&
  4. delgroup $(getent group 33 | cut -d: -f1) 2>/dev/null || true &&
  5. mkdir -p ~root/.ssh /etc/authorized_keys && chmod 700 ~root/.ssh/ &&
  6. augtool 'set /files/etc/ssh/sshd_config/AuthorizedKeysFile ".ssh/authorized_keys /etc/authorized_keys/%u"' &&
  7. echo -e "Port 22n" >> /etc/ssh/sshd_config &&
  8. cp -a /etc/ssh /etc/ssh.cache &&
  9. rm -rf /var/cache/apk/*
  10.  
  11. EXPOSE 22
  12.  
  13. COPY docker-entrypoint.sh /docker-entrypoint.sh
Add Comment
Please, Sign In to add comment