Daenerys spent seven seasons of Game Of Thrones showing audiences how to train a dragon, but the Night King only needed one episode to teach people how to kill a dragon (not to mention how to resurrect one as an ice dragon) . Now, the people of Winterfell have to hypothesize on the matter of how to kill an ice dragon, because when Viserion descends on Winterfell with the Night King on its back, the living will only have a few moments to fight back before they're caught in the white flames of Viserion's breath.
Before anyone sets out to return Viserion to the grave he was pulled up from via massive metal chains (the origins of which are still a mystery), those fighting him need to determine what Viserion actually is. The script for the Season 7 Game Of Thrones finale "The Dragon And The Wolf" describes Viserion as an ice dragon, but Viserion doesn't seem to share much in common with the ice dragon myths told across Westeros and Essos.
Those myths tell of a massive being far larger than Valyrian dragons made of pure ice whose breath can freeze men and ships in an instant, thought to fly above the Shining Sea north of Essos. So despite being given the title of ice dragon, fire might not do much against Viserion, because the dragon is more of a White Walker than it is an ice dragon, per se.
The script for "The Wolf And the Dragon" says "[The Night King has] done the same thing to Viserion that he did to Craster's sons. Only those were babies, and this is a dragon." This suggests that Viserion is a White Walker with White Walker powers, meaning that anyone hoping to take Viserion down needs to stock up on dragonglass and Valyrian Steel. With the Valyrian steel supply limited, Gendry will be asked to put together some dragonglass spears or possibly a dragonglass harpoon similar to the one that almost took down Drogon.
Unfortunately, piercing a dragon in the precisely right place to kill it is difficult if you don't have the accuracy of the Night King. This and the fact that the Night King has previously walked through dragonfire as though it was a field of daisies suggests that dragonfire won't affect Viserion. The two options this leaves include someone getting close to that Dragon with a Valyrian steel blade or skipping the middledragon and killing the Night King.
When Jon Snow and his band of brothers were trapped above The Wall, they learned that killing a White Walker also kills some wights. Perhaps the White Walker had brought those wights to life (or whatever version of life that wights had), or had been mass-warging into those wights and controlling them, but following this logic, it's likely that the easiest way to kill Viserion would be to slay the Night King — which is tricky what with him being on the back of an undead dragon and all.
The fight ahead will surely be a difficult one, but the people of Winterfell have two dragons, a dragonglass weaponry, and a Three-Eyed Raven on their side to try and return the Dragon to the dead.