With Uber, Travis was attempting to undercut competition. Investors subsidize rides because when there is no competition they are in a better place to profit. Amazon (I believe?) was reinvesting the money in the business while subsidizing prices and package delivery to gain loyal customers. Many times an investor will subsidize a no-advertisement experience to gain an audience, and then switch on ads when the network effects are strong enough to retain the audience.
This is basically Machiavelli's advice that new princes should give favors to the masses when they rise to power, so that their positions are stronger later. But the real goal is always to turn profit aggressively, even if investors are patient for a few years while they maneuver into the right position.
Also just to be clear, no investor wants a business to pursue every profit opportunity. They want the business to focus on a strategy that will maximize profit given their strengths, and that always involves focus rather than being distracted by every possible opportunity.
That isn't obviously true. Eg, Amazon spent years actively doing everything possible to avoid making profits.
If investors don't like a company's strategy then they can try to get management changes or they can sell. But company strategy goes way beyond the blind pursuit of profit.
E.g. if startup X has the tech to take over a market, but is insufficiently pursuing a profit opportunity because of moral squeamishness, chances are relatively good that investors in X will simply replace the executives with somebody that will pursue those opportunities since that's vastly cheaper than building up competitive tech in a new investment.
That maybe true sometimes, but it is a lot rarer than you seem to believe (especially with early stage companies). The team running the company is a very large part of what people invest it. As a good counter example: Uber. Few would say that Travis wasn't pursuing profit every way possible, and it was the investors that moved against him because of his bad moral judgment.