#!/bin/bash
while true
do
wildflyStarted=$(grep -ic "Wildfly.*started in.*ms.*Started.*of.*services" /opt/wildfly/standalone/log/server.log)
if [[ "$wildflyStarted" -eq "1" ]]; then
break;
else
sleep 1;
fi
done
while true
do
ejbcaStatus=$(/opt/wildfly/bin/jboss-cli.sh -c --commands="cd deployment,cd ejbca.ear,read-attribute status")
if [[ "$ejbcaStatus" -eq "OK" ]]; then
break;
else
sleep 5;
fi
done
Este script funcionou para mim.