and create an account.
Step 3: Select a Region and Choose VM Configuration
- In the "Compute Nodes" tab, select a geographical region where you want to launch the Virtual Machine (e.g., the United States).
- In the Choose VM Configuration section, select the number of cores, amount of memory, boot disk type, and size that best suits your needs.
- You will have at least 40 - 80 GB of storage. The disk space should cover the base OS, Minikube, Kubernetes, Docker images, and some application data. If you’re working with larger datasets or multiple containers, consider increasing storage. If you use NodeShift and need more resources, you can always resize to add more CPUs and RAM.
Step 5: Choose the Billing Cycle & Authentication Method
- Select the billing cycle that best suits your needs. Two options are available: Hourly, ideal for short-term usage and pay-as-you-go flexibility, or Monthly, perfect for long-term projects with a consistent usage rate and potentially lower overall cost.
- Select the authentication method. There are two options: Password and SSH Key. SSH keys are a more secure option. To create them, refer to our
Step 6: Additional Details & Complete Deployment
- The ‘Finalize Details' section allows users to configure the final aspects of the Virtual Machine.
- After finalizing the details, click the 'Create' button, and your Virtual Machine will be deployed.
Step 8: Connect via SSH
- Open your terminal
- Run the SSH command:
For example, if your username is root, the command would be:
ssh root@ip
- If SSH keys are set up, the terminal will authenticate using them automatically.
- If prompted for a password, enter the password associated with the username on the VM.
- You should now be connected to your VM!
Step 10: Install Dependencies
Run the following command to Install the dependencies:
sudo apt install -y apt-transport-https ca-certificates curl
Purpose of the Command
This command ensures that your system can securely download software from HTTPS sources and has the necessary tools (curl) to fetch files from the internet, which is often required for installing tools like Minikube and Docker.
This commands, ensure your user can run Docker commands without sudo by adding it to the docker group:
sudo usermod -aG docker $USER
newgrp docker
Command 1: sudo usermod -aG docker $USER
- sudo: Runs the command with superuser (administrator) privileges.
- usermod: A command to modify user accounts.
- -aG docker: The -a option adds the user to a supplementary group without removing it from other groups. -G docker specifies the group (in this case, docker) to which the user should be added.
- $USER: A variable representing the current logged-in user’s username.
Purpose: This command adds the current user to the docker group, giving them permission to run Docker commands without using sudo every time.
Command 2: newgrp docker
- newgrp docker: With this command , make the new group members active immediately without having to log out and log back in.
Purpose: When adding a user to a docker group, this command ensures that the current session recognizes other group members, so you do not have to restart your terminal.
Next, Run the following command to Verify the installation:
kubectl version --client --output=yaml
Step 14: Create a non-root user
Run the following command to Create a non-root user:
sudo adduser your_username
Then run the following command to add the user to the Docker group to allow it to use Docker without root privileges:
sudo usermod -aG docker your_username
Next, run the following command to log in as the new user:
su - your_username
Step 16: Verify Minikube Installation
Run the following command to check the status of Minikube and your Kubernetes cluster:
minikube status
kubectl get nodes
This will open the Kubernetes dashboard in your default web browser. If you’re working on a remote VM, you may need to forward the port.
Note: However, if you’re running Minikube on a remote VM, this local URL won’t open directly on your local machine.
To access the dashboard from your local machine, you can use SSH port forwarding to tunnel the local URL from the VM to your local system.
Once connected, open the following URL in your local browser to access the Kubernetes dashboard:
CODEhttp://127.0.0.1:38885/api/v1/namespaces/kubernetes-dashboard/services/http:kubernetes-dashboard:/proxy/
↗ Original-Artikel auf dev.to lesenVollständiger Original-BerichtAusführliche Details, Code-Beispiele & Hersteller-Stellungnahme auf dev.to.
SOCIAL SHARE CARD GENERATOR