diff options
author | liamfallon <liam.fallon@est.tech> | 2022-09-05 14:52:02 +0100 |
---|---|---|
committer | liamfallon <liam.fallon@est.tech> | 2022-09-05 14:56:11 +0100 |
commit | a0411250da4358062576be11f1620665271f423b (patch) | |
tree | eacba8d3e5c83599dbebe7a671cfb6d0206bdc3f /csit | |
parent | c286a3485cd3928ef223c4df1f66af777acd5729 (diff) |
Fix broken CSIT tests
The CSITs are all failing due to a problem in the cert generation.
This review disables cert generation and copies in certs as a temporary
fix.
In JIRA POLICY-4338 we are converting the CSITs to use HTTP so that will
be the eventual solution for this issue. See also:
https://gerrit.onap.org/r/c/policy/docker/+/130624
Issue-ID: POLICY-4350
Change-Id: I97dbdcce9919bbc98632174a5bb7afe84c1a8f4c
Signed-off-by: liamfallon <liam.fallon@est.tech>
Diffstat (limited to 'csit')
-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 | 63 |
9 files changed, 161 insertions, 18 deletions
diff --git a/csit/config/cakey.pem b/csit/config/cakey.pem new file mode 100644 index 00000000..7ab3ba69 --- /dev/null +++ b/csit/config/cakey.pem @@ -0,0 +1,30 @@ +-----BEGIN ENCRYPTED PRIVATE KEY----- +MIIFHDBOBgkqhkiG9w0BBQ0wQTApBgkqhkiG9w0BBQwwHAQIn7IXl9tp53oCAggA +MAwGCCqGSIb3DQIJBQAwFAYIKoZIhvcNAwcECM9vPkP/Ay5JBIIEyIHDtrUSJOPo +OT/ZqNZ2hCxa7nwJUPAE09elPML75FGLXFuKmZXSEKMsC5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pjzzNY44MYxXDP+ciTM2602VVCXtt6+74NC0bvAzSIeY5lmOqTlA1 +xWSDfbZ+T7NbFpdFcjuApiyzsL41rEEnaqgWcA2ldBisQNeQut7xHjcTeFzeNyTe +Zy3e76wOi0fT5MZbsQLDcIUCW3deYgoBdeivTpMvfHnJImsKhGnO9kQGLwgSqgN8 +MU3abOhobfVtLIilYfqlm46XKFcsudL7wKrEhzx8D9vBHmN40WKu4A7oQQgmg+8Y +YZfUHDKGViIaqcieR9+6C3VQhDKLK4OBfg2g5b9bOqe6Fo+nXZI5pf/jxfP8eHXc +7xCvHbOahOy+R5LubLLxAJtQaf4X63bCJDKutJa5iCGi87rAwxh7sm0B7mkC4XpD +ont+Ose4GeiytJqqe6LlDdIjD7wQOAoBhb4DqX50tNiGa5ymBJEQ5Lq456dLUtY+ +5r7ARnBifzrKPSXqE79GNUMceI7BQlot/72WQIuD6MwBTe6FCUoNM+zMF4zzi7Ph +9MX3EFimqcL8H4x3wD1g4w== +-----END ENCRYPTED PRIVATE KEY----- diff --git a/csit/config/careq.pem b/csit/config/careq.pem new file mode 100644 index 00000000..57b414d8 --- /dev/null +++ b/csit/config/careq.pem @@ -0,0 +1,16 @@ +-----BEGIN CERTIFICATE REQUEST----- +MIICjDCCAXQCAQAwRzELMAkGA1UEBhMCVVMxEzARBgNVBAgMCk5ldyBKZXJzZXkx +DTALBgNVBAsMBE9OQVAxFDASBgNVBAMMC3BvbGljeS5vbmFwMIIBIjANBgkqhkiG +9w0BAQEFAAOCAQ8AMIIBCgKCAQEAozkMogBnADQwOp36opXoqvPKwlduH6bXH40o +zVLiTKLnKIFJ2edR7npSNGLMTvnFfIKg+L/yq+mcS6tjubm07uXF/LYxf2ie2WNW +itk4GBtvqREqr6ayo+q9AJ8aq35uhHylVq8OXFYLLOAJ8hhZAcuoAy3zjVYpNzh7 +reCbIp5GtIJanR3mior5ZD2Yr/D88QoSPpdMl13ezWDxoC8EwtZp2uul6x63t8i+ +GXcy5OWOH8WMvRe6E5FJptWaMvSkDVzDZVZQnDQpmQg2Fu+N/LkV0m/dCjEB++vz +DYWpK/X1LWtX+X1ZP++Dgt+Uk9MuueN1sc+SkqcF4Wh0N6mY5wIDAQABoAAwDQYJ +KoZIhvcNAQELBQADggEBAET3HRrtAz/COoIemC8Oo6JJm2f9umM0QPq0bijUA81Z +SFvnzfNhMZnvHdsAEl/VsBlqCSA+JLrPoXYhFV9YOYMHakuMToa7okW3yPPWbZRh +grFMCfRAO1j0INHA4emLASRkbEOE+R1ngkdoFv/EX0ImcyfMo/N+ls52QIAKo5cV +/Y6P0uXPqr4yOAaDZAyTKveQGdu1++SkTpZBBNdmq352FyARpH1CTB28oTy5tpl/ +wETVCcMxi9MYET4MGQSxQga91xyntjczjWGqnMpkTe35DVl4qAdrtkZHcvgM4WQ5 +HTxc7sBCRzvEAdI7a+uG6Tb5pJ4hvwCtjuIZApzsZWU= +-----END CERTIFICATE REQUEST----- diff --git a/csit/config/caroot.cer b/csit/config/caroot.cer new file mode 100644 index 00000000..f09d7630 --- /dev/null +++ b/csit/config/caroot.cer @@ -0,0 +1,19 @@ +-----BEGIN CERTIFICATE----- +MIIDFTCCAf0CFF9v497aX5+9X6xnUe8EUAITW8hpMA0GCSqGSIb3DQEBCwUAMEcx +CzAJBgNVBAYTAlVTMRMwEQYDVQQIDApOZXcgSmVyc2V5MQ0wCwYDVQQLDARPTkFQ +MRQwEgYDVQQDDAtwb2xpY3kub25hcDAeFw0yMjA5MDUxMzQzMDhaFw0zMjA5MDIx +MzQzMDhaMEcxCzAJBgNVBAYTAlVTMRMwEQYDVQQIDApOZXcgSmVyc2V5MQ0wCwYD +VQQLDARPTkFQMRQwEgYDVQQDDAtwb2xpY3kub25hcDCCASIwDQYJKoZIhvcNAQEB +BQADggEPADCCAQoCggEBAKM5DKIAZwA0MDqd+qKV6KrzysJXbh+m1x+NKM1S4kyi +5yiBSdnnUe56UjRizE75xXyCoPi/8qvpnEurY7m5tO7lxfy2MX9ontljVorZOBgb +b6kRKq+msqPqvQCfGqt+boR8pVavDlxWCyzgCfIYWQHLqAMt841WKTc4e63gmyKe +RrSCWp0d5oqK+WQ9mK/w/PEKEj6XTJdd3s1g8aAvBMLWadrrpeset7fIvhl3MuTl +jh/FjL0XuhORSabVmjL0pA1cw2VWUJw0KZkINhbvjfy5FdJv3QoxAfvr8w2FqSv1 +9S1rV/l9WT/vg4LflJPTLrnjdbHPkpKnBeFodDepmOcCAwEAATANBgkqhkiG9w0B +AQsFAAOCAQEAaWmjOUU0XyWpt27D8U2+2OIbWyeUz9L9HBppVzcadJo1CdNR2nvK +eESF12rg5uRy8E7gOKaYw1TZ7eLiTEAX2qkRaSknn72zQ6JcmRYKAOkA0qUhXKy9 +Jq+wo3M68mO7lam7BKqADPEq6a1t/QXWchA0mpQFbLM6w0l5V8k3cZqDRBiRgU1f +CNFEGY/YlT3r28jUbuYh1WerBPxw28TkFKaoxVvJ6FkAVqu0DYSexW+Y9ewRz4kK +9tXTIWYk87Q1F4gJc1f9rvgKMMcrWkIwb1AExkf35TBlKtVwCACqgNoMnszDMMf/ +/WCpM5vmC/6YoHpX5gD9GnoEk6MkYWbxKQ== +-----END CERTIFICATE----- diff --git a/csit/config/ks.cer b/csit/config/ks.cer new file mode 100644 index 00000000..463098c7 --- /dev/null +++ b/csit/config/ks.cer @@ -0,0 +1,29 @@ +-----BEGIN CERTIFICATE----- +MIIE+jCCA+KgAwIBAgIUNDLU1bXxnW46HpC3FmOFcJungPYwDQYJKoZIhvcNAQEL +BQAwRzELMAkGA1UEBhMCVVMxEzARBgNVBAgMCk5ldyBKZXJzZXkxDTALBgNVBAsM +BE9OQVAxFDASBgNVBAMMC3BvbGljeS5vbmFwMB4XDTIyMDkwNTEzNDMxMFoXDTIy +MTAwNTEzNDMxMFowYjEPMA0GA1UEAxMGcG9saWN5MSMwIQYDVQQLDBpwb2xpY3lA +cG9saWN5Lm9uYXAub3JnOkRFVjEOMAwGA1UECxMFT1NBQUYxDTALBgNVBAoTBE9O +QVA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SjBuX2IqrAohptTs/lutDFx +fm5l7ymTudg0CLPI+iYjG25ykf2ysUhxCk4VWjE6L2B4XGo6d4S1n5Gef0XDpWkA +zASUn1M22rkJWZsM55Kti6l57T++eiBzo6KjM3NzX4+a9P7ZzacrKMpNxBitq+IE +iJiY0INSlwO3kvUrqm7nWShgSQVksTzYVZHjZmVj9VaVo8Q49EIrHEpxAKgC/Y0M +dtZy6n2wvSurdcJtRMRZAows1pi3jFA/U82H3menh3dAhwr3hrRSfdjbzMg2HVeX +Z6vhpJ2xPa46US9j+sbL/6YriZOADkdcNe4C54qD +-----END CERTIFICATE----- diff --git a/csit/config/ks.csr b/csit/config/ks.csr new file mode 100644 index 00000000..6c405de1 --- /dev/null +++ b/csit/config/ks.csr @@ -0,0 +1,18 @@ +-----BEGIN NEW CERTIFICATE REQUEST----- +MIIC1zCCAb8CAQAwYjEPMA0GA1UEAxMGcG9saWN5MSMwIQYDVQQLDBpwb2xpY3lA
+cG9saWN5Lm9uYXAub3JnOkRFVjEOMAwGA1UECxMFT1NBQUYxDTALBgNVBAoTBE9O
+QVAxCzAJBgNVBAYTAlVTMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA
+jS6rhuIhW3O8I12CEwPqpvseVLrghXU5JnBiOhWUbVsMwbAhQvGbte5Z7k8kmPEd
+c84xfpmFHl/4jP2ada/QbJIT5kIrqBcocivyXIbztnThsCWPbKFBduvvtRxTCN+X
+0iSNux6vyHpfFB4PONzy/CdtRjgeO9Rbm4xYOgvvtLXGVuJ9oELMPNfVr5kFUUnv
+L9F7alE0wEVC1uDnU9EmGZFnEkfLLkcTVYUtlI8xzXSf24KN6ZjGHK2m8454PuK0
+/H1a1F5M4IdseVQK/OrOPxwGVgVZAIL0NIaw0i27Lu0S4t6Wpf5MtnYZmNix/8Pp
+qWeHaD5bUKVw93kigTw8PwIDAQABoDAwLgYJKoZIhvcNAQkOMSEwHzAdBgNVHQ4E
+FgQUs58oN4+Lq91oHXv7O+04gKZ95RswDQYJKoZIhvcNAQELBQADggEBAAwlPDBX
+urNeBAuIW8whtTPeuvDxlNYyotxvgJSD1wDmdYVFTd2lE0ibyCcc/6lKr9LYyjt9
+zpN+6CQOVk2rKTstbI0ZEmAbOA4p4dFOhPBmrOTdghc30NCNuoqnnUiOGsy4fkrh
+4uT46trLKhDdYlKEYWBeG3GfVyxhV1Zzf6ftf8Ab4TgFfacThpfe5cv9TLT9Nmpl
+cTcd2EwuRtkx9EpK/mqKqNTO0ZHB+aJ6YsrXxErNBd1zkeD0+mdU/CFgXJw1t2G7
+bARt8ybQ/caD9gjPL9sdrmV3dbG10d0saWcJc8KqzImURmnsu+Wdzf6kcSGwuHjU
+vgMUceeN155oQwg= +-----END NEW CERTIFICATE REQUEST----- diff --git a/csit/config/ks.jks b/csit/config/ks.jks Binary files differnew file mode 100644 index 00000000..b3603086 --- /dev/null +++ b/csit/config/ks.jks diff --git a/csit/config/policy-truststore b/csit/config/policy-truststore Binary files differindex 883e0a9c..0b78cafb 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 d77b06fa..4798ac18 100755 --- a/csit/run-project-csit.sh +++ b/csit/run-project-csit.sh @@ -168,8 +168,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 0eeb1c9b..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====================================================== +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 |