Dockerfile 920 B

1234567891011121314151617
  1. FROM rancher/os-base
  2. COPY console.sh docker-init update-ssh-keys rancheros-install /usr/sbin/
  3. COPY build/lsb-release /etc/
  4. RUN sed -i 's/rancher:!/rancher:*/g' /etc/shadow && \
  5. sed -i 's/docker:!/docker:*/g' /etc/shadow && \
  6. sed -i 's/#ClientAliveInterval 0/ClientAliveInterval 180/g' /etc/ssh/sshd_config && \
  7. echo '## allow password less for rancher user' >> /etc/sudoers && \
  8. echo 'rancher ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers && \
  9. echo '## allow password less for docker user' >> /etc/sudoers && \
  10. echo 'docker ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers && \
  11. ln -sf /usr/bin/docker.dist /usr/bin/docker && \
  12. ln -sf /usr/bin/docker-containerd.dist /usr/bin/docker-containerd && \
  13. ln -sf /usr/bin/docker-containerd-shim.dist /usr/bin/docker-containerd-shim && \
  14. ln -sf /usr/bin/docker-runc.dist /usr/bin/docker-runc
  15. COPY prompt.sh /etc/profile.d/
  16. CMD ["/usr/sbin/console.sh"]