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
52323cba
Commit
52323cba
authored
Feb 13, 2025
by
Roberto Bonafiglia
Committed by
Roberto Bonafiglia
Mar 05, 2025
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Revert "Add ability to pass configuration options to flannel backend"
This reverts commit
86435769
. Signed-off-by:
Roberto Bonafiglia
<
roberto.bonafiglia@suse.com
>
parent
b86a6947
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
13 deletions
+2
-13
setup.go
pkg/agent/flannel/setup.go
+2
-13
No files found.
pkg/agent/flannel/setup.go
View file @
52323cba
...
@@ -48,8 +48,7 @@ const (
...
@@ -48,8 +48,7 @@ const (
wireguardNativeBackend
=
`{
wireguardNativeBackend
=
`{
"Type": "wireguard",
"Type": "wireguard",
"PersistentKeepaliveInterval": %PersistentKeepaliveInterval%,
"PersistentKeepaliveInterval": 25
"Mode": "%Mode%"
}`
}`
emptyIPv6Network
=
"::/0"
emptyIPv6Network
=
"::/0"
...
@@ -210,7 +209,6 @@ func createFlannelConf(nodeConfig *config.Node) error {
...
@@ -210,7 +209,6 @@ func createFlannelConf(nodeConfig *config.Node) error {
}
}
var
backendConf
string
var
backendConf
string
backendOptions
:=
make
(
map
[
string
]
string
)
// precheck and error out unsupported flannel backends.
// precheck and error out unsupported flannel backends.
switch
nodeConfig
.
FlannelBackend
{
switch
nodeConfig
.
FlannelBackend
{
...
@@ -241,16 +239,7 @@ func createFlannelConf(nodeConfig *config.Node) error {
...
@@ -241,16 +239,7 @@ func createFlannelConf(nodeConfig *config.Node) error {
}
}
backendConf
=
strings
.
ReplaceAll
(
tailscaledBackend
,
"%Routes%"
,
routes
)
backendConf
=
strings
.
ReplaceAll
(
tailscaledBackend
,
"%Routes%"
,
routes
)
case
config
.
FlannelBackendWireguardNative
:
case
config
.
FlannelBackendWireguardNative
:
mode
,
ok
:=
backendOptions
[
"Mode"
]
backendConf
=
wireguardNativeBackend
if
!
ok
{
mode
=
"separate"
}
keepalive
,
ok
:=
backendOptions
[
"PersistentKeepaliveInterval"
]
if
!
ok
{
keepalive
=
"25"
}
backendConf
=
strings
.
ReplaceAll
(
wireguardNativeBackend
,
"%Mode%"
,
mode
)
backendConf
=
strings
.
ReplaceAll
(
backendConf
,
"%PersistentKeepaliveInterval%"
,
keepalive
)
default
:
default
:
return
fmt
.
Errorf
(
"Cannot configure unknown flannel backend '%s'"
,
nodeConfig
.
FlannelBackend
)
return
fmt
.
Errorf
(
"Cannot configure unknown flannel backend '%s'"
,
nodeConfig
.
FlannelBackend
)
}
}
...
...
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