Create a Kubernetes cluster using the wizard on the IBM Cloud platform. When it's running, follow the instructions for operating with the cluster on your local command line:
curl -sL https://ibm.biz/idt-installer | bash ibmcloud login -a https://api.eu-gb.bluemix.net ibmcloud cs region-set uk-south ibmcloud cs cluster-config diffblue export KUBECONFIG=~/.bluemix/plugins/container-service/clusters/diffblue/kube-config-lon02-diffblue.yml
Create a registry to push the Diffblue Cover images to:
ibmcloud plugin install container-registry -r Bluemix ibmcloud login -a https://api.eu-gb.bluemix.net ibmcloud cr namespace-add <my_namespace> ibmcloud cr login
repoNameenvironment variable to point to your registry and namespace:
If you see errors pulling images from the repository this tends to mean the registry is in a different zone. By default, registries are open to nodes inside the same zone. If they are different, you can add a token like this:
ibmcloud cr token-add --description "Registry token" --non-expiring --readwrite kubectl --namespace diffblue create secret docker-registry registry-token --docker-server=registry.eu-de.bluemix.net --docker-username=token --docker-password=<token from first step> --email@example.com
Ensure that the token is replaced as well as the correct registry server. Then add these lines to
spec sections of the
YAMLs and the
application-server stateful set YAML:
spec: imagePullSecrets: - name: registry-token
Then reapply these YAMLs.
In some cases Mongo can fail to start in the initial interval timeframe set in the manifest YAML
files. This seems to be an issue with IBM Cloud only, and how volumes take some time to start.
The solution is to increase the
initialDelaySeconds: 30 value to around 100 seconds
in both the liveness and readiness checks.
Now return to the main cloud deployment page and follow the instructions to deploy Diffblue Cover to the cluster.