Skip to content

Conversation

@tamilmani1989
Copy link
Member

  1. ip6table cmd support
  2. wiat falg with timeout

What this PR does / why we need it:
This PR adds following support:

  1. ip6tables command support without changing function signature
  2. Wait flag with timeout parameter
  3. Added few more constants to support specific iptable rules

Which issue this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close that issue when PR gets merged): fixes #

Special notes for your reviewer:

Release note:

1. ip6table cmd support
2. wiat falg with timeout
@tamilmani1989 tamilmani1989 changed the title Added more feature is iptm package Added more feature in iptm package Apr 24, 2019
@tamilmani1989 tamilmani1989 requested a review from saiyan86 April 24, 2019 21:46
@tamilmani1989 tamilmani1989 changed the title Added more feature in iptm package Added more features in iptm package Apr 24, 2019
@codecov
Copy link

codecov bot commented Apr 24, 2019

Codecov Report

Merging #342 into master will increase coverage by 0.04%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #342      +/-   ##
==========================================
+ Coverage   45.18%   45.22%   +0.04%     
==========================================
  Files          25       25              
  Lines        3539     3542       +3     
==========================================
+ Hits         1599     1602       +3     
  Misses       1685     1685              
  Partials      255      255
Impacted Files Coverage Δ
npm/iptm/iptm.go 55.42% <100%> (+0.54%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 9d8a280...bc1be67. Read the comment docs.


waitFlag := fmt.Sprintf("%s %s", util.IptablesWaitFlag, entry.LockWaitTimeInSeconds)
waitFlag = strings.TrimSpace(waitFlag)
cmdArgs := append([]string{waitFlag, iptMgr.OperationFlag, entry.Chain}, entry.Specs...)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about

append([]string{util.IptablesWaitFlag, entry.LockWaitTimeInSeconds, iptMgr.OperationFlag, entry.Chain}, entry.Specs...)

if you think the line is too long, we can line break too.
This way we don't need to import fmt & strings packages.

@tamilmani1989 tamilmani1989 merged commit 9cfec88 into Azure:master Apr 24, 2019
tamilmani1989 added a commit that referenced this pull request Apr 24, 2019
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

Successfully merging this pull request may close these issues.

2 participants