The proper answer is: "it depends." But that's unsatisfying because it's too complex. But in reality you can't eliminate that complexity, it's an irreducible complexity. Just as there isn't one simple, objective system which you can consult to reliably get an answer to the question "should you go outside or stay indoors?" there isn't one for whether you should use something off the shelf or build something yourself. Look at, for example, SpaceX, who built the first generation of engines for their Falcon 9 rockets using turbopumps (one of the most complex components of a high performance rocket) provided by 3rd party companies. However, in the subsequent generation of engines (the Merlin-1D) SpaceX has designed and built the turbopumps themselves, and this is responsible for significant improvements in the engine.
Ultimately I think it's more important to take a step back and make a conscious effort to avoid making big decisions based on instinct or inertia and begin to cultivate a set of processes, elements of corporate culture, and habits which encourage thoughtful analysis and introspection about these choices. People should be more thorough about evaluating the advantages and disadvantages of doing things different ways and be mindful of when it doesn't seem to make much difference. And also mindful of the opportunity to change your mind in the future. Sometimes it can be worthwhile to rebuild a tool that already exists in the industry just for the purposes of acquiring the experience and knowledge of having done so. And sometimes even when taking something in house might easily save millions of dollars a year it still might not be worth it due to other opportunity costs.
It's a complicated question, and it's always going to be a complicated question. Instead of pretending it's an easy question people should be working on acquiring the skills to make sure they can answer the question well with some degree of reliability.