(a) The Secretary of the Navy, under such regulations as he prescribes, may sell to a merchant ship such fuel and other supplies as may be required to meet its necessities if the ship is unable
(1) to procure the supplies from other sources at its present location; and
(2) to proceed to the nearest port where they may be obtained without endangering the safety of the ship, the health and comfort of its personnel, or the safe condition of the property carried on it.