H2 is the most abundant gas in the universe, so we can pretty much find it anywhere. With hydrogen and oxygen burned together comes energy.
Many rockets, including United Launch Alliance's Atlas V and Vulcan Centaur, Blue Origin's New Shepard and New Glenn Rocket, and many more, all use Hydrogen as their primary fuel. Let's not forget that the Space Shuttle also relied on Hydrogen Fuel to get to orbit successfully. In the future, humanity will be living among the stars, and we'll have plenty of Hydrogen. So, while we're already using it as energy to alter the position of the spacecraft when needed, we might as well use some of it for electricity as well.
If things are done currently and you are burning your propellant (Hydrogen and Oxygen) in a controlled manner, you could have infinite propellant, as you could keep re-using that same propellant which you just burned. Pure Hydrogen and Oxygen burn together, it produces water vapor (gaseous water/H2O) as a byproduct, you let that gaseous water float around in a sealed environment, you convert the heat generated into electricity via a thermoelectric generator, the water vapor condenses eventually, you use electrolysis to split the water back into Hydrogen and Oxygen, and now you have your propellant back, ready to be burned again.