minikube start
For more details about minikube visit the official documentation.
You must choose between a native executable and a JVM executable
- Fast-jar executable:
./mvnw package -DskipTests -Dquarkus.package.type=fast-jar
- Native executable:
./mvnw package -Pnative -DskipTests -Dquarkus.native.container-build=true -Dquarkus.container-image.build=true -Dquarkus.native.builder-image=quay.io/quarkus/ubi-quarkus-mandrel:20.3.0.0.Final-java11
We need to create the container image inside Minikube. Point your shell to minikube's docker-daemon:
eval $(minikube -p minikube docker-env)
- If you are using the Fast-jar mode:
docker build -f src/main/docker/Dockerfile.fast-jar -t projectopenubl/searchpe-operator .
- If you are using the Native mode:
docker build -f src/main/docker/Dockerfile.native -t projectopenubl/searchpe-operator .
kubectl create -f k8s/crd.yaml
kubectl create -f k8s/operator.yaml
kubectl create -f k8s/searchpe.yaml -n searchpe-operator
Get pods:
kubectl get pods -n searchpe-operator
Scale operator deployment:
kubectl scale deployments/searchpe-operator --replicas=0 -n searchpe-operator
Delete all:
kubectl delete searchpe hellows -n searchpe-operator
kubectl delete namespace searchpe-operator
kubectl delete customresourcedefinition searchpes.project.openubl
kubectl delete clusterrolebinding operator-admin
kubectl delete clusterroles searchpe-operator