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

Removing check for chkconfig #7861

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
3 changes: 1 addition & 2 deletions cache-config/t3c-apply/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -681,8 +681,7 @@ func getOSSvcManagement() SvcManagement {
_svcManager = SystemD
} else if isCommandAvailable(Service) {
_svcManager = SystemV
}
if !isCommandAvailable(Chkconfig) {
} else {
Copy link
Contributor

Choose a reason for hiding this comment

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

Since systemV needs chkconfig maybe we should do this.

if _svcManager == SystemV && !isCommandAvailable(Chkconfig) {
		return Unknown
	}

Copy link
Contributor

Choose a reason for hiding this comment

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

Do we support System V? That's older than me. Far as I'm aware we only support RHEL 7, 8 & 9 (and only some of those distros and only to varying degrees, for whatever reason).

Copy link
Contributor

Choose a reason for hiding this comment

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

That is true, I think you have to go back to RHEL 6 for System V. That said, we could probably remove the System V check too and just return unknown if it's not System D.

Copy link
Contributor

Choose a reason for hiding this comment

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

Does that sound good to you, @smalenfant?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Centos/Rocky 7,8 and 9 support chkconfig. Just depends if it's installed or not. That's the wrong way to detect which service manager is installed. This is really up to the software used (ATS) and how it's been packaged. I think we should remove these checks entirely as they seem invalid and just use systemctl by default.

Using systemctl for SystemV type works anyway. By removing, we just don't support Centos 6 anymore

return Unknown
}

Expand Down