Commit Graph

184 Commits (master)

Author SHA1 Message Date
Priya Modali 43cc1a2581 Resolved merg conflicts. 2020-10-02 14:10:55 -07:00
Priya Modali 97d96bf925 Switching from glob library to klog library. 2020-09-29 15:49:41 -07:00
Medya Gh f0f10d6135 first version 2020-09-29 14:14:24 -07:00
Sharif Elgamal b98580c820 fix up if statement 2020-09-17 10:31:10 -07:00
Sharif Elgamal eab92dc455 Reduce cyclotomic complexity of CreateContainerNode to fix lint 2020-09-17 10:22:28 -07:00
Anders F Björklund f718e39ab9 Make sure CFS_BANDWIDTH is available for --cpus 2020-09-15 12:54:39 +02:00
Sharif Elgamal 3c86db01f4
Merge pull request #9166 from priyawadhwa/revert-static-ip
Revert static IP for docker
2020-09-02 15:49:40 -07:00
Priya Wadhwa 22b40e215a revert static IP 2020-09-02 16:33:38 -04:00
Thomas Stromberg 7fc0299c6f Disable swap in Docker/podman by setting --memory-swap to --memory 2020-09-01 13:57:52 -07:00
Priya Wadhwa 2400d1b850 remove network correctly 2020-08-12 10:08:46 -07:00
Priya Wadhwa 3b5f973459 make sure we delete networks correctly 2020-08-12 12:36:57 -04:00
Priya Wadhwa 21789d8c4e compile 2020-08-10 17:18:42 -04:00
Priya Wadhwa dfcfd6f2f0 cleanup 2020-08-10 17:15:26 -04:00
Priya Wadhwa 9dcb0c5478 fix merge conflict 2020-08-10 17:12:56 -04:00
Priya Wadhwa 5799b47ddb Implement some checks and reorganize code 2020-08-10 17:04:41 -04:00
Thomas Stromberg 9c0618f102 Merge to master 2020-07-24 11:22:59 -07:00
Thomas Stromberg bd713ffd45 Increase maximum container startup wait from 13 seconds to 25 seconds 2020-07-24 09:02:32 -07:00
Thomas Stromberg dee9c0b427 Show 'docker logs' excerpt if container dies 2020-07-24 08:58:09 -07:00
Medya Ghazizadeh f04a6a061f
Merge pull request #8586 from afbjorklund/container-id
Support more error messages for container inspect
2020-07-21 12:22:31 -07:00
Anders F Björklund 2a9e9b2425 Make sure to prepare the kic volume after creation
The volume is created as empty, so make sure that we run a
container to do the initial copy of /var from the image.

This is to avoid race conditions later on, where the preload
starts to use the created volume for packing up the tarball.
2020-07-20 21:50:13 +02:00
Jose Donizetti c2175abcba Add static ip to kic/docker 2020-07-18 18:19:53 -03:00
Sharif Elgamal d0d3973a13 restrict apparmor security opt to docker 2020-07-09 12:58:01 -07:00
Anders F Björklund f23bbea995 Support more error messages for container inspect
The messages are different between "inspect" and "container inspect",
and also changed a bit in format between Podman v1 and Podman v2.

Support all of them, for compatibility with different versions of
Docker and Podman. Was causing restarts and failures, with KIC.
2020-06-28 14:19:09 +02:00
Priya Wadhwa e32e2135ed review comments 2020-06-25 19:39:59 -07:00
Priya Wadhwa 903686172d Check for iptables file before determining container is running 2020-06-25 17:58:22 -07:00
Medya Gh e91e11eeba address review comments 2020-06-17 18:32:11 -07:00
Medya Gh ca2d0f97ec move advice to its own file 2020-06-17 15:07:17 -07:00
Medya Gh 543b0b5bfa add post mortem logs when container not running 2020-06-17 13:27:17 -07:00
Medya Gh 736f5219e0 add error type for check running 2020-06-17 12:13:12 -07:00
Medya Gh 4caf260279 add cpu count limit error type for kic drivers 2020-06-16 13:21:56 -07:00
Priya Wadhwa 6ef48499b4 Code review comments 2020-06-12 11:00:46 -07:00
Priya Wadhwa 330224f36a Warn user to restart daemon if context deadline is exceeded 2020-06-11 12:50:11 -07:00
Priya Wadhwa 0ec839186d Change glog.Errorf to glog.Infof so that we don't get an ugly log to stdout 2020-06-11 11:14:04 -07:00
Anders F Björklund 14937e4677 Never use docker inspect, always provide the type
Should avoid errors like: map has no entry for key "State"

When inspecting a volume, rather than a container or image
2020-05-21 17:20:53 +02:00
Medya Ghazizadeh 6b97ee8ee2
Merge pull request #8001 from afbjorklund/podman-start
podman: Wrap the start command with cgroup manager too
2020-05-11 17:59:39 +00:00
Anders F Björklund c578a7aa1e Add a PointToHost function for podman as well
And add an active variable, similiar to docker
2020-05-10 23:07:12 +02:00
Anders F Björklund 46025eccf5 Use the runCmd wrapper for start to not miss error 2020-05-09 14:07:18 +02:00
Anders F Björklund ac01e92012 Add comment about why podman looks at runtime.GOOS 2020-05-09 14:05:57 +02:00
Anders F Björklund a7a5148ff6 Don't add cgroup manager param for podman-remote
Since it doesn't work for either "run" or "start"

	Error: unknown flag: --cgroup-manager
2020-05-09 14:04:04 +02:00
Anders F Björklund 85fae62d4a Wrap the start command with cgroup manager too
When running with podman, to match the run cmd
2020-05-09 14:04:04 +02:00
Medya Ghazizadeh 1da92a1c84
Merge pull request #7961 from afbjorklund/podman-preload
Use the correct binary for unpacking the preload
2020-05-04 20:04:19 +00:00
Medya Gh 2102a20605 wrap errors 2020-05-02 18:38:23 -07:00
Medya Gh 4572d0634f exit with usage if container type is windows 2020-05-02 18:29:33 -07:00
Anders F Björklund e2d7d94dfc Use the correct binary for unpacking the preload
Previously hardcoded to *always* use a Docker volume,
even if using a different container driver (podman).
2020-05-01 22:11:28 +02:00
Anders F Björklund 78a22f5056 Remove prefix parameter and add prefix command
Move the "sudo" prefix to a central location, instead of
having it all over the place. Assume only needed on Linux.
2020-04-28 13:52:52 +02:00
Anders F Björklund 1744ffe773 Restore the configured state added for podman
Reverted 22aa1aff22 by accident
2020-04-27 22:27:53 +02:00
Anders F Björklund 795128131f Remove old Copy function added in merge conflict 2020-04-26 22:52:10 +02:00
Anders F Björklund 88c8a24d55 Pass the container implementation on to systemd 2020-04-25 22:43:40 +02:00
Anders F Björklund 7647b1f998 Don't try to limit podman memory without cgroup
Podman requires both memcg and memcg_swap for it (--memory).

Docker will still limit memory, without swap limit support.
2020-04-25 22:01:51 +02:00
Anders F Björklund 6644c5cc64 Merge branch 'master' into podman-sudo 2020-04-25 18:05:33 +02:00
Medya Gh 63f9bfbb61
addres review comments 2020-04-24 14:07:54 -07:00
Medya Gh ef01ed481c
get rid of global CliRunner 2020-04-23 14:37:03 -07:00
Medya Gh 17f420cc71
warn slow part of cli runner 2020-04-23 01:23:49 -07:00
Medya Gh 038aef6b48
unexport warnIfSlow func 2020-04-23 00:33:40 -07:00
Medya Gh 8a0a210763
convert more funcs to use cli runner 2020-04-23 00:29:37 -07:00
Medya Gh c6e1445ccb
convert more to cli runner 2020-04-23 00:12:41 -07:00
Medya Gh b639c6112d
fix delete and add integeration test 2020-04-20 20:38:31 -07:00
Anders F Björklund 19be5619d6 Resource limits seem to work ok when not rootless 2020-04-19 09:45:16 +02:00
Anders F Björklund 024cd6b108 Use the same kind of named /var mount for podman
The internal anonymous mounts do not seem to have the same
issues as the external path mounts, so we can do all of /var
2020-04-19 09:45:16 +02:00
Anders F Björklund 8987b1067a Also persist the kubelet and the cni state dirs 2020-04-19 09:45:16 +02:00
Anders F Björklund 223424652c Also create and mount the container runtime dirs 2020-04-19 09:45:16 +02:00
Anders F Björklund f57faf8036 Only remount the /var/lib/minikube directory 2020-04-19 09:45:16 +02:00
Anders F Björklund 22aa1aff22 Handle more state and status for the podman driver 2020-04-19 09:45:16 +02:00
Anders F Björklund d7dc7bf7b2 The podman driver should not be run as root
Use sudo for the podman commands instead

Wrap the docker commands with env prefix
2020-04-19 09:42:17 +02:00
Medya Gh bf15f9a00c fix build err 2020-04-16 16:20:04 -07:00
Medya Gh 934f900f16 improve kic start and kill 2020-04-16 16:10:44 -07:00
Medya Gh 34fafc783f fine tune 2020-04-14 22:20:28 -07:00
Medya Gh 7303ccf07d lint 2020-04-14 21:31:12 -07:00
Medya Gh 54aa958f01 use oci to delete 2020-04-14 20:51:18 -07:00
Medya Gh b7f0bfc369 unconfine apparmor for kic 2020-04-13 16:44:17 -07:00
Priya Wadhwa 3a12fbd1f5 Fix spelling 2020-04-09 10:50:20 -07:00
Priya Wadhwa 70329bf51d Code review comments 2020-04-08 13:44:04 -07:00
Priya Wadhwa b509d69182 Extract preloaded tarball as soon as minikube volume is created
Extracting preload currently takes 6 seconds. This PR begins preload extraction as soon as the minikube volume is created, and runs it in parallell with creating the container node and setting up SSH.

This shaves 2-3 secnods off of `node.StartHost`
2020-04-07 14:19:20 -07:00
Medya Gh a0263c2513 adjust more 2020-04-03 20:59:03 -07:00
Medya Gh a62d611e0b adjust kill time 2020-04-03 20:59:03 -07:00
Medya Gh 8f51d7de58 adjust warn if slow for ps and volume 2020-04-03 20:59:03 -07:00
Thomas Stromberg 5307145802 Move errors and warnings to output to stderr 2020-04-02 09:58:13 -07:00
Thomas Stromberg 2f2dccd30c Remove test values 2020-03-26 14:05:02 -07:00
Thomas Stromberg 46f31480df Make slow command detection consistent across kic/oci 2020-03-26 14:03:22 -07:00
Medya Ghazizadeh f00f5ff600
remove extra if 2020-03-24 10:21:32 -07:00
Medya Gh 940baa09ea fix comment 2020-03-24 07:31:22 -07:00
Medya Gh 41b16b1568 fail if container is not running 2020-03-24 07:27:07 -07:00
Medya Gh 83cc28e082 add logging for when container status is running 2020-03-24 07:11:22 -07:00
Thomas Stromberg 9ac1ad2a7e Merge master 2020-03-06 16:13:54 -08:00
Thomas Stromberg e027dfc4d2 More unused code cleanup 2020-03-06 15:57:12 -08:00
Thomas Stromberg 3fee641a13 Remove remaining PointToHostDockerDaemon calls 2020-03-06 15:15:05 -08:00
Medya Gh a58a9f0176 tweak 2020-03-06 15:13:56 -08:00
Medya Gh cb14468b44 english 2020-03-06 15:11:42 -08:00
Medya Gh cdb8f9c3f6 make sure container is running after create 2020-03-06 15:08:39 -08:00
Medya Gh 38ccb88e3f address code review 2020-03-06 10:25:48 -08:00
Medya Gh 0335fb1ad7 change names 2020-03-05 22:38:47 -08:00
Medya Gh 1e8dd94a77 fix logic 2020-03-05 22:31:44 -08:00
Medya Gh e1f6820335 fix already in use 2020-03-05 16:42:56 -08:00
Sharif Elgamal 0ff12cafac Merge branch 'master' of github.com:kubernetes/minikube into machinename 2020-03-04 16:37:54 -08:00
Medya Gh f40c5a7b30 move funcs arround 2020-03-04 12:50:01 -08:00
Medya Gh 6a62046e62 add warning and point to right docker 2020-03-04 10:22:20 -08:00
Sharif Elgamal 31a42ce672
address comments 2020-03-02 17:30:08 -08:00
Sharif Elgamal 4cd3ef81a5
more changes 2020-03-02 15:21:37 -08:00
Medya Gh 8d0c41392b continue instead of nest 2020-02-26 13:50:42 -08:00
Medya Gh 4709af55df resolve review comments 2020-02-26 12:44:25 -08:00