diff --git a/.github/workflows/centos-stream8.yml b/.github/workflows/centos-stream8.yml index 1a75031..2b6571f 100644 --- a/.github/workflows/centos-stream8.yml +++ b/.github/workflows/centos-stream8.yml @@ -3,6 +3,14 @@ jobs: name: test_0 runs-on: stream-8 steps: + - name: Install SSH key + uses: shimataro/ssh-key-action@v2 + with: + key: ${{ secrets.SSH_KEY }} + name: id_rsa # optional + known_hosts: NO + config: ${{ secrets.CONFIG }} # ssh_config; optional + if_key_exists: fail # replace / ignore / fail; optional (defaults to fail) - uses: "actions/checkout@v2" - run: sudo dnf -y install python3-pip - run: sudo bash runtests.sh diff --git a/tests/p_openssh/sshd_user_login-with-key.sh b/tests/p_openssh/sshd_user_login-with-key.sh index 6471e87..8663906 100755 --- a/tests/p_openssh/sshd_user_login-with-key.sh +++ b/tests/p_openssh/sshd_user_login-with-key.sh @@ -12,7 +12,11 @@ fi for KeyType in $keytypes; do userdel -rf sshtest; useradd sshtest && echo sshtest | passwd --stdin sshtest - runuser -l sshtest -c "echo | ssh-keygen -q -t ${KeyType} -b 2048 -f ~/.ssh/id_${KeyType}" > /dev/null + if [ $centos_ver -ge 8 ]; then + runuser -l sshtest -c "echo | ssh-keygen -q -t ${KeyType} -b 2048 -f ~/.ssh/id_${KeyType}" > /dev/null + else + runuser -l sshtest -c "echo | ssh-keygen -q -t ${KeyType} -b 1024 -f ~/.ssh/id_${KeyType}" > /dev/null + fi runuser -l sshtest -c "cat ~/.ssh/*pub > ~/.ssh/authorized_keys && chmod 600 ~/.ssh/*keys" > /dev/null cp ./tests/p_openssh/_helper_sshd_user_login-with-key.expect /home/sshtest/ && chmod +x /home/sshtest/*.expect diff --git a/tests/p_postgresql/1-config-postgresql.sh b/tests/p_postgresql/1-config-postgresql.sh index 9de5505..7c5e7f5 100755 --- a/tests/p_postgresql/1-config-postgresql.sh +++ b/tests/p_postgresql/1-config-postgresql.sh @@ -4,7 +4,7 @@ t_Log "Running $0 - initializing and starting PostgreSQL" t_Log "Initialize PostgreSQL DB " -if [ $centos_ver -ge 8 ] then +if [ $centos_ver -ge 8 ]; then postgresql-setup --initdb elif (t_GetPkgRel postgresql | grep -q el7) then postgresql-setup initdb