Skip to content

Instantly share code, notes, and snippets.

@rafaelfoster
Last active August 29, 2015 14:09
Show Gist options
  • Save rafaelfoster/6654848f881b3600bd23 to your computer and use it in GitHub Desktop.
Save rafaelfoster/6654848f881b3600bd23 to your computer and use it in GitHub Desktop.
RHEL 7 - Firewall-cmd
#!/bin/bash
firewall-cmd --zone=internal --add-rich-rule="rule family=ipv4 source address=$SERVER_IP service name=$SERVICE_NAME accept"
# File: /etc/firewalld/services/zabbix.xml
<?xml version="1.0" encoding="utf-8"?>
<service>
<short>zabbix</short>
<description>Zabbix Agent</description>
<port protocol="tcp" port="10050"/>
</service>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment