I guess the 'courageous' part comes from the existence of often virulent anti-muslim sentiment.  When a political figure takes a stand against it, as the mayors of Saint-Apollinaire and Quebec City did, they do so at some political risk.  Or perhaps more.

Nobody vilified all the voters of Saint-Apollinaire, but even the local mayor reported that the tipping point came from voters against a muslim cemetery, not just a cemetery.  In that they were encouraged, and I'd say inflamed, by the people you call "outside agitators", some of whom live in that small town, some in Quebec City.