If any of the post-install scripts fail during first boot,
they should be retried on subsequent boots.
That was not happening because run-agl-postinsts.service
would be disabled even if a post-install script failed as
it always returned success on its execution.
Now signalize properly when it sees any error while executing
some post-install script.
Change-Id: I4402ee69c80814b06e3cc25cb400a66de3b5652d
Signed-off-by: Andre Goddard Rosa <andre.goddard@gmail.com>
# since all postinstalls executed successfully, remove the postinstalls directory
if [ $remove_agl_pi_dir = 1 ]; then
rm -rf $agl_pi_dir
+ exit 0
fi
+exit 1