At our clinic (I'm a vet tech), first thought with something like that would be an infected or abscessed tooth. The infection can sometimes burst through the cheek like that.

Hopefully it's just an abscess, whether it's from a tooth or just a scratch.