File tree 4 files changed +24
-32
lines changed
4 files changed +24
-32
lines changed Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
18
18
ethtool libpcap-dev openvswitch-switch qemu-kvm qemu-utils \
19
19
dnsmasq ntfs-3g iproute2 qemu-system-x86 software-properties-common \
20
20
dosfstools openssh-server locales locales-all python3.10 python3.10-venv \
21
- vim psmisc && \
21
+ vim psmisc iputils-ping && \
22
22
apt-get clean && rm -rf /var/lib/apt/lists/* || { echo "Package installation failed" ; exit 1; }
23
23
24
24
# ## Locale support ###
@@ -82,15 +82,11 @@ RUN bash -c "source /fwpy/bin/activate && \
82
82
83
83
RUN firewheel repository install -s -i || { echo "Repository installation failed" ; exit 1; }
84
84
85
- RUN cp /usr/bin/ssh /usr/bin/ssh-old && \
86
- cp /usr/bin/scp /usr/bin/scp-old && \
87
- cp /usr/bin/sudo /usr/bin/sudo-old && \
85
+ RUN cp /usr/bin/sudo /usr/bin/sudo-old && \
88
86
cp /usr/bin/chgrp /usr/bin/chgrp-old
89
87
90
88
COPY docker/fsroot/ /
91
89
RUN chmod +x /usr/local/bin/entry && \
92
- chmod +x /usr/bin/ssh && \
93
- chmod +x /usr/bin/scp && \
94
90
chmod +x /usr/bin/sudo && \
95
91
chmod +x /usr/bin/chgrp && \
96
92
chmod +x /start-minimega.sh
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -7,6 +7,27 @@ function gr() {
7
7
echo -e " \033[32;1m" " $@ " " \033[m"
8
8
}
9
9
10
+ function yl() {
11
+ echo -e " \033[33;1m" " $@ " " \033[m"
12
+ }
13
+
14
+ # Let the SSH server run without systemd
15
+ mkdir /var/run/sshd
16
+
17
+ # Start the SSH server
18
+ /usr/sbin/sshd
19
+ ssh-keygen -f ~ /.ssh/id_rsa -N " " & > /dev/null
20
+ cat ~ /.ssh/id_rsa.pub >> ~ /.ssh/authorized_keys
21
+ if [ -e ~ /.ssh/config ];
22
+ then
23
+ yl " SSH config already existed, not modifying it" ;
24
+ else
25
+ cat << EOF > ~/.ssh/config
26
+ Host *
27
+ StrictHostKeyChecking no
28
+ EOF
29
+ fi
30
+
10
31
export HOME=/root
11
32
12
33
HN=" $( hostname) "
@@ -75,4 +96,4 @@ until rm -rf /tmp/*; do
75
96
done
76
97
gr " done"
77
98
78
- gr " Container shutdown."
99
+ gr " Container shutdown."
You can’t perform that action at this time.
0 commit comments