blob: ef114397774e957b6e19cccc98d3f80f4b3e7da1 [file] [log] [blame]
Valerio Settif67ded32024-06-27 08:03:32 +02001#!/bin/bash
2
3# Copyright The Mbed TLS Contributors
4# SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
5
6set -e
7
8# The server creates some local files when it starts up so we can wait for this
9# event as signal that the server is ready so that we can start client(s).
10function wait_for_server_startup() {
Ronald Cronc04c2ed2024-07-22 08:48:17 +020011 while [ $(find . -name "psa_notify_*" | wc -l) -eq 0 ]; do
Valerio Settif67ded32024-06-27 08:03:32 +020012 sleep 0.1
13 done
14}
15
Valerio Settif67ded32024-06-27 08:03:32 +020016$(dirname "$0")/psa_server &
17wait_for_server_startup