Showing with 155,134 additions and 609 deletions.
  1. +1 −1 .msync.yml
  2. +34 −1 CHANGELOG.md
  3. +1 −1 Gemfile
  4. +39 −0 README.md
  5. +845 −431 REFERENCE.md
  6. +1 −1 Rakefile
  7. +2 −0 data/Debian-11.yaml
  8. +0 −5 data/Debian-8.yaml
  9. +0 −5 data/Debian-9.yaml
  10. +2 −0 data/Ubuntu-20.04.yaml
  11. +4 −0 data/{Ubuntu-16.04.yaml → Ubuntu-22.04.yaml}
  12. +3 −3 lib/facter/systemd.rb
  13. +76 −0 lib/facter/udev.rb
  14. +25 −0 lib/facter/udevadm.rb
  15. +3 −3 manifests/dropin_file.pp
  16. +6 −2 manifests/init.pp
  17. +6 −0 manifests/install.pp
  18. +66 −0 manifests/manage_dropin.pp
  19. +80 −0 manifests/manage_unit.pp
  20. +4 −3 manifests/resolved.pp
  21. +7 −12 manifests/service_limits.pp
  22. +1 −8 manifests/timesyncd.pp
  23. +5 −23 manifests/unit_file.pp
  24. +5 −7 metadata.json
  25. +7 −0 spec/classes/init_spec.rb
  26. +60 −0 spec/defines/manage_dropin_spec.rb
  27. +65 −0 spec/defines/manage_unit_spec.rb
  28. +18 −14 spec/defines/service_limits_spec.rb
  29. +0 −83 spec/defines/unit_file_spec.rb
  30. +40,284 −0 spec/fixtures/udevdb/almalinux8-supermicro-1114S-WN10RT.txt
  31. +51,428 −0 spec/fixtures/udevdb/almalinux9-supermicro-1114S-WN10RT.txt
  32. +40,517 −0 spec/fixtures/udevdb/centos7-supermicro-1114S-WN10RT.txt
  33. +20,703 −0 spec/fixtures/udevdb/fedora37-supermicro-X10SRA-F.txt
  34. +2 −0 spec/spec_helper.rb
  35. +2 −1 spec/type_aliases/systemd_servicelimits_spec.rb
  36. +19 −0 spec/type_aliases/systemd_unit_install_spec.rb
  37. +92 −0 spec/type_aliases/systemd_unit_service_exec_spec.rb
  38. +23 −0 spec/type_aliases/systemd_unit_service_spec.rb
  39. +45 −0 spec/type_aliases/systemd_unit_unit_spec.rb
  40. +32 −0 spec/type_aliases/unit_spec.rb
  41. +3 −3 spec/unit/facter/systemd_spec.rb
  42. +448 −0 spec/unit/facter/udev_spec.rb
  43. +44 −0 spec/unit/facter/udevadm_spec.rb
  44. +32 −0 templates/unit_file.epp
  45. +1 −0 types/servicelimits.pp
  46. +3 −2 types/unit.pp
  47. +11 −0 types/unit/install.pp
  48. +43 −0 types/unit/service.pp
  49. +12 −0 types/unit/service/exec.pp
  50. +24 −0 types/unit/unit.pp
2 changes: 1 addition & 1 deletion .msync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
# Managed by modulesync - DO NOT EDIT
# https://voxpupuli.org/docs/updating-files-managed-with-modulesync/

modulesync_config_version: '5.3.0'
modulesync_config_version: '5.4.0'
35 changes: 34 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,39 @@ All notable changes to this project will be documented in this file.
Each new release typically also includes the latest modulesync defaults.
These should not affect the functionality of the module.

## [v4.0.0](https://github.com/voxpupuli/puppet-systemd/tree/v4.0.0) (2023-01-27)

[Full Changelog](https://github.com/voxpupuli/puppet-systemd/compare/v3.10.0...v4.0.0)

**Breaking changes:**

- drop support for fedora 30 & 31 \(EOL\) [\#310](https://github.com/voxpupuli/puppet-systemd/pull/310) ([jhoblitt](https://github.com/jhoblitt))
- drop support for ubuntu 16.04 \(EOL\) [\#308](https://github.com/voxpupuli/puppet-systemd/pull/308) ([jhoblitt](https://github.com/jhoblitt))
- drop debian 9 support \(EOL\) [\#307](https://github.com/voxpupuli/puppet-systemd/pull/307) ([jhoblitt](https://github.com/jhoblitt))
- Remove debian 8 support [\#305](https://github.com/voxpupuli/puppet-systemd/pull/305) ([traylenator](https://github.com/traylenator))
- systemd::unit\_file: remove hasrestart/hasstatus params [\#264](https://github.com/voxpupuli/puppet-systemd/pull/264) ([bastelfreak](https://github.com/bastelfreak))
- Remove restart\_service on service\_limits define [\#193](https://github.com/voxpupuli/puppet-systemd/pull/193) ([ekohl](https://github.com/ekohl))

**Implemented enhancements:**

- Revisit setting daemon-reload to true by default [\#284](https://github.com/voxpupuli/puppet-systemd/issues/284)
- The module should have the ability to reload services that have outdated unit dropin files [\#282](https://github.com/voxpupuli/puppet-systemd/issues/282)
- Add restart\_service parameter on service\_limits for compatibility [\#313](https://github.com/voxpupuli/puppet-systemd/pull/313) ([ekohl](https://github.com/ekohl))
- add support for fedora 36 & 37 [\#309](https://github.com/voxpupuli/puppet-systemd/pull/309) ([jhoblitt](https://github.com/jhoblitt))
- Allow MemorySwapMax to be specified as service limit [\#304](https://github.com/voxpupuli/puppet-systemd/pull/304) ([traylenator](https://github.com/traylenator))
- add udevadm & udev facts [\#292](https://github.com/voxpupuli/puppet-systemd/pull/292) ([jhoblitt](https://github.com/jhoblitt))
- Make Systemd::Unit type stricter [\#290](https://github.com/voxpupuli/puppet-systemd/pull/290) ([traylenator](https://github.com/traylenator))
- New systemd::manage\_unit, systemd::manage\_dropin types [\#288](https://github.com/voxpupuli/puppet-systemd/pull/288) ([traylenator](https://github.com/traylenator))
- Add support for Ubuntu 22.04 [\#278](https://github.com/voxpupuli/puppet-systemd/pull/278) ([simondeziel](https://github.com/simondeziel))
- Notify services by default on drop in files [\#194](https://github.com/voxpupuli/puppet-systemd/pull/194) ([ekohl](https://github.com/ekohl))

**Fixed bugs:**

- systemd-timesyncd package should be managed, if required [\#294](https://github.com/voxpupuli/puppet-systemd/issues/294)
- feat: manage timesyncd package on Debian \>= 11 and Ubuntu \>= 20.04 [\#296](https://github.com/voxpupuli/puppet-systemd/pull/296) ([saz](https://github.com/saz))
- resolved: `onlyif` snippet requires shell support [\#293](https://github.com/voxpupuli/puppet-systemd/pull/293) ([simondeziel](https://github.com/simondeziel))
- Correct docs for name var of systemd::dropin\_file [\#289](https://github.com/voxpupuli/puppet-systemd/pull/289) ([traylenator](https://github.com/traylenator))

## [v3.10.0](https://github.com/voxpupuli/puppet-systemd/tree/v3.10.0) (2022-06-20)

[Full Changelog](https://github.com/voxpupuli/puppet-systemd/compare/v3.9.0...v3.10.0)
Expand Down Expand Up @@ -172,7 +205,7 @@ These should not affect the functionality of the module.

**Implemented enhancements:**

- Add support for strict mode for DNS over TLS [\#200](https://github.com/voxpupuli/puppet-systemd/pull/200) ([wobblesprout](https://github.com/wobblesprout))
- Add support for strict mode for DNS over TLS [\#200](https://github.com/voxpupuli/puppet-systemd/pull/200) ([ghost](https://github.com/ghost))

**Merged pull requests:**

Expand Down
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ group :test do
gem 'voxpupuli-test', '~> 5.4', :require => false
gem 'coveralls', :require => false
gem 'simplecov-console', :require => false
gem 'puppet_metadata', '~> 1.0', :require => false
gem 'puppet_metadata', '~> 2.0', :require => false
end

group :development do
Expand Down
39 changes: 39 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,30 @@ systemd::unit_file { 'foo.service':
}
```

### unit files from parameters

Create a unit file from parameters

```puppet
systemd::manage_unit { 'myrunner.service':
$unit_entry => {
'Description' => 'My great service',
},
$service_entry => {
'Type' => 'oneshot',
'ExecStart' => '/usr/bin/doit.sh',
},
$install_entry => {
'WantedBy' => 'multi-user.target',
},
enable => true,
active => true,
}
```

The parameters `unit_entry`, `service_entry` and `install_entry` populate the
`[Unit]`, `[Service]` and `[Install]` sections of the generated unit file.

### drop-in files

Drop-in files are used to add or alter settings of a unit without modifying the
Expand Down Expand Up @@ -105,6 +129,21 @@ systemd::dropin_files:
source: puppet:///modules/${module_name}/foo.conf
```
### drop-in files from parameters
```puppet
systemd::manage_dropin { 'myconf.conf':
ensure => present,
unit => 'myservice.service',
service_entry => {
'Type' => 'oneshot',
'ExecStart' => ['', '/usr/bin/doit.sh'],
},
}
```

The filename of the drop in. The full path is determined using the path, unit and this filename.

### modules-load.d

Create a file entry for modules-loads directory and start
Expand Down
Loading