When attempting to run a kubejob using the perl image, the default installation of minikube will cause the job to fail because the disk size for the minikube vm is too small. In order to fix this issue, you must delete the minikube instance and install a new one.
minikube delete
β β minikube start --disk-size=5g --cpus=2 --memory=2000
π minikube v1.16.0 on Darwin 11.1
β¨ Automatically selected the docker driver. Other choices: hyperkit, virtualbox
π Starting control plane node minikube in cluster minikube
π Pulling base image ...
π₯ Creating docker container (CPUs=2, Memory=2000MB) ...
π³ Preparing Kubernetes v1.20.0 on Docker 20.10.0 ...
βͺ Generating certificates and keys ...
βͺ Booting up control plane ...
βͺ Configuring RBAC rules ...
π Verifying Kubernetes components...
π Enabled addons: storage-provisioner, default-storageclass
π Done! kubectl is now configured to use "minikube" cluster and "default" namespace by default
--docker-opt="--data-root /mnt/sda1"
option to put the docker data in the /mnt/sda fs instead of root /β β ξ° ~ ξ° minikube start --disk-size=5g --cpus=2 --memory=2000 --docker-opt="--data-root /mnt/sda1"
π minikube v1.16.0 on Darwin 11.1
β¨ Using the docker driver based on existing profile
π Starting control plane node minikube in cluster minikube
π Updating the running docker "minikube" container ...
π³ Preparing Kubernetes v1.20.0 on Docker 20.10.0 ...
βͺ opt --data-root /mnt/sda1
apiVersion: batch/v1
π Verifying Kubernetes components...
π Enabled addons: storage-provisioner, default-storageclass
π Done! kubectl is now configured to use "minikube" cluster and "default" namespace by default
To connect to a service on minikube, run: minikube service list
. This will list all the services running on minikube.
β K8s minikube service list
|-------------|----------------------|-----------------------------|
| NAMESPACE | NAME | URL |
|-------------|----------------------|-----------------------------|
| default | kubernetes | No node port |
| default | nginx | http://192.168.99.103:32494 |
| kube-system | kube-dns | No node port |
| kube-system | kubernetes-dashboard | http://192.168.99.103:30000 |
| kube-system | metrics-server | No node port |
|-------------|----------------------|-----------------------------|
β K8s wget -O- 192.168.99.103:32494
--2021-02-20 16:22:38-- http://192.168.99.103:32494/
Connecting to 192.168.99.103:32494... connected.
HTTP request sent, awaiting response... 200 OK
Length: 612 [text/html]
Saving to: βSTDOUTβ
- 0%[ ] 0 --.-KB/s <!DOCTYPE html>
<html>
<head>
<title>Welcome to nginx!</title>
<style>
body {
width: 35em;
margin: 0 auto;
font-family: Tahoma, Verdana, Arial, sans-serif;
}
</style>
</head>
<body>
<h1>Welcome to nginx!</h1>
<p>If you see this page, the nginx web server is successfully installed and
working. Further configuration is required.</p>
<p>For online documentation and support please refer to
<a href="http://nginx.org/">nginx.org</a>.<br/>
Commercial support is available at
<a href="http://nginx.com/">nginx.com</a>.</p>
<p><em>Thank you for using nginx.</em></p>
</body>
</html>
- 100%[=================================================>] 612 --.-KB/s in 0s
2021-02-20 16:22:38 (10.6 MB/s) - written to stdout [612/612]