Skip to content

Commit

Permalink
(maint) cleanup docker ssh opensuse and archlinux
Browse files Browse the repository at this point in the history
* dropped archlinux as it never worked
* support opensuse ssh service start
  • Loading branch information
h0tw1r3 committed Feb 13, 2024
1 parent eb7e3c4 commit 7cd162f
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions tasks/docker.rb
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,6 @@ def install_ssh_components(distro, version, container)
docker_exec(container, 'zypper -n in openssh')
docker_exec(container, 'ssh-keygen -A')
docker_exec(container, 'sed -ri "s/^#?UsePAM .*/UsePAM no/" /etc/ssh/sshd_config')
when %r{archlinux}
docker_exec(container, 'pacman --noconfirm -Sy archlinux-keyring')
docker_exec(container, 'pacman --noconfirm -Syu')
docker_exec(container, 'pacman -S --noconfirm openssh')
docker_exec(container, 'ssh-keygen -A')
docker_exec(container, 'sed -ri "s/^#?UsePAM .*/UsePAM no/" /etc/ssh/sshd_config')
docker_exec(container, 'systemctl enable sshd')
else
raise "distribution #{distro} not yet supported on docker"
end
Expand Down Expand Up @@ -79,7 +72,7 @@ def install_ssh_components(distro, version, container)
else
docker_exec(container, 'service sshd restart')
end
when %r{sles}
when %r{opensuse}, %r{sles}
docker_exec(container, '/usr/sbin/sshd')
else
raise "distribution #{distro} not yet supported on docker"
Expand Down

0 comments on commit 7cd162f

Please sign in to comment.