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
c2db115e
Commit
c2db115e
authored
Feb 23, 2020
by
Knic Knic
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix formatting
parent
2346ccc6
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
78 additions
and
85 deletions
+78
-85
command.go
pkg/agent/containerd/command.go
+15
-15
command_windows.go
pkg/agent/containerd/command_windows.go
+7
-7
netpol_windows.go
pkg/agent/netpol/netpol_windows.go
+10
-11
setup_windows.go
pkg/agent/syssetup/setup_windows.go
+3
-4
rootless_windows.go
pkg/rootless/rootless_windows.go
+5
-9
controller_windows.go
pkg/rootlessports/controller_windows.go
+10
-11
file.go
pkg/util/file.go
+15
-15
file_windows.go
pkg/util/file_windows.go
+13
-13
No files found.
pkg/agent/containerd/command.go
View file @
c2db115e
// +build !windows
// +build !windows
package
containerd
package
containerd
import
(
import
(
"os/exec"
"os/exec"
"syscall"
"syscall"
)
)
func
addDeathSig
(
cmd
*
exec
.
Cmd
)
{
func
addDeathSig
(
cmd
*
exec
.
Cmd
)
{
// not supported in this OS
// not supported in this OS
cmd
.
SysProcAttr
=
&
syscall
.
SysProcAttr
{
cmd
.
SysProcAttr
=
&
syscall
.
SysProcAttr
{
Pdeathsig
:
syscall
.
SIGKILL
,
Pdeathsig
:
syscall
.
SIGKILL
,
}
}
}
}
pkg/agent/containerd/command_windows.go
View file @
c2db115e
package
containerd
package
containerd
import
"os/exec"
import
"os/exec"
func
addDeathSig
(
_
*
exec
.
Cmd
)
{
func
addDeathSig
(
_
*
exec
.
Cmd
)
{
// not supported in this OS
// not supported in this OS
}
}
pkg/agent/netpol/netpol_windows.go
View file @
c2db115e
package
netpol
package
netpol
import
(
import
(
"context"
"context"
daemonconfig
"github.com/rancher/k3s/pkg/daemons/config"
daemonconfig
"github.com/rancher/k3s/pkg/daemons/config"
)
)
func
Run
(
ctx
context
.
Context
,
nodeConfig
*
daemonconfig
.
Node
)
error
{
func
Run
(
ctx
context
.
Context
,
nodeConfig
*
daemonconfig
.
Node
)
error
{
panic
(
"Netpol is not supported on windows ensure to pass --disable-network-policy"
)
panic
(
"Netpol is not supported on windows ensure to pass --disable-network-policy"
)
}
}
\ No newline at end of file
pkg/agent/syssetup/setup_windows.go
View file @
c2db115e
package
syssetup
package
syssetup
func
Configure
()
{}
func
Configure
()
{}
\ No newline at end of file
pkg/rootless/rootless_windows.go
View file @
c2db115e
package
rootless
package
rootless
import
(
func
Rootless
(
stateDir
string
)
error
{
)
panic
(
"Rootless not supported on windows"
)
}
func
Rootless
(
stateDir
string
)
error
{
panic
(
"Rootless not supported on windows"
)
}
pkg/rootlessports/controller_windows.go
View file @
c2db115e
package
rootlessports
package
rootlessports
import
(
import
(
"context"
"context"
coreClients
"github.com/rancher/wrangler-api/pkg/generated/controllers/core/v1"
coreClients
"github.com/rancher/wrangler-api/pkg/generated/controllers/core/v1"
)
)
func
Register
(
ctx
context
.
Context
,
serviceController
coreClients
.
ServiceController
,
httpsPort
int
)
error
{
func
Register
(
ctx
context
.
Context
,
serviceController
coreClients
.
ServiceController
,
httpsPort
int
)
error
{
panic
(
"Rootless is not supported on windows"
)
panic
(
"Rootless is not supported on windows"
)
}
}
\ No newline at end of file
pkg/util/file.go
View file @
c2db115e
// +build !windows
// +build !windows
package
util
package
util
import
(
import
(
"os"
"os"
)
)
func
SetFileModeForPath
(
name
string
,
mode
os
.
FileMode
)
error
{
func
SetFileModeForPath
(
name
string
,
mode
os
.
FileMode
)
error
{
return
os
.
Chmod
(
name
,
mode
)
return
os
.
Chmod
(
name
,
mode
)
}
}
func
SetFileModeForFile
(
file
*
os
.
File
,
mode
os
.
FileMode
)
error
{
func
SetFileModeForFile
(
file
*
os
.
File
,
mode
os
.
FileMode
)
error
{
return
file
.
Chmod
(
mode
)
return
file
.
Chmod
(
mode
)
}
}
pkg/util/file_windows.go
View file @
c2db115e
package
util
package
util
import
(
import
(
"os"
"os"
)
)
func
SetFileModeForPath
(
name
string
,
mode
os
.
FileMode
)
error
{
func
SetFileModeForPath
(
name
string
,
mode
os
.
FileMode
)
error
{
return
nil
return
nil
}
}
func
SetFileModeForFile
(
file
*
os
.
File
,
mode
os
.
FileMode
)
error
{
func
SetFileModeForFile
(
file
*
os
.
File
,
mode
os
.
FileMode
)
error
{
return
nil
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