Method: Beaker::HostPrebuiltSteps#disable_iptables
- Defined in:
- lib/beaker/host_prebuilt_steps.rb
#disable_iptables(host, opts) ⇒ Object
Disable iptables on centos, does nothing on other platforms
457 458 459 460 461 462 463 464 465 466 467 |
# File 'lib/beaker/host_prebuilt_steps.rb', line 457 def disable_iptables host, opts logger = opts[:logger] block_on host do |host| if host['platform'] =~ /centos|el-|redhat|fedora|eos/ logger.debug("Disabling iptables on #{host.name}") host.exec(Command.new("sudo su -c \"/etc/init.d/iptables stop\""), {:pty => true}) else logger.warn("Attempting to disable iptables on non-supported platform: #{host.name}: #{host['platform']}") end end end |