File tree Expand file tree Collapse file tree 1 file changed +7
-5
lines changed
acceptance/tests/resource/service Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change 2525
2626agents . each do |agent |
2727 platform = agent . platform . variant
28+ init_script_systemd = "/usr/lib/systemd/system/#{ package_name [ platform ] } .service"
2829
29- if agent [ 'platform' ] =~ /ubuntu-24.04-amd64/
30- init_script_systemd = "/usr/lib/systemd/system/#{ package_name [ platform ] } .service"
31- elsif agent [ 'platform' ] =~ /(debian|ubuntu)/
30+ if agent [ 'platform' ] =~ /(ubuntu)/
31+ version = on ( agent , facter ( 'os.release.full' ) ) . stdout . chomp . to_i
32+ if version < 24
33+ init_script_systemd = "/lib/systemd/system/#{ package_name [ platform ] } .service"
34+ end
35+ elsif agent [ 'platform' ] =~ /debian/
3236 init_script_systemd = "/lib/systemd/system/#{ package_name [ platform ] } .service"
33- else
34- init_script_systemd = "/usr/lib/systemd/system/#{ package_name [ platform ] } .service"
3537 end
3638
3739 symlink_systemd = "/etc/systemd/system/multi-user.target.wants/#{ package_name [ platform ] } .service"
You can’t perform that action at this time.
0 commit comments