Note that minikube works better in Mac Docker Desktop. Linux is recommended for best results.
minikube start
minikube addons enable ingress
kubectl get pods --all-namespaces -l app=ingress-nginx
minikube load image joystream/node:giza --daemon
pulumi up ...
# get the namespace name of the deployed stack
NAMESPACE_NAME=$(pulumi stack output namespaceName)
kubectl apply -f query-node/ingress.yaml --namespace $NAMESPACE_NAME
kubectl apply -f node-network/ingress.yaml --namespace $NAMESPACE_NAME
In a separate terminal run the tunnel service, which will attempt to listen on port 80:
minikube tunnel
You could run it in the background with the "&" ampersand
minikube tunnel &
With ingress deployed you will be able to access the exposed services on:
ws://localhost/ws-rpc
http://localhost/indexer/graphql
http://localhost/server/graphql
kill the background job by its given number (assuming job number 1)
kill %1
pulumi destroy
minikube stop
minikube delete
Our cluster configuration will try to listen on port 80 so there cannot be another service running on that port.
# optionally save cluster config in specific location,
# remember to set this again when using kubectl command to access the cluster.
export KUBECONFIG=$(PWD)/kubeconfig
# create the cluster with custom configuration
kind create cluster --config ./kind-cluster.yaml --name joystream
# confirm current context is set to newly created cluster
kubectl config current-context
# you should see:
kind-joystream
# if you have switched to a different context you can switch back to the cluster with:
kubectl config set current-context kind-joystream
# list cluster nodes
kubectl get nodes
# get cluster details
kubectl cluster-info
kubectl apply -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/main/deploy/static/provider/kind/deploy.yaml
kubectl wait --namespace ingress-nginx \
--for=condition=ready pod \
--selector=app.kubernetes.io/component=controller \
--timeout=90s
Load docker images for the stacks. Do not use :latest
tag otherwise it will be pulled from docker hub.
kind load docker-image joystream/node:giza
kind load docker-image joystream/apps:giza
For more details see the README files for each stack.
pulumi up ...
# get the namespace name for the stack that was deployed
NAMESPACE_NAME=$(pulumi stack output namespaceName)
kubectl apply -f node-network/ingress.yaml --namespace $NAMESPACE_NAME
kubectl apply -f query-node/ingress.yaml --namespace $NAMESPACE_NAME
With ingress deployed you will be able to access the exposed services on:
ws://localhost/ws-rpc
http://localhost/indexer/graphql
http://localhost/server/graphql
pulumi destroy
kind delete cluster