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

chore(redhat): handle CentOS Stream releases #6216

Closed
wants to merge 4 commits into from

Conversation

YoannGh
Copy link

@YoannGh YoannGh commented Feb 27, 2024

Description

This PR adds support for the CentOS Stream OS type family and detects it through the existing CentOS analyzer.
It uses the CentOS Stream prefix in the /etc/centos-release file to detect this OS type family.

$ cat /etc/centos-release 
CentOS Stream release 9

Related issues

  • Close #XXX

Checklist

  • I've read the guidelines for contributing to this repository.
  • I've followed the conventions in the PR title.
  • I've added tests that prove my fix is effective or that my feature works.
  • I've updated the documentation with the relevant information (if needed).
  • I've added usage information (if the PR introduces new options)
  • I've included a "before" and "after" example to the description (if the PR is a user interface change).

@CLAassistant
Copy link

CLAassistant commented Feb 27, 2024

CLA assistant check
All committers have signed the CLA.

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@YoannGh YoannGh changed the title chore(centos): handle CentOS Stream os-release chore(redhat): handle CentOS Stream os-release Feb 27, 2024
@YoannGh YoannGh changed the title chore(redhat): handle CentOS Stream os-release chore(redhat): handle CentOS Stream releases Feb 27, 2024
@knqyf263
Copy link
Collaborator

CentOS and CentOS stream have different relationships to RHEL and Fedora. I believe it should not be treated in the same way as CentOS, as the security advisories are also different.

difference

What if adding a new family for CentOS Stream?

@YoannGh
Copy link
Author

YoannGh commented Feb 28, 2024

@knqyf263 my last commit adds a new CentOSStream OS type family and makes use of it in the centos analyzer.
Let me know if that suits what you want

Copy link
Collaborator

@knqyf263 knqyf263 left a comment

Choose a reason for hiding this comment

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

I think we should also think about EOL.

redhatEOLDates = map[string]time.Time{
"4": time.Date(2017, 5, 31, 23, 59, 59, 0, time.UTC),
"5": time.Date(2020, 11, 30, 23, 59, 59, 0, time.UTC),
"6": time.Date(2024, 6, 30, 23, 59, 59, 0, time.UTC),
// N/A
"7": time.Date(3000, 1, 1, 23, 59, 59, 0, time.UTC),
"8": time.Date(3000, 1, 1, 23, 59, 59, 0, time.UTC),
"9": time.Date(3000, 1, 1, 23, 59, 59, 0, time.UTC),
}
centosEOLDates = map[string]time.Time{
"3": time.Date(2010, 10, 31, 23, 59, 59, 0, time.UTC),
"4": time.Date(2012, 2, 29, 23, 59, 59, 0, time.UTC),
"5": time.Date(2017, 3, 31, 23, 59, 59, 0, time.UTC),
"6": time.Date(2020, 11, 30, 23, 59, 59, 0, time.UTC),
"7": time.Date(2024, 6, 30, 23, 59, 59, 0, time.UTC),
"8": time.Date(2021, 12, 31, 23, 59, 59, 0, time.UTC),
}

Now, I'm confused about its security advisories. CentOS Stream is ahead of RHEL, but the FAQ mentioned as below.

Security issues will be updated in CentOS Stream after they are solved in the current RHEL release

https://centos.org/distro-faq/

It sounds like the same as CentOS.
@YoannGh Do you know anything?

Copy link

github-actions bot commented May 4, 2024

This PR is stale because it has been labeled with inactivity.

@github-actions github-actions bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and will be auto-closed. label May 4, 2024
@github-actions github-actions bot closed this May 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lifecycle/stale Denotes an issue or PR has remained open with no activity and will be auto-closed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants