Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename cron package to cronie for RHEL10 product #12463

Merged
merged 3 commits into from
Oct 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{{% if product in ["sle12", "sle15"] %}}
{{% if product in ["rhel10", "sle12", "sle15"] %}}
{{% set package_name = "cronie" %}}
{{% else %}}
{{% set package_name = "cron" %}}
Expand Down Expand Up @@ -42,5 +42,6 @@ template:
name: package_installed
vars:
pkgname: cron
pkgname@rhel10: cronie
pkgname@sle12: cronie
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should a pkgname@rhel10 key be added also in the template vars in rule service_cron_enabled?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Checked RHEL distros and the service is named crond, not cron. Added new commit with the fix for RHEL distros

pkgname@sle15: cronie
15 changes: 13 additions & 2 deletions linux_os/guide/services/cron_and_at/service_cron_enabled/rule.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
{{% if product in ["rhel8", "rhel9", "rhel10"] %}}
{{% set service_name = "crond" %}}
{{% else %}}
{{% set service_name = "cron" %}}
{{% endif %}}

documentation_complete: true

title: 'Enable cron Service'
Expand All @@ -6,7 +12,7 @@ description: |-
The <tt>crond</tt> service is used to execute commands at
preconfigured times. It is required by almost all systems to perform necessary
maintenance tasks, such as notifying root of system activity.
{{{ describe_service_enable(service="cron") }}}
{{{ describe_service_enable(service=service_name) }}}

rationale: |-
Due to its usage for maintenance and security-supporting tasks,
Expand Down Expand Up @@ -34,9 +40,14 @@ references:
nist-csf: PR.IP-1,PR.PT-3

ocil: |-
{{{ ocil_service_enabled(service="cron") }}}
{{{ ocil_service_enabled(service=service_name) }}}

template:
name: service_enabled
vars:
servicename: cron
servicename@rhel8: crond
servicename@rhel9: crond
servicename@rhel10: crond
packagename: cron
packagename@rhel10: cronie
Loading