How to shutdown dash server after one hour in python

I’m launching python files by crontab and it is working fine and creating a dash website, but when the same python file launches again, I get the old data on the website. so, please help me to shut down the server automatically after one hour so that next launching python file will update the data on website.

I have the following code to run server

if name == ‘main’:
app.run_server(debug = True,host = ‘’, port=8052).

A better way might be to use a layout function instead of a static layout. That way you can load the data on every page refresh. This is described at the bottom of this page

If loading the data takes a long time then you could cache the result for one hour by specifying a cache timeout