mvn clean install
Then run the main method from your IDE or run with maven spring-boot:run
mvn versions:display-dependency-updates versions:display-plugin-updates
mvn -f app/pom.xml jib:dockerBuild
docker push terracotta/terracotta-operator
If you encounter :
Message: Forbidden!Configured service account doesn't have access. Service account may have been revoked. namespaces "thisisatest" is forbidden: User "system:serviceaccount:default:default" cannot get namespaces in the namespace "thisisatest".
Then apply this file :
kubectl apply -f sample-yaml-files/fabric8-rbac.yaml
If on Minikube :
kubectl run terracotta-operator --image-pull-policy='Always' --image=terracotta/terracotta-operator --port=8080
kubectl expose deployment terracotta-operator --name=terracotta-operator-port --type=NodePort
minikube service terracotta-operator-port
If somewhere else :
kubectl run terracotta-operator --image-pull-policy='Always' --image=terracotta/terracotta-operator --port=8080
kubectl expose deployment terracotta-operator --name=operator-port --type=NodePort
To create a new cluster:
curl --header "Content-Type: application/json" \
--request POST \
--data '{"offheaps":{"offheap1":"100MB","offheap2":"1GB"},"serversPerStripe":2,"clientReconnectWindow":20}' \
http://localhost:8080/api/cluster
Check the status of the cluster:
curl http://localhost:8080/api/cluster
Delete the cluster:
curl -X DELETE http://localhost:8080/api/cluster
kubectl --namespace=thisisatest apply -f sample-yaml-files/1server-cluster.yaml
and delete :
kubectl --namespace=thisisatest delete -f sample-yaml-files/1server-cluster.yaml
super slow to delete a statefulset...