From 26f54c0770e04f5d9f1388f1f7fd9c35926b1110 Mon Sep 17 00:00:00 2001 From: hanez Date: Sun, 8 Jun 2025 04:05:24 +0200 Subject: [PATCH] Wuhuuu... --- Dockerfile | 11 +++++++---- README.md | 13 ++++++------- 2 files changed, 13 insertions(+), 11 deletions(-) diff --git a/Dockerfile b/Dockerfile index dfdd652..c682323 100644 --- a/Dockerfile +++ b/Dockerfile @@ -13,7 +13,8 @@ WORKDIR /root RUN apk add --no-cache alpine-sdk ca-certificates perl # Install Rust (Copied from the official Rust Dockerfile) -RUN set -eux; \ +RUN \ + set -eux; \ apkArch="$(apk --print-arch)"; \ case "$apkArch" in \ x86_64) rustArch='x86_64-unknown-linux-musl'; rustupSha256='e6599a1c7be58a2d8eaca66a80e0dc006d87bbcf780a58b7343d6e14c1605cb2' ;; \ @@ -35,14 +36,16 @@ RUN set -eux; \ # ... # Setup environment -RUN apk update; \ +RUN \ + apk update; \ apk upgrade --available; \ apk add --no-cache bash byobu helix mc openssh shadow tmux vim zsh zsh-vcs neovim -RUN chsh -s /bin/zsh root; \ +RUN \ + chsh -s /bin/zsh root; \ useradd -M -u 1000 -U -s /bin/zsh -d /home/hanez hanez; \ useradd -M -u 1001 -U -s /bin/bash -d /home/one one; \ - useradd -M -u 1002 -U -s /bin/zsh -d /home/two two + useradd -M -u 1002 -U -s /bin/ash -d /home/two two # This is obsolete since I use docker-compose for managing the container ENTRYPOINT ["bash"] diff --git a/README.md b/README.md index 2972737..b43a3d8 100644 --- a/README.md +++ b/README.md @@ -44,6 +44,12 @@ I manage these Git based $HOME directories/repositories outside of the container If you do not configure your $HOME directories here, the container creates missing configuration files. +### Create SSH key file + +Create a private key without a password. + + ssh-keygen -N "" -f home/$USER/.ssh/id_rsa + ## Using docker compose docker compose build @@ -52,10 +58,3 @@ If you do not configure your $HOME directories here, the container creates missi You can stop the container by executing "exit" or by hiting ctrl+c when attached. You can always detache the container when hiting ctrl+p and then ctrl+q. This is useful if you have a screen or a tmux session runningin your container, or maybe some other applications. -## Using the Dockerfile only (less comfortable and without shared directories) - -I recommend not to do it this way! You have been warned! - - docker build -t rusty . - docker run -it --entrypoint /bin/bash rusty -