It is a mitzvah for every Jew to serve in the IDF. But he must learn and follow the appropriate halakhot.