Don't have an American bias when people share their cultures from around the world.
There are a lot of governments, and all of our experience with the American government basically means jack diddly with respect to the German government.
With that said, I do share your concerns, but I'm not going to make claims about a government I never visited and never worked with in my life that's roughly 10 time-zones away.
The German government, for example, owns several large banking groups, which act like any normal banking group – but their dividends directly go into the tax budget. (And they have to give loans at lower interest rates to the governments).
Normal bankers, in normal environment, and they’d probably never notice it was government owned.
The German government has done it for several decades, with great success – you should take a look at their model.
In all other cases, cities investing in companies are either going to take on a VC role which I'd very much argue that they are not capable of performing well (and introduces so much room for corruption) or will be investing in mature companies and likely without the balance sheet to make a dent as far as voting power goes. I don't see how either leads to anything productive.
The German city of Wolfsburg, and the state of Niedersachsen have done it with VW.
The solution: You just buy a large amount of shares of the companies that are started in your city. Municipalities get a far larger share of the profits directly, politicians have an incentive to ensure companies are profitable, and companies can’t avoid paying for the infrastructure they use.