SpaceX was funded mostly with his own money, I thought?
The difference between investor and customer is only one of scale. How much money and what timeframe for return. As that increases risk, accordingly.
When you pay for a house or an apartment that's not built yet, you're investing in construction, you're not a "customer". Of course you expect a house and/or an apartment in a few years. But you invested your money, and that house/apartment may not materialize.
So NASA was an investor. Today they're also a customer, but they're still an investor. Some of their money blew up two days ago.