Created
May 28, 2021 17:08
-
-
Save brettviren/4a36b1fddf3fdb838d94991f776f3a7f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
❯ docker run -p 2222:22 -ti dunedaq/sl7 | |
[root@29a0d8d71d90 /]# vi /etc/ssh/sshd_config | |
[root@29a0d8d71d90 /]# ssh-keygen -A | |
[root@29a0d8d71d90 /]# /usr/sbin/sshd -D & | |
[root@29a0d8d71d90 /]# mkdir /root/.ssh | |
[root@29a0d8d71d90 /]# chmod 700 /root/.ssh | |
[root@29a0d8d71d90 /]# cat >> /root/.ssh/authorized_keys | |
# paste, ctrl-d | |
[root@29a0d8d71d90 /]# chmod 600 /root/.ssh/authorized_keys | |
❯ ssh root@localhost -p 2222 | |
[root@29a0d8d71d90 ~]# |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment