You can set the functionTimeout option in the host.json file.
The host.json affects also the local development.
As described in the host.json reference for functionTimeout you can set it to:
{ "functionTimeout": "-1" }