I find myself having to duplicate a lot of code across all my jobs since many of them to have similar restart/reschedule policies
interval = "30s"
delay = "5s"
attempts = 3
mode = "delay"
delay = "10s"
delay_function = "constant"
unlimited = true
Is there any native way to have a groups in Nomad to inherit from a parent or something like that? I feel like there is just a lot of duplication in Nomad jobs in general. Thanks
restart block can only be defined at the group level and will be inherited by all tasks. The
reschedule can be defined at the job level and will be inherited by all groups within the job.
In order to share
reschedule blocks across jobs, you would need to use a templating tool. I wonder if you have had a chance to look at nomad-pack? This could allow you to define certain blocks in a reusable way, across many job specifications.
jrasell and the Nomad team
Thanks will look into it however I think it would be valuable to be able to have jobs inherit from a template natively.