Fix intermittent errors with test-network ca (#1304)

If CA server hasn't finished initialization then the initial
register and enroll requests will fail.
Waiting 3 seconds resolves the issue.

Signed-off-by: David Enyeart <enyeart@us.ibm.com>
This commit is contained in:
Dave Enyeart 2025-02-20 17:14:35 -05:00 committed by GitHub
parent e1d8779f2a
commit 50699a6801
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -224,6 +224,8 @@ function createOrgs() {
infoln "Generating certificates using Fabric CA" infoln "Generating certificates using Fabric CA"
${CONTAINER_CLI_COMPOSE} -f compose/$COMPOSE_FILE_CA -f compose/$CONTAINER_CLI/${CONTAINER_CLI}-$COMPOSE_FILE_CA up -d 2>&1 ${CONTAINER_CLI_COMPOSE} -f compose/$COMPOSE_FILE_CA -f compose/$CONTAINER_CLI/${CONTAINER_CLI}-$COMPOSE_FILE_CA up -d 2>&1
# Allow CAs to initialize and then make register and enroll requests
sleep 3
. organizations/fabric-ca/registerEnroll.sh . organizations/fabric-ca/registerEnroll.sh
while : while :