Skip to content

Commit

Permalink
feat(basic remote server): add dockerfile and entrypoint script
Browse files Browse the repository at this point in the history
* setup basic ubuntu image to a minimal remote server
  • Loading branch information
tmicka23 committed Apr 14, 2024
0 parents commit e4a1255
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 0 deletions.
17 changes: 17 additions & 0 deletions dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
FROM ubuntu:latest

RUN apt-get update -y \
&& apt-get install -y openssh-server git vim htop \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*

RUN yes | unminimize

RUN echo "root:demo" | chpasswd
RUN echo "PermitRootLogin Yes" >> /etc/ssh/sshd_config

COPY entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh

CMD ["bash"]
ENTRYPOINT ["/entrypoint.sh"]
7 changes: 7 additions & 0 deletions entrypoint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/usr/bin/env bash

service --status-all
service ssh restart
service --status-all

exec "$@"

0 comments on commit e4a1255

Please sign in to comment.