Sign inSign up

deepaksorthiya/awslinux-2023-with-ssh-server

By deepaksorthiya

•Updated about 1 year ago

SSH server enable AWS Linux 2023 image

Image
Networking
0

2.3K

deepaksorthiya/awslinux-2023-with-ssh-server repository overview

⁠build image with cache

docker build --progress=plain -t deepaksorthiya/awslinux-2023-with-ssh-server:latest .

⁠build image with no cache

docker build --progress=plain --no-cache -t deepaksorthiya/awslinux-2023-with-ssh-server:latest .

⁠run image

docker run --name awslinux-2023-with-ssh-server -it -p 22:22 deepaksorthiya/awslinux-2023-with-ssh-server:latest

⁠Install all packages from readme

dnf install sudo -y

⁠install minimum utils

sudo dnf install unzip -y && sudo dnf install tar -y && sudo dnf install findutils.x86_64 -y && sudo yum install which -y && sudo yum install iproute -y

⁠start ssh server using(optional)

/usr/sbin/sshd -D

⁠check ssh running port

sudo ss -tulpn | grep LISTEN

⁠import key from host

copy your host ssh public key from ~/.ssh/id_rsa.pub

⁠on remote ssh server add this public key

cd ~/.ssh touch authorized_keys add content of id_rsa.pub to authorized_keys

echo "" >> authorized_keys

⁠start ssh tunnel from host

ssh -v [email protected]

#if error :: REMOTE HOST IDENTIFICATION HAS CHANGED try below first ssh-keygen -R 127.0.0.1

Tag summary

Content type

Image

Digest

sha256:2c7d74959…

Size

163.3 MB

Last updated

about 1 year ago

docker pull deepaksorthiya/awslinux-2023-with-ssh-server