New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

firewalld module should support creation of port forwards #28349

seafoodbuffet opened this Issue Aug 17, 2017 · 5 comments


None yet
6 participants

seafoodbuffet commented Aug 17, 2017

  • Feature Idea

firewalld module

  config file = /etc/ansible/ansible.cfg
  configured module search path = Default w/o overrides
  python version = 2.7.5 (default, Nov  6 2016, 00:28:07) [GCC 4.8.5 20150623 (Red Hat 4.8.5-11)]

The firewalld module doesn't seem to allow creation of port forwards (--add-forward-port). This would be a useful capability to add to the module.


This comment has been minimized.


ansibot commented Aug 17, 2017


This comment has been minimized.

geoffreywiseman commented Jan 25, 2018

And if it is supported already, better documentation -- since I also am inclined to believe the firewalld module doesn't support this.

@ansibot ansibot added feature and removed feature_idea labels Mar 2, 2018


This comment has been minimized.

mikehardenize commented Apr 30, 2018

Although I agree that the module needs updating to support this functionality explictly and/or include documentation, I thought it was worth me posting my solution to the problem in case others have the same issue:

- name: Redirect port 443 to 8443
    rich_rule: rule family={{ item }} forward-port port=443 protocol=tcp to-port=8443
    zone:      public
    permanent: true
    immediate: true
    state:     enabled
    - ipv4
    - ipv6

This comment has been minimized.


maxamillion commented Apr 30, 2018

@mikehardenize thanks for sharing, I'll update the examples in the firewalld module to include this.

I would like to add the port forward directive, but it's just a matter of finding the free time. I've recently pushed in a large refactor of the module up (#37603) and once that is merged, I'll add the port forward.


This comment has been minimized.


maxamillion commented Apr 30, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment