It is true that you will be much dependent on who you get your energy from. Japan's lack of energy is what prompted the attack on Pearl Harbor. To understand Trump's tactics here, you have to look at the full picture. He has chided the EU nations for taking a free ride in NATO, and for inequitable tariffs against the US. Rather than deal with those problems, Germany is turning toward Russia for solutions. As with Russia, Germany is resisting or rejecting the US sanctions on Iran. Other sources of gas are available, including a pipeline under construction coming up from the South.
Trump is trying to draw Germany back to closer relations with the US, but on on more equitable financial basis. The hammer he wields is potential tariffs on Germany's auto industry, which is its huge moneymaker. So far it doesn't seem to be working in Merkel's case, but the US has nothing to lose by imposing 20% tariffs on German cars. It will bring the US more jobs and a better balance sheet. But it will be devastating to the German economy.