Skip to content

Commit

Permalink
amazonlinux2: fix sshd startup
Browse files Browse the repository at this point in the history
Signed-off-by: gbionescu <[email protected]>
  • Loading branch information
gbionescu committed Sep 4, 2024
1 parent 1997803 commit d36105b
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions type-amazonlinux2/inside-container.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,10 @@ yum install -y \
# Set password
echo "root:root" | chpasswd

# Start the ssh server to generate keys
systemctl start sshd
# Generate keys
ssh-keygen -A
# Manually enable sshd service
ln -s '/usr/lib/systemd/system/sshd.service' '/etc/systemd/system/multi-user.target.wants/sshd.service'

# Then, copy the newly configured system to the rootfs image:
mkdir /my-rootfs
Expand Down

0 comments on commit d36105b

Please sign in to comment.