From 0a5966bed767a80161e086c9daf1e18c8e856350 Mon Sep 17 00:00:00 2001 From: amass <168062547@qq.com> Date: Mon, 7 Oct 2024 12:54:24 +0000 Subject: [PATCH] add simple image for test. --- ubuntu2404_pure.dockerfile | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 ubuntu2404_pure.dockerfile diff --git a/ubuntu2404_pure.dockerfile b/ubuntu2404_pure.dockerfile new file mode 100644 index 0000000..736d55d --- /dev/null +++ b/ubuntu2404_pure.dockerfile @@ -0,0 +1,28 @@ +FROM ubuntu:24.04 +LABEL maintainer="amass <168062547@qq.com>" +ENV DEBIAN_FRONTEND=noninteractive + +RUN sed -i 's@//.*archive.ubuntu.com@//mirrors.ustc.edu.cn@g' /etc/apt/sources.list.d/ubuntu.sources \ + && apt update \ + && apt install -y tini openssh-server + +RUN mkdir /var/run/sshd \ + && sed -i 's/#Port 22/Port 5022/' /etc/ssh/sshd_config \ + && sed -i 's/#PubkeyAuthentication yes/PubkeyAuthentication yes/' /etc/ssh/sshd_config \ + && mkdir -p /root/.ssh \ + && wget https://frp-by1.wwvvww.cn:44048/s/id_ed25519/download -O /root/.ssh/authorized_keys \ + && chmod 600 /root/.ssh/authorized_keys && chown root:root /root/.ssh/authorized_keys + +EXPOSE 5022 + + +ENV LANG=C.UTF-8 +ENV LC_ALL=C.UTF-8 +ENV TERM=xterm-256color + +ENTRYPOINT ["/usr/bin/tini", "--"] +CMD ["service", "ssh", "start", "-D"] + +# docker build --progress=tty -f ubuntu2404_pure.dockerfile -t frp-by1.wwvvww.cn:45288/ubuntu_pure:24.04 . +# docker push frp-by1.wwvvww.cn:45288/ubuntu_dev:24.04 +# docker run -it -d --rm --network host --name develop frp-by1.wwvvww.cn:45288/ubuntu_pure:24.04 \ No newline at end of file