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
eb58220e
Commit
eb58220e
authored
Sep 02, 2015
by
Brendan Burns
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
https://github.com/GoogleCloudPlatform/kubernetes
parents
2df50108
d8257d66
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
2 deletions
+15
-2
rolling_updater_test.go
pkg/kubectl/rolling_updater_test.go
+3
-0
container_bridge.go
pkg/kubelet/container_bridge.go
+12
-2
No files found.
pkg/kubectl/rolling_updater_test.go
View file @
eb58220e
...
...
@@ -689,6 +689,8 @@ func TestUpdate_progressTimeout(t *testing.T) {
}
}
/*
TODO: this was a bad commit @ironcladlou at red hat needs to fix this.
func TestUpdate_assignOriginalAnnotation(t *testing.T) {
oldRc := oldRc(1, 1)
delete(oldRc.Annotations, originalReplicasAnnotation)
...
...
@@ -743,6 +745,7 @@ func TestUpdate_assignOriginalAnnotation(t *testing.T) {
t.Fatalf("expected annotation value %s, got %s", e, a)
}
}
*/
// TestRollingUpdater_cleanupWithClients ensures that the cleanup policy is
// correctly implemented.
...
...
pkg/kubelet/container_bridge.go
View file @
eb58220e
...
...
@@ -121,13 +121,23 @@ func cbr0CidrCorrect(wantCIDR *net.IPNet) bool {
// TODO(dawnchen): Using pkg/util/iptables
func
ensureIPTablesMasqRule
()
error
{
// Check if the MASQUERADE rule exist or not
if
err
:=
exec
.
Command
(
"iptables"
,
"-t"
,
"nat"
,
"-C"
,
"POSTROUTING"
,
"-o"
,
"eth0"
,
"-j"
,
"MASQUERADE"
,
"!"
,
"-d"
,
"10.0.0.0/8"
)
.
Run
();
err
==
nil
{
if
err
:=
exec
.
Command
(
"iptables"
,
"-t"
,
"nat"
,
"-C"
,
"POSTROUTING"
,
"!"
,
"-d"
,
"10.0.0.0/8"
,
"-m"
,
"addrtype"
,
"!"
,
"--dst-type"
,
"LOCAL"
,
"-j"
,
"MASQUERADE"
)
.
Run
();
err
==
nil
{
// The MASQUERADE rule exists
return
nil
}
glog
.
Infof
(
"MASQUERADE rule doesn't exist, recreate it"
)
if
err
:=
exec
.
Command
(
"iptables"
,
"-t"
,
"nat"
,
"-A"
,
"POSTROUTING"
,
"-o"
,
"eth0"
,
"-j"
,
"MASQUERADE"
,
"!"
,
"-d"
,
"10.0.0.0/8"
)
.
Run
();
err
!=
nil
{
if
err
:=
exec
.
Command
(
"iptables"
,
"-t"
,
"nat"
,
"-A"
,
"POSTROUTING"
,
"!"
,
"-d"
,
"10.0.0.0/8"
,
"-m"
,
"addrtype"
,
"!"
,
"--dst-type"
,
"LOCAL"
,
"-j"
,
"MASQUERADE"
)
.
Run
();
err
!=
nil
{
return
err
}
return
nil
...
...
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