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

systemd::unit_file: Ensure link gets removed on ensure => absent #405

Merged
merged 2 commits into from Mar 11, 2024

Conversation

baurmatt
Copy link
Contributor

@baurmatt baurmatt commented Jan 22, 2024

Pull Request (PR) description

Currently the systemd::unit_file type ignores the ensure parameter if target is defined. This allows the ensure parameter to be absent and thus removing the unit file if target is set.

This Pull Request (PR) fixes the following issues

@kenyon kenyon changed the title systemd::unit_file, Ensure link get's removed on ensure = absent systemd::unit_file, Ensure link gets removed on ensure => absent Mar 7, 2024
@kenyon kenyon changed the title systemd::unit_file, Ensure link gets removed on ensure => absent systemd::unit_file: Ensure link gets removed on ensure => absent Mar 7, 2024
manifests/unit_file.pp Outdated Show resolved Hide resolved
@baurmatt baurmatt force-pushed the unit_file_ensure_absent_link branch from e300262 to 7f63dfa Compare March 7, 2024 08:04
@kenyon kenyon added the enhancement New feature or request label Mar 11, 2024
@baurmatt baurmatt merged commit b72cca8 into master Mar 11, 2024
34 checks passed
@baurmatt baurmatt deleted the unit_file_ensure_absent_link branch March 11, 2024 08:12
baurmatt added a commit that referenced this pull request Mar 11, 2024
@cocker-cc correctly mentioned in
7f63dfa#commitcomment-139614892
that after #405 `ensure=file` breaks due to `stdlib::ensure` not being
able to handle that. As `file` is any way only a synonym for `present`,
let's just remove it from the possible values.
baurmatt added a commit that referenced this pull request Mar 12, 2024
@cocker-cc correctly mentioned in
7f63dfa#commitcomment-139614892
that after #405 `ensure=file` breaks due to `stdlib::ensure` not being
able to handle that. As `file` is any way only a synonym for `present`,
let's just remove it from the possible values.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants