Skip to content
Browse files

Manage tftp via systemd on openSUSE 12.3

Enabling it via chkconfig and xinetd doesn't work on 12.3 anymore
  • Loading branch information...
1 parent 1a50a63 commit 5682fe0e0d770d02a2144ada8628380bf5a708ff @rhafer rhafer committed
Showing with 9 additions and 3 deletions.
  1. +9 −3 chef/cookbooks/provisioner/recipes/setup_base_images.rb
View
12 chef/cookbooks/provisioner/recipes/setup_base_images.rb
@@ -144,15 +144,21 @@
if node[:platform] == "suse"
service "tftp" do
- # just enable, don't start (xinetd takes care of it)
enabled true
- action [ :enable ]
+ if node[:platform_version].to_f >= 12.3
+ provider Chef::Provider::Service::Systemd
+ service_name "tftp.socket"
+ action [ :enable, :start ]
+ else
+ # on older releases just enable, don't start (xinetd takes care of it)
+ action [ :enable ]
+ end
end
service "xinetd" do
running true
enabled true
action [ :enable, :start ]
- end
+ end unless node[:platform_version].to_f >= 12.3
else
bluepill_service "tftpd" do
variables(:processes => [ {

0 comments on commit 5682fe0

Please sign in to comment.
Something went wrong with that request. Please try again.