Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
69398f84
Commit
69398f84
authored
Jun 12, 2018
by
Weibin Lin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Get ipv6 nodeIP when in ipv6 cluster
parent
bababe08
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
server_others.go
cmd/kube-proxy/app/server_others.go
+5
-5
No files found.
cmd/kube-proxy/app/server_others.go
View file @
69398f84
...
@@ -136,12 +136,12 @@ func newProxyServer(
...
@@ -136,12 +136,12 @@ func newProxyServer(
var
endpointsEventHandler
proxyconfig
.
EndpointsHandler
var
endpointsEventHandler
proxyconfig
.
EndpointsHandler
proxyMode
:=
getProxyMode
(
string
(
config
.
Mode
),
iptInterface
,
kernelHandler
,
ipsetInterface
,
iptables
.
LinuxKernelCompatTester
{})
proxyMode
:=
getProxyMode
(
string
(
config
.
Mode
),
iptInterface
,
kernelHandler
,
ipsetInterface
,
iptables
.
LinuxKernelCompatTester
{})
nodeIP
:=
net
.
ParseIP
(
config
.
BindAddress
)
if
nodeIP
.
IsUnspecified
()
{
nodeIP
=
getNodeIP
(
client
,
hostname
)
}
if
proxyMode
==
proxyModeIPTables
{
if
proxyMode
==
proxyModeIPTables
{
glog
.
V
(
0
)
.
Info
(
"Using iptables Proxier."
)
glog
.
V
(
0
)
.
Info
(
"Using iptables Proxier."
)
nodeIP
:=
net
.
ParseIP
(
config
.
BindAddress
)
if
nodeIP
.
Equal
(
net
.
IPv4zero
)
||
nodeIP
.
Equal
(
net
.
IPv6zero
)
{
nodeIP
=
getNodeIP
(
client
,
hostname
)
}
if
config
.
IPTables
.
MasqueradeBit
==
nil
{
if
config
.
IPTables
.
MasqueradeBit
==
nil
{
// MasqueradeBit must be specified or defaulted.
// MasqueradeBit must be specified or defaulted.
return
nil
,
fmt
.
Errorf
(
"unable to read IPTables MasqueradeBit from config"
)
return
nil
,
fmt
.
Errorf
(
"unable to read IPTables MasqueradeBit from config"
)
...
@@ -194,7 +194,7 @@ func newProxyServer(
...
@@ -194,7 +194,7 @@ func newProxyServer(
int
(
*
config
.
IPTables
.
MasqueradeBit
),
int
(
*
config
.
IPTables
.
MasqueradeBit
),
config
.
ClusterCIDR
,
config
.
ClusterCIDR
,
hostname
,
hostname
,
getNodeIP
(
client
,
hostname
)
,
nodeIP
,
recorder
,
recorder
,
healthzServer
,
healthzServer
,
config
.
IPVS
.
Scheduler
,
config
.
IPVS
.
Scheduler
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment