Commit Graph

12 Commits

Author SHA1 Message Date
Sascha Grunert
2aa9e76be1
Move pkg/kubelet/cri/remote to cri-client
Signed-off-by: Sascha Grunert <sgrunert@redhat.com>
2024-05-14 10:58:18 +02:00
Tim Hockin
6dbc754ed6
Retool typecheck to be simpler
Instead of walking paths ourselves, just let Go's packages library do
it.  This is a slight CLI change - it wants "./foo" rather than "foo".

This also flagged a few things which seem to be legit failures.
2024-02-29 22:07:00 -08:00
Claudiu Belu
b4d1440063 unittests: Fixes hostutil.GetFileType for Windows
GetFileType is meant to return the type of the given file by using os.Stat.
However, os.Stat doesn't work on Windows for Unix Sockets, causing an error to occur:

[2-Socket Test] unexpected error :
CreateFile C:\Users\Administrator\AppData\Local\Temp\test-get-filetype-2776877299\mt.sock:
The file cannot be accessed by the system.

This is a known issue and we're already using a workaround for this in
pkg/kubelet/util/util_windows.go.

This commit fixes this issue for GetFileType on Windows.
2023-06-01 16:02:07 +00:00
Claudiu Belu
11f1d24165 unit tests: Fixes kubelet util unit tests for Windows
The unit tests are currently failing due to missing imports. This commit
addresses this issue.

Additionally, TestIsUnixDomainSocket expects an error to be raised by
IsUnixDomainSocket if the file does not exist, but on Windows we do not
raise such error.

This issue is addressed by Stat-ing the file, and checking
if the file exists or not. We're also handling the case in which the given
filePath is a named pipe, returning false immediately, instead of trying to
dial it as a Unix domain socket.
2023-05-10 11:25:49 +00:00
Francesco Romani
6b4ffdb9f7 node: re-implement Localendpoint on windows
this will allows us to move forward with the podresources
endpoint GA graduation.

xref: https://github.com/kubernetes/kubernetes/issues/78628

Signed-off-by: Francesco Romani <fromani@redhat.com>
2023-03-14 22:39:56 +01:00
Claudiu Belu
5cce4bccad tests: Port kubelet tests to Windows
Ports kubelet/util unit tests to Windows.
2023-02-09 13:50:51 +00:00
inosato
3b95d3b076 Remove ioutil in kubelet and its tests
Signed-off-by: inosato <si17_21@yahoo.co.jp>
2022-07-30 12:35:26 +09:00
Mihai Albert
c666656259 Add retry logic for Unix Domain sockets on Windows 2022-06-10 00:59:55 +03:00
Stephen Augustus
481cf6fbe7
generated: Run hack/update-gofmt.sh
Signed-off-by: Stephen Augustus <foo@auggie.dev>
2021-08-24 15:47:49 -04:00
ESWZY
9ce4dfe6d2 Add test for pkg/kubelet/util/util_windows_test.go#GetAddressAndDialer 2020-08-13 01:17:00 +08:00
Deep Debroy
1321c9115b Support PluginWatcher in Windows
Signed-off-by: Deep Debroy <ddebroy@docker.com>
2019-08-27 16:24:38 -07:00
Pengfei Ni
053b71d5d2 Switch windows runtime endpoints to npipe 2018-10-22 21:28:36 +08:00