A South Korean man has been convicted of gaining weight on purpose to avoid serving in the military, The Korea Herald reported on Sunday (Nov 24). The 26-year-old was sentenced to a year in prison, suspended for two years, under the Military Service Act. He reportedly doubled his daily food
Not quite the same, but Finland will put you in jail for six months if you refuse your mandatory military/civilian service. Though technically speaking you are just doing your civilian service by sitting in jail instead at that point.
To avoid that you need to have a valid medical condition that prohibits you from serving. Being too obese is one of them.