diff options
author | Liam Fallon <liam.fallon@est.tech> | 2022-09-06 14:26:29 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2022-09-06 14:26:29 +0000 |
commit | b4a9f4b5bb8fdcbf56a61e30127a1a872ca2eb31 (patch) | |
tree | c1d9b512b9af3aee1e4f99546e657d502a6490bc | |
parent | e87009d35a11763dc8ec64e5f6cefbba749d3755 (diff) | |
parent | d15d21fd6cbaa4a1e6c9f8ce151fc691a484083a (diff) |
Merge "Fix broken CSIT tests" into jakarta
-rw-r--r-- | csit/config/cakey.pem | 30 | ||||
-rw-r--r-- | csit/config/careq.pem | 16 | ||||
-rw-r--r-- | csit/config/caroot.cer | 19 | ||||
-rw-r--r-- | csit/config/ks.cer | 29 | ||||
-rw-r--r-- | csit/config/ks.csr | 18 | ||||
-rw-r--r-- | csit/config/ks.jks | bin | 0 -> 5001 bytes | |||
-rw-r--r-- | csit/config/policy-truststore | bin | 124180 -> 125108 bytes | |||
-rwxr-xr-x | csit/run-project-csit.sh | 4 | ||||
-rwxr-xr-x | csit/wait_for_port.sh | 65 |
9 files changed, 162 insertions, 19 deletions
diff --git a/csit/config/cakey.pem b/csit/config/cakey.pem new file mode 100644 index 00000000..461c1523 --- /dev/null +++ b/csit/config/cakey.pem @@ -0,0 +1,30 @@ +-----BEGIN ENCRYPTED PRIVATE KEY----- +MIIFHDBOBgkqhkiG9w0BBQ0wQTApBgkqhkiG9w0BBQwwHAQIrbGtIemEC2oCAggA +MAwGCCqGSIb3DQIJBQAwFAYIKoZIhvcNAwcECNUTed7WnOACBIIEyOcQO0PmJ/Qj +0NSwyyRpztMUtwuBanXC43vHgPfkYXiQRSl7vFrKZ6c3rYc8+ZFIK4U6XzK9peuc +Tqkt408CBlpOcHqYEtgIQ+U2Fm2ytbIa8BVYbKN3w2+GRN1bbfNwn2+k23r7lceb +4M4OOM6aaEcTITXa63xE0LdpDX2URh4Jaty/6kVhu4ZHWarHZ4hoeZKbdS4WEz66 +j0Rajmpwdd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E0ob/C4oJioEGcdi9s2akYMXTt +FFWn52elJnd+5Q38ElO3jpK3L1cOr4KA9tahl1uM1C8blM696fBbeS2A5HHh8PbO +tl0GXXLgSM5fzGhKlZCbRnVIsusONC0O3cw72RKC1OszaNIYctIoYy3OcSeG85wy +0BjiWo72Nvc1yKdwO4mRm1IYm95N61uv2bLMaRXtjQSlHqrY/S5UdTO/1SnMOYRZ +KChzLf8rRN0c6lb+3bov167Uveu6tAGgXE8W53w9fA7ZwcmdDchnPJsN4YkM2bGh +qoHiVDXvb4OS3H4HMoJBv/yUOb/icr5Z+kALpnH2FGUx/N36NcYH/cDesFNj7X9T +FIhIqnbHcdIEGmjnmXCwmA== +-----END ENCRYPTED PRIVATE KEY----- diff --git a/csit/config/careq.pem b/csit/config/careq.pem new file mode 100644 index 00000000..b56ade1e --- /dev/null +++ b/csit/config/careq.pem @@ -0,0 +1,16 @@ +-----BEGIN CERTIFICATE REQUEST----- +MIICjDCCAXQCAQAwRzELMAkGA1UEBhMCVVMxEzARBgNVBAgMCk5ldyBKZXJzZXkx +DTALBgNVBAsMBE9OQVAxFDASBgNVBAMMC3BvbGljeS5vbmFwMIIBIjANBgkqhkiG +9w0BAQEFAAOCAQ8AMIIBCgKCAQEA0qNgvDgs8fDWKUqQ0/ZLE3X8Ugg1EMnH0KVb +qBAQlQjcP/G02ucBbp5KATXMI7RJQTtjajeQlLAHs2G8rZDRoWwg/61aEI6SGHzZ +gb0k/ROQ1sIrtSfbHVSrZIyQaIF8XZrAh5RdA2oCLwJbc80aCDY06Sc4OsuljylN +wqZHlBY/KBytkVGbeRY79dx7844SN7Wcr8qRAfLo1Gc3ZgSSwpMUHFueWr84Fh1O +4xc9TXiz52QACWjHbqrI66IJLRZrvqMJz+hVOIQeT1c0ixTfb7q4kH5yDSmqZuNF +PevnzL3Z0EoH/d3cJ5JmIjzKL5O+FMY43fPisziJoQmj36GaFQIDAQABoAAwDQYJ +KoZIhvcNAQELBQADggEBAFdqXYjXK+88XvJyspAD5YX9XKBAiOH+eyacdMUKqkDJ +coYw4xBX0LlzupZamg5Qwk/Ad/SMlqXL29hI322HN7Frx3dwlNzuighIMZ62sN/s +FFf+rrAxqMBb1b++9thfOgrZdIQI5WodU0EELy+sFpRAbkieyEQ7a1SVie1+7Afu +KhGfEGTvgln81eMr+QB0gRkTlorC7AkeWJzIgWMh4kTcujTWsVc/FLb1jSe7Hc7R +diOdNes3EZLjfdpORhuL3BOb+HzTwVUyw2BHD3bD0u+XFOfDLIUlfdOSesuf6bi6 +JKHSeUV0xww0R0WfsgYxN/6HSFQ8hWFGa3PjY5D1UNE= +-----END CERTIFICATE REQUEST----- diff --git a/csit/config/caroot.cer b/csit/config/caroot.cer new file mode 100644 index 00000000..cd12c65c --- /dev/null +++ b/csit/config/caroot.cer @@ -0,0 +1,19 @@ +-----BEGIN CERTIFICATE----- +MIIDFTCCAf0CFCAWwWW10ZqYy46ID/aAsN1zxnkgMA0GCSqGSIb3DQEBCwUAMEcx +CzAJBgNVBAYTAlVTMRMwEQYDVQQIDApOZXcgSmVyc2V5MQ0wCwYDVQQLDARPTkFQ +MRQwEgYDVQQDDAtwb2xpY3kub25hcDAeFw0yMjA5MDUxMzI1MDlaFw0zMjA5MDIx +MzI1MDlaMEcxCzAJBgNVBAYTAlVTMRMwEQYDVQQIDApOZXcgSmVyc2V5MQ0wCwYD +VQQLDARPTkFQMRQwEgYDVQQDDAtwb2xpY3kub25hcDCCASIwDQYJKoZIhvcNAQEB +BQADggEPADCCAQoCggEBANKjYLw4LPHw1ilKkNP2SxN1/FIINRDJx9ClW6gQEJUI +3D/xtNrnAW6eSgE1zCO0SUE7Y2o3kJSwB7NhvK2Q0aFsIP+tWhCOkhh82YG9JP0T +kNbCK7Un2x1Uq2SMkGiBfF2awIeUXQNqAi8CW3PNGgg2NOknODrLpY8pTcKmR5QW +PygcrZFRm3kWO/Xce/OOEje1nK/KkQHy6NRnN2YEksKTFBxbnlq/OBYdTuMXPU14 +s+dkAAlox26qyOuiCS0Wa76jCc/oVTiEHk9XNIsU32+6uJB+cg0pqmbjRT3r58y9 +2dBKB/3d3CeSZiI8yi+TvhTGON3z4rM4iaEJo9+hmhUCAwEAATANBgkqhkiG9w0B +AQsFAAOCAQEAumReAeDIj8a/bba3Lyhe55NSrMiVzZD9GRxJSUkmbi0RD6QRJpHG +HXu9e8v3luP7Y8INz6c/ztCCNWCIggR53qYRdGAssId/mLpkx02WOvQGdWiPIoZQ +VmUC4BORkfuHk/LceKPwIf+RM52NzlRPhPawZhDITVoVx5EASeV5ZrVUMoxDgix6 +Wk56MYUSjAjMQq3NFPzLbQEMA73gSCifo29NSPqEtTzNKI4UHTgOaXnv59YKP3t7 +IgbCtAxiN4qqUgemTXeBvfpLLpuq0wrltxu2joqprikvJujqxvxzOXlH4cMik47v +aRqp806pFMBIf7P8S3b4MzLrZi8U5/CqVA== +-----END CERTIFICATE----- diff --git a/csit/config/ks.cer b/csit/config/ks.cer new file mode 100644 index 00000000..2946a080 --- /dev/null +++ b/csit/config/ks.cer @@ -0,0 +1,29 @@ +-----BEGIN CERTIFICATE----- +MIIE+jCCA+KgAwIBAgIUDSbE1jAMdFITeC8csFyyBEhTc6YwDQYJKoZIhvcNAQEL +BQAwRzELMAkGA1UEBhMCVVMxEzARBgNVBAgMCk5ldyBKZXJzZXkxDTALBgNVBAsM +BE9OQVAxFDASBgNVBAMMC3BvbGljeS5vbmFwMB4XDTIyMDkwNTEzMjUyMVoXDTIy +MTAwNTEzMjUyMVowYjEPMA0GA1UEAxMGcG9saWN5MSMwIQYDVQQLDBpwb2xpY3lA +cG9saWN5Lm9uYXAub3JnOkRFVjEOMAwGA1UECxMFT1NBQUYxDTALBgNVBAoTBE9O +QVAxCzAJBgNVBAYTAlVTMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA +kBWA9VTEHET8X9uDs35VVTfpHtHXxxHPWwm04uCROHus6AADNN0KVchZCFMm2Cem +f4kEoaGxLWNsW57YnSybyB5L254/YvNa9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/x69UdcR5KK2Lsy63fAtTVY9F5bKx1PmRm5vnQbExYp+ncD+C+8mvPEU +ofJIbGmEGrf/YHDsCrn0yq37G3ujJxT114Z7YIai+LTFlMqSL8wR8gDhSEGB4anz +cWNLMN4/l73ySRMXSC7Kj2h2J5DS0z46ujJCkCPN +-----END CERTIFICATE----- diff --git a/csit/config/ks.csr b/csit/config/ks.csr new file mode 100644 index 00000000..9777b85b --- /dev/null +++ b/csit/config/ks.csr @@ -0,0 +1,18 @@ +-----BEGIN NEW CERTIFICATE REQUEST----- +MIIC1zCCAb8CAQAwYjEPMA0GA1UEAxMGcG9saWN5MSMwIQYDVQQLDBpwb2xpY3lA
+cG9saWN5Lm9uYXAub3JnOkRFVjEOMAwGA1UECxMFT1NBQUYxDTALBgNVBAoTBE9O
+QVAxCzAJBgNVBAYTAlVTMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA
+kBWA9VTEHET8X9uDs35VVTfpHtHXxxHPWwm04uCROHus6AADNN0KVchZCFMm2Cem
+f4kEoaGxLWNsW57YnSybyB5L254/YvNa9utFLkaMnVzNZkoFFE24j4T2KgT2Vbt4
+YLMJYFzdu6/9pGhlkBw30UfZKo8li0BPyxReshk8hWFV+6Tcbr94qPM90j4b1Hz6
+pkJ1BwPOqCyrRLjuk6tQc2TYRN3PBFjknC/C9yeJc7fiBgoe8Hbx8AWEpMK/pFIB
+2JkMojuopjLffic8cN834+mExECWqtyaHNxnv8BaLvpCOgxXo3EMS9fHPM/N9XGz
+XIlw7W70d/FWE8pwCw+DXwIDAQABoDAwLgYJKoZIhvcNAQkOMSEwHzAdBgNVHQ4E
+FgQUVnkgg3tzlx3ioqbZEtORGBLdpS4wDQYJKoZIhvcNAQELBQADggEBAE6C4xqR
+1Ju3IaVGGoUW6zVtKwPPwXbbU4opQfpFMnDw6HGs1HFF6bRmB5bCN9uS32CSRq42
+X6uYFh24prpU2D3e1xQCtSZfBq55AYlgVrfuLwDXgpLNTQbQGnpeyobThS5qgeld
+umpWTCOU4dRIjjpXJb3e3CW2PN3wzNwavjgx1kHWHH+D5OGD4BZeZT8PHShT0qo6
+G6LNcedvEgJVHDFxnWJ7CK0qVAHHldVZ6PKvb9T79g2tRbIw29yfLv4nUUQtpRzU
+Ru0LTNStOxvbbg5Lrlx9gltdiHUMihnSj430yhG+7W6D16pP1YhAMCLBbdp9BKzn
+jOCKf0x5qlcc/Bk= +-----END NEW CERTIFICATE REQUEST----- diff --git a/csit/config/ks.jks b/csit/config/ks.jks Binary files differnew file mode 100644 index 00000000..c45251b8 --- /dev/null +++ b/csit/config/ks.jks diff --git a/csit/config/policy-truststore b/csit/config/policy-truststore Binary files differindex 883e0a9c..78998aff 100644 --- a/csit/config/policy-truststore +++ b/csit/config/policy-truststore diff --git a/csit/run-project-csit.sh b/csit/run-project-csit.sh index f09af486..c0f8d07a 100755 --- a/csit/run-project-csit.sh +++ b/csit/run-project-csit.sh @@ -172,8 +172,8 @@ cd "${WORKDIR}" docker login -u docker -p docker nexus3.onap.org:10001 # Generate truststore and keystore to be used by repos -${SCRIPTS}/gen_truststore.sh -${SCRIPTS}/gen_keystore.sh +#${SCRIPTS}/gen_truststore.sh +#${SCRIPTS}/gen_keystore.sh cp ${SCRIPTS}/config/ks.jks ${SCRIPTS}/config/drools/custom/policy-keystore cp ${SCRIPTS}/config/ks.jks ${SCRIPTS}/config/drools-apps/custom/policy-keystore cp ${SCRIPTS}/config/policy-truststore \ diff --git a/csit/wait_for_port.sh b/csit/wait_for_port.sh index aec5f222..9262ba32 100755 --- a/csit/wait_for_port.sh +++ b/csit/wait_for_port.sh @@ -1,6 +1,7 @@ #!/bin/sh # ============LICENSE_START==================================================== # Copyright (C) 2021 AT&T Intellectual Property. All rights reserved. +# Modifications Copyright (C) 2022 Nordix Foundation. # ============================================================================= # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -17,35 +18,65 @@ # SPDX-License-Identifier: Apache-2.0 # ============LICENSE_END====================================================== -tmout=120 +usage() { + echo args: [-t timeout] [-c command] hostname1 port1 hostname2 port2 ... >&2 + exit 1 +} + +tmout=300 cmd= -while getopts c:t: opt; do +while getopts c:t: opt +do case "$opt" in - c) cmd="$OPTARG" ;; - t) tmout="$OPTARG" ;; + c) + cmd="$OPTARG" + ;; + + t) + tmout="$OPTARG" + ;; + + *) + usage + ;; esac done -nargs=$(expr $OPTIND - 1) -shift $nargs -even_args=$(expr $# % 2) -if [ $# -lt 2 -o $even_args -ne 0 ]; then - echo "args: [-t timeout] [-c command] hostname1 port1 hostname2 port2 ..." >&2 - exit 1 +nargs=$((OPTIND-1)) +shift "$nargs" + +even_args=$(($#%2)) +if [ $# -lt 2 ] || [ "$even_args" -ne 0 ] +then + usage fi -while [ $# -ge 2 ]; do - export host=$1 - export port=$2 +while [ $# -ge 2 ] +do + export host="$1" + export port="$2" shift shift echo "Waiting for $host port $port..." - timeout $tmout sh -c 'until nc -vz "$host" "$port"; do echo -n "."; - sleep 1; done' - rc=$? - if [ $rc != 0 ]; then + while [ "$tmout" -gt 0 ] + do + nc -vz "$host" "$port" + rc=$? + + if [ $rc -eq 0 ] + then + break + else + docker ps + tmout=$((tmout-1)) + sleep 1 + fi + done + + if [ $rc -ne 0 ] + then echo "$host port $port cannot be reached" exit $rc fi |