Auto update foreman

How can I make some servers under Hosts to automatically update yum and some servers to update without kernel update, is that possible?

For example

x Make Rhel 7.9 auto update on my server
My Y server should not upgrade to Rhel 8.6 8.9 but should be able to do security and bug updates otherwise


For RHEL, you can use the dot-release repos illustrated here:

You would set your host’s release version to the same version, and make sure your host consumes that repo via its content view.

These will only contain updates released during that dot release. However, keep in mind that they won’t get backported security updates. For example, if you’re on the 8.6 repo and a security update is released today, it won’t be added to the 8.6 repo.

Because of this, it’s recommended instead to use the regular (non-dot-release) repositories and use Content View filters to restrict what updates your hosts get.

If you are also asking about how to automate the yum update on the given host, the Remote Execution plugin can be used to run tasks repeatedly, e.g. once a day. It would be then a matter of scheduling the following job

yum -y --exclude=kernel\* update