Assuming the US military is even deployed to Gaza, they generally don’t want people pressed into service.
The requirement isn’t that people serve in the military – it’s community service, not military service. I’m just using the military as an example of a situation where Congress can compel people to go abroad (albeit not as a punishment).