Skip to content

Modified manifests for Minikube compatibility and updated README #2796

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 37 additions & 19 deletions docs/development-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,28 +79,47 @@ This doc explains how to build and run the Online Boutique source code locally u

## Option 2 - Local Cluster

1. Launch a local Kubernetes cluster with one of the following tools:
### Launching with Minikube

- To launch **Minikube** (tested with Ubuntu Linux). Please, ensure that the
local Kubernetes cluster has at least:
- 4 CPUs
- 4.0 GiB memory
- 32 GB disk space
1. Launch a **Minikube** cluster (tested with Ubuntu Linux). Please, ensure that the local Kubernetes cluster has at least:
- 4 CPUs
- 4.0 GiB memory
- 32 GB disk space

```shell
minikube start --cpus=4 --memory 4096 --disk-size 32g
```
```shell
minikube start --cpus=4 --memory 4096 --disk-size 32g
```

2. Run `kubectl get nodes` to verify you're connected to the respective control plane.

- To launch **Docker for Desktop** (tested with Mac/Windows). Go to Preferences:
- choose “Enable Kubernetes”,
- set CPUs to at least 3, and Memory to at least 6.0 GiB
- on the "Disk" tab, set at least 32 GB disk space
3. Apply the Minikube-specific Kubernetes manifest file:

```sh
kubectl apply -f ./release/minikube-kubernetes-manifests.yaml
```

The `minikube-kubernetes-manifests.yaml` file includes changes made to ensure compatibility with Minikube:

- **Service Type Adjustments**: Services originally defined as `LoadBalancer` have been changed to `NodePort` since Minikube does not natively support `LoadBalancer` services without additional configurations.
- **Resource Requests and Limits** (Optional): CPU and memory resource requests and limits have been reduced to align with the typically constrained resource availability in a Minikube environment.

4. Run `kubectl get pods` to verify the Pods are ready and running.

- To launch a **Kind** cluster:
5. Run `kubectl get services` to confirm that the services are up and running.

```shell
kind create cluster
```
6. To access the frontend service, you can run the following command, which will open it in your default web browser:

```sh
minikube service frontend-external
```

### Launching with Kind

1. To launch a **Kind** cluster:

```shell
kind create cluster
```

2. Run `kubectl get nodes` to verify you're connected to the respective control plane.

Expand All @@ -114,8 +133,7 @@ This doc explains how to build and run the Online Boutique source code locally u

6. Navigate to `localhost:8080` to access the web frontend.


## Cleanup

If you've deployed the application with `skaffold run` command, you can run
If you've deployed the application with the `skaffold run` command, you can run
`skaffold delete` to clean up the deployed resources.
Loading