Thank you very much for the help!
When I put my copy command into bootsync.sh, I may have made a mistake somehow, but it did not work. To avoid the mentioned race condition I made my copy command the first line in bootlocal.sh and that did work fine.