逸 itself means "escape" or "break loose". One one hand, this can be used for verbs such as 逸する, and on the other hand this "escape" has been taken in a more literary sense of "breaking loose", which it's not hard to see how it becomes "relax" or "leisure". This same meaning is present in Chinese.
Breaking up the character
As for the origins, 兔 is the original kanji for ウサギ, with 兎 as a variant. Standardization in Japan for some reason picked 兎 for ウサギ rather than the first one, while leaving 兔 present in 逸. The character is made up of parts for "movement" and "rabbit / hare", both acting to show the meaning of fleeing.
Kunyomi and finding source of this meaning
A number of the kunyomi reflect the meaning when it was loaned to Japanese. The kunyomi are:
はしる, うしなう, それる
Granted, I've never seen はしる written with this kanji, but it was loaned as a reading (showing similar semantic use in Japan when inherited from China). Hashiru obviously means "to run" (written with 走 now), Ushinau means "to part with", and soreru means "to go astray".
So where did it come from?
The meaning of "relax" is used in Chinese compounds, and in none of the kunyomi Japan gave the character initially, which suggests that at the time Japan started using this kanji it didn't have that meaning, but came to mean "relax" in China, and so the additional meaning of "relax" came along in compounds such as 安逸 and 逸楽 in Japan.
tl;dr came from a development in the Chinese language sometime after kanji were first introduced to Japan.