File: test_suite-sle15

package info (click to toggle)
scap-security-guide 0.1.78-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 114,600 kB
  • sloc: xml: 245,305; sh: 84,381; python: 33,093; makefile: 27
file content (24 lines) | stat: -rw-r--r-- 798 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
FROM registry.suse.com/bci/bci-base:latest

ENV AUTH_KEYS=/root/.ssh/authorized_keys

ARG CLIENT_PUBLIC_KEY
ARG ADDITIONAL_PACKAGES

RUN zypper ar --no-gpgcheck http://download.opensuse.org/distribution/leap/15.5/repo/oss/ oss
RUN zypper refresh

RUN true \
        && zypper --non-interactive in openssh-clients openssh-server openscap-utils \
        python311 python311-rpm python311-pip tar gawk\
        $ADDITIONAL_PACKAGES \
&& true
RUN pip install ansible && ansible-galaxy collection install ansible.posix

RUN true \
        && for key_type in rsa ecdsa; do ssh-keygen -N '' -t $key_type -f /etc/ssh/ssh_host_${key_type}_key; done \
        && mkdir -p /root/.ssh \
        && printf "%s\n" "$CLIENT_PUBLIC_KEY" >> "$AUTH_KEYS" \
        && chmod og-rw /root/.ssh "$AUTH_KEYS" \
&& true