Commit Graph

11 Commits

Author SHA1 Message Date
Kubernetes Prow Robot
7824ac0f3e
Merge pull request #114336 from claudiubelu/fixes-test-get-file-type
unittests: Fixes hostutil.GetFileType for Windows
2023-10-17 20:07:39 +02:00
Gunju Kim
b94fa250c2
Sidecar: Implement lifecycle of the restartable init container
- Implement `computeInitContainerActions` to sets the actions for the
  init containers, including those with `RestartPolicyAlways`.
- Allow StartupProbe on the restartable init containers.
- Update PodPhase considering the restartable init containers.
- Update PodInitialized status and status manager considering the
  restartable init containers.

Co-authored-by: Matthias Bertschy <matthias.bertschy@gmail.com>
2023-07-08 07:26:12 +09: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
auxten
a9c1acc044 Fix staticchecks ST1005,S1002,S1008,S1039 in pkg/kubelet 2020-09-07 10:53:43 +08:00
Javier Diaz-Montes
9743cda4a7 Adding Kubelet changes to enable SetHostnameAsFQDN feature
These changes allow to set FQDN as hostname of pods for pods
that set the new PodSpec field setHostnameAsFQDN to true. The PodSpec
new field was added in related PR.

This is PART2 (last) of the changes to enable KEP #1797 and addresses #91036
2020-06-14 21:26:27 -04:00
Pengfei Ni
053b71d5d2 Switch windows runtime endpoints to npipe 2018-10-22 21:28:36 +08:00
Jordan Liggitt
3fafdb7001
Detect backsteps correctly in base path detection
Avoid false positives with atomic writer ..<timestamp> directories
2018-03-13 02:23:06 -04:00
Jan Safranek
5110db5087 Lock subPath volumes
Users must not be allowed to step outside the volume with subPath.
Therefore the final subPath directory must be "locked" somehow
and checked if it's inside volume.

On Windows, we lock the directories. On Linux, we bind-mount the final
subPath into /var/lib/kubelet/pods/<uid>/volume-subpaths/<container name>/<subPathName>,
it can't be changed to symlink user once it's bind-mounted.
2018-03-05 09:14:44 +01:00
carlory
7831085e13 func parseEndpointWithFallbackProtocol should check if protocol of endpoint is empty. 2017-06-06 17:28:15 +08:00
Dong Liu
fb26c9100a Support TCP type runtime endpoint for kubelet. 2017-05-25 09:16:11 +08:00
Wojciech Tyczynski
220cfdff91 Optimize secret manager to refresh secrets from apiserver cache 2017-01-26 20:54:45 +01:00