Skip to content

Commit

Permalink
Merge pull request #6 from jasonnance/multiple-ports-same-service
Browse files Browse the repository at this point in the history
Add portpair to port-forward command key
  • Loading branch information
flowerinthenight authored Nov 30, 2020
2 parents 3a33611 + edc316c commit bd5ec2c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ func Run(cmd *cobra.Command, args []string) error {
addcmd = exec.Command("kubectl", "--context", ctx, "port-forward", "-n", parts[1], rctype+"/"+targetList[0], portpair)
}

key := fmt.Sprintf("%s:%s:%s", ctx, parts[1], name)
key := fmt.Sprintf("%s:%s:%s:%s", ctx, parts[1], name, portpair)
if _, ok := cs[key]; !ok {
cs[key] = addcmd
}
Expand Down

0 comments on commit bd5ec2c

Please sign in to comment.