File fdo-client-service of Package fdo-client

#!/bin/sh
check_file=/var/lib/fdo-client/initialized
data=/var/lib/fdo-client/data
log=/var/log/fdo-client.log

cd ${data}

if [ ! -f ${check_file} ]; then
    # The first time the client will connect the manufacturer
    # server in order to get information about rendevous service.
    # After that the service will be stopped. The machine is now
    # ready for delivery. Next time the machine will connect to
    # the rendezvous service when it will be switched on.
    /usr/bin/fdo-client >${log}
    systemctl status fdoclient| grep 'Main PID' | awk '{print $3}' >${check_file}
    /bin/systemctl stop fdoclient
    exit 0
fi

while :
do
    # The rendevous service returns the information about the
    # prider platform service (only the first time). This service
    # will be contacted periodically.
    /usr/bin/fdo-client >>${log}
    sleep 30;
done


openSUSE Build Service is sponsored by