This quote is likely a reference to the role-playing game Dungeons & Dragons, in which dragons are often powerful creatures that can easily defeat adventurers. The quote cautions against taking on challenges that are too difficult or dangerous.
The quote has also been used in a more general sense, to warn against getting involved in matters that are too complex or dangerous. For example, someone might say "Don't meddle in the affairs of politics, because you're likely to get burned."