You seem to totally understand the situation, why ask.
You put him on something that your possible str8 could beat. Either a set or JX. So you know your drawing here. Gives you about a 1:4 chance of hitting for a 2:1 (both approximate, don't get picky here) payoff. From that POV, it is not a good call. And you seem to know this.
The real question here seems to be should you gamble or not? A good gamble gives you better than even odds. You at best barely have those.
I fold here mainly because of position. He could be cold stone bluffing
you here, he took the initiative with his early position, but at this point a sane person would grant him a real hand.
Had he checked, min bet or maybe even standard raised, It would change the dynamics of play so that a shove might increase your odds here significantly.
He shoved first, he gets this one.......
EDIT a few minutes later....
Thought 1; It's a bit peculiar how often situations like this do occur. It seems that a shortstack gets enamored with the possibilities of a hand and gets it all in at someone else's behest. It's a coinflip pre-turn. You still have enough chips left to play another round or 2, but since you didn't give details we can't know if this is a tourney life or death situation or not.
Thought 2; IF this is a tourney, then your 'M' is in the red zone, you haven't many orbits left, and this could be the best shot you'll get.
It's still a coinflip.