For a long time in the US military, this was reserved for religious reason and religious reason only. A person who was not a believer in any religion was not allowed to object, and was therefore forced to go into battle regardless of their beliefs and personal feelings.

Fortunately, this has changed, and that form of discrimination against those without religion is gone.