The duration of mandatory service depends on the age at the time of Aliyah (immigration to Israel) and personal status. There is a chart available for reference, specifying the duration based on different factors.