Starbases around stars are definitely a lost cause at the moment. Even with full upgrades you'll still get hosed. To make that work they'll need to modify the system to allow other structures, or add in abilities that grant repair and shield restoration to the mix. Even after the upgrade, it takes too long to repair them between fights, and you'll need a sizable fleet with the base to prevent it from taking the full brunt of the attack. As such it's not going to be worth holding the star at all. If you can build other defense structures, then it will be a sustainable idea. Blowing 10k resources on a solitary starbase that will drop in ten seconds to an invasion fleet will never be a good idea unless it's powerful enough to make planetary assault completely impossible.
In controlled gravity wells on the other hand, starbases are fucking awesome. The key component is the shipyard. Place two of them on opposite sides, directly next to the starbase, and ring it with densely packed turrets. It's especially effective as the Feds thanks to synergy and adding in a hanger with shield bestowal. The static +4 regeneration and the addition of shields to the repair facilities and shipyards makes for a seriously tough nut. As long as it's close enough to the planet to tag sieging ships, you're invincible against anything but a massive fleet.