Skip to content

lib/facter/systemd: Also include masked services#632

Open
b4ldr wants to merge 1 commit into
voxpupuli:masterfrom
icann-dns:fact_masked_services
Open

lib/facter/systemd: Also include masked services#632
b4ldr wants to merge 1 commit into
voxpupuli:masterfrom
icann-dns:fact_masked_services

Conversation

@b4ldr

@b4ldr b4ldr commented Jun 4, 2026

Copy link
Copy Markdown
Member

update the systemd flag to also include services in the masked state

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

This PR updates the systemd_internal_services Facter fact to include unit files in the masked state when querying systemctl list-unit-files, ensuring masked internal systemd services are surfaced in the returned hash.

Changes:

  • Extend the systemctl list-unit-files --state= filter to include masked.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread lib/facter/systemd.rb
Comment thread lib/facter/systemd.rb
Comment on lines 55 to 57
command_output = Facter::Util::Resolution.exec(
'systemctl list-unit-files --no-legend --no-pager "systemd-*" -t service --state=enabled,disabled,enabled-runtime,indirect',
'systemctl list-unit-files --no-legend --no-pager "systemd-*" -t service --state=enabled,disabled,enabled-runtime,indirect,masked',
)
@b4ldr b4ldr force-pushed the fact_masked_services branch from 9af5074 to ab35537 Compare June 9, 2026 22:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants