methods/in_osx.rb
# Check OS X dnsmasq (used for puppet)
Check OS X dnsmasq (used for puppet)
Check OS X dnsmasq ( used for puppet )
def check_osx_dnsmasq(options)
  pkg_name = "dnsmasq"
  install_brew_pkg(pkg_name)
  plist_file   = "/Library/LaunchDaemons/homebrew.mxcl.dnsmasq.plist"
  dnsmasq_file = "/usr/local/etc/dnsmasq.conf"
  if not File.exist?(plist_file)
    message = "Information:\tCreating Plist file "+plist_file+" for "+pkg_name
    command = "cp -fv /usr/local/opt/dnsmasq/*.plist /Library/LaunchDaemons"
    execute_command(options,message,command)
    message = "Information:\tCreating Configuration file "+plist_file
    command = "cp #{dnsmasq_file}.example #{dnsmasq_file}"
    execute_command(options,message,command)
    message = "Information:\tLoading Configuration for "+pkg_name
    command = "launchctl load -w #{plist_file}"
    execute_command(options,message,command)
  end
  return
end
def check_osx_dnsmasq ( options ) pkg_name = "dnsmasq" install_brew_pkg ( pkg_name ) plist_file = "/Library/LaunchDaemons/homebrew.mxcl.dnsmasq.plist" dnsmasq_file = "/usr/local/etc/dnsmasq.conf" if not File . exist? ( plist_file ) message = "Information:\tCreating Plist file " + plist_file + " for " + pkg_name command = "cp -fv /usr/local/opt/dnsmasq/*.plist /Library/LaunchDaemons" execute_command ( options , message , command ) message = "Information:\tCreating Configuration file " + plist_file command = "cp #{dnsmasq_file}.example #{dnsmasq_file}" execute_command ( options , message , command ) message = "Information:\tLoading Configuration for " + pkg_name command = "launchctl load -w #{plist_file}" execute_command ( options , message , command ) end return end
Check OS X dnsmasq (used for puppet)
Check OS X dnsmasq ( used for puppet )
options
<not_specific>