Skip to content

Conversation

sengo4hd
Copy link
Contributor

@sengo4hd sengo4hd commented Jul 12, 2025

  • Pull request is based on the default branch (3.x at this time)
  • Pull request includes tests for any new/updated operations/facts
  • Pull request includes documentation for any new/updated operations/facts
  • Tests pass (see scripts/dev-test.sh)
  • Type checking & code style passes (see scripts/dev-lint.sh)

Hello and thank you for your work on this project :)
I find the design to be very clear and well-thought, making it easy to engage with contributing.

I want to use pyinfra to enable a nftables service on the boot runlevel with OpenRC. I noticed that the openrc.service operation would always trigger a change on every run even though the service was never really enabled on this runlevel. This is because the change was always happening on the default runlevel, ignoring the configuration.

I would like to propose these changes:

  • A noop message for when a service is already enabled/disabled to help with troubleshooting.
  • Support for enabled/disabling services on a specific runlevel, as expected from the documentation.

I did not find it necessary to update the openrc.service documentation.
I also fixed a small typo in a link in the contributing documentation.

Copy link
Member

@Fizzadar Fizzadar left a comment

Choose a reason for hiding this comment

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

Very nice, thank you @sengo4hd!

@Fizzadar Fizzadar merged commit 6fa182d into pyinfra-dev:3.x Jul 29, 2025
52 checks passed
@sengo4hd sengo4hd deleted the openrc-runlevels branch August 5, 2025 07:47
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