The flag was raised at a concert by Lebanese indie rock band Mashrou' Leila, whose lead singer is openly gay.
Homosexuality is taboo in both Muslim and Christian communities in largely-conservative Egypt, and while Egyptian law doesn't overtly prohibit homosexuality, officials often use charges like "immorality," "debauchery" or even "blasphemy" to prosecute people for being gay, the New York Post reported.
After the concert, images and videos of the flag-raising went viral, with some supporting the flag but others attacking the men on social media.
A host on a television channel called for Reza Ragab, the deputy head of the Official Musicians Union, to explain how such immorality could have occurred "on Egyptian soil."
In an echo of the title of the infamous 1937 Nazi-run anti-Semitic art exhibition "Die Entartete Kunst [Degenerate Art]," Ragab said in a phone interview on AlAssema TV, "We are against gay art… it is depraved art."
Even though the band has all the necessary permits approved by state security services to perform in Egypt and last night's performance wasn't the band's first in the country, the union claimed that it would forbid the group from ever returning.
The band, which has gained worldwide popularity in Europe and the US, was banned twice from performing in Jordan because the musicians allegedly violate the country's rules with their blasphemy.
Egypt frequently arrests gay men. In 2001, 52 men were arrested at a boat dance party on the Nile. The men were put on highly publicized trial, during which they were taunted by the media and even saw their names, addresses and photos published.
Though the arrests were heavily criticized by human rights organizations and Western governments, almost half of the men were sentenced to prison terms.