Skip to content
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

nftables::rules::out::icmp::v4_types and v6_types prodcues errors #264

Open
pulven opened this issue Nov 25, 2024 · 1 comment
Open

nftables::rules::out::icmp::v4_types and v6_types prodcues errors #264

pulven opened this issue Nov 25, 2024 · 1 comment

Comments

@pulven
Copy link

pulven commented Nov 25, 2024

Affected Puppet, Ruby, OS and module versions/distributions

  • Module version: 4.0

How to reproduce (e.g Puppet code you use)

add this to you .yaml

nftables::rules::out::icmp::v4_types:
    - 'echo-reply'
    - 'destination-unreachable'
    - 'source-quench'

What are you seeing

Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Resource Statement, Duplicate declaration: Nftables::Rule[default_out-accept_icmpv4] is already declared at (file: .../modules/nftables/manifests/rules/out/icmp.pp, line: 14); cannot redeclare (file: .../modules/nftables/manifests/rules/out/icmp.pp, line: 14) (file: .../modules/nftables/manifests/rules/out/icmp.pp, line: 14, column: 7) on node ...

What behaviour did you expect instead

No error; the same beahivour as in

/modules/nftables/manifests/rules/icmp.pp

i.e. using the same naming scheme fixes the problem.

Any additional information you'd like to impart

its the same issue for v6_types too

@duritong
Copy link
Collaborator

Yeah, that never worked.

Introduced here: #16 - No tests for out rules, which is why it was never detected. And the correct way should be here: https://github.com/voxpupuli/puppet-nftables/pull/16/files#diff-c0adcf801153e99ee1b24f1f2120aa8080041d5b24b7f7c98a3ac72b458ed934R9

duritong added a commit to duritong/puppet-nftables that referenced this issue Nov 25, 2024
duritong added a commit to duritong/puppet-nftables that referenced this issue Nov 25, 2024
… types

Add tests for nftables::rules::out:icmp to avoid regressions.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants