# Update strategy

**URL:** <https://forums.balena.io/t/update-strategy/266756>\
**Category:** balenaOS\
**Tags:** foo\
**Created:** [March 8, 2021, 6:48am UTC](https://forums.balena.io/t/update-strategy/266756 "2021-03-08T06:48:44Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![PatrickEntabeni](https://avatars.discourse-cdn.com/v4/letter/p/da6949/32.png) [@PatrickEntabeni](https://forums.balena.io/u/PatrickEntabeni)\
**Post date:** [March 8, 2021, 6:48am UTC](https://forums.balena.io/t/update-strategy/266756/1 "2021-03-08T06:48:44Z")

</div>

Hello, I am working on an update strategy with Electron & node, Firstly, I want a notification to appear on the users screen that says a download is in progress(Lock the update with a lockfile):  
Is there a better way to do this other than polling the device download\_progress through the API?

Then I want the user to be able to click update when they are finished with their task(that I can do by deleting the lockfile and the container will restart)

I will also have a chronjob to delete the lockfiles overnight to enable automatic updates.

My second question is, if there is an update downloaded, and the user restarts the device instead of deleting the lockfile, will the updated happen?

---

<div class="post-metadata">

**Author:** ![PatrickEntabeni](https://avatars.discourse-cdn.com/v4/letter/p/da6949/32.png) [@PatrickEntabeni](https://forums.balena.io/u/PatrickEntabeni)\
**Post date:** [March 8, 2021, 4:08pm UTC](https://forums.balena.io/t/update-strategy/266756/4 "2021-03-08T16:08:08Z")

</div>

Moving this to paid support
