cloudpakforapplications-appmod
workshop-10-01-2020
workshop-10-01-2020
  • Introduction
  • Setup / Pre-work
    • Cloud Workshop + Cloud Shell Setup Instructions
  • Day 1
    • Lab: Kubernetes 101
      • Lab 1 - Deploy Application
      • Lab 2 - Scale Application
      • Lab 3 - Multi-tier Application
    • Lab: Helm 101
      • Setup Helm
      • Lab 1 - Deploy Application
      • Lab 2 - Update Application
      • Lab 3 - Revisions
      • Lab 4 - Helm Repositories
    • Lab: Jenkins and Kubernetes
  • Day 2
    • Lab: Deploy Microservices on IKS
    • Lab: Kubernetes Extensions
      • Access Cognitive Class
      • Setup Tools
      • Custom Resources and Operators
    • Lab: Istio 101
      • Setup Istio
      • Lab 1 - Installing Istio
      • Lab 2 - Deploying Guestbook Application
      • Lab 3 - Expose the Service Mesh with Istio Ingress Gateway
      • Lab 4 - Perform Traffic Management
  • Resources
    • IBM Developer
Powered by GitBook
On this page
  • 1. Install Operator SDK
  • 2. Configure Kubectl

Was this helpful?

  1. Day 2
  2. Lab: Kubernetes Extensions

Setup Tools

PreviousAccess Cognitive ClassNextCustom Resources and Operators

Last updated 4 years ago

Was this helpful?

Please follow these steps to prepare for the Kubernetes Extensions lab:

1. Install Operator SDK

The Cloud Shell comes with several tools/libraries. For the lab, we will use the operator-sdk cli, which depends on Go to be installed. To check if both tools are installed in your shell, runn the following commands.

go version
operator-sdk version

If you see a command not found error, you will need to install both. For detailed installation instructions go .

The version of the operator SDK used in the lab is 0.18.2. If the version shown from the above command is not 0.18.2, we need to install it.

curl -LO https://github.com/operator-framework/operator-sdk/releases/download/v0.18.2/operator-sdk-v0.18.2-x86_64-linux-gnu
chmod +x operator-sdk-v0.18.2-x86_64-linux-gnu
mkdir $HOME/operatorsdk0182
cp operator-sdk-v0.18.2-x86_64-linux-gnu $HOME/operatorsdk0182/operator-sdk
rm operator-sdk-v0.18.2-x86_64-linux-gnu
echo 'export PATH=$HOME/operatorsdk0182:$PATH' > .bash_profile
source .bash_profile

Check again,

operator-sdk version

2. Configure Kubectl

If you have not setup your kubectl to access your cluster, you can do so in the terminal environment

  1. Login to IBM Cloud using ibmcloud login. If asked, choose Advowork as your target account.

  2. Run the ibmcloud ks clusters command to verify the terminal and setup for access to the cluster

    ibmcloud ks clusters
  3. Configure the kubectl cli available within the terminal for access to your cluster. If you previously stored your cluster name to an environment variable, use that (ie. $CLUSTER_NAME), otherwise copy and paste your cluster name from the previous commands output to the $CLUSTER_NAME portion below.

    ibmcloud ks cluster config --cluster $CLUSTER_NAME
  4. Verify access to the Kubernetes API by getting the namespaces.

    kubectl get namespace
  5. You should see output similar to the following, if so, then your're ready to continue.

NAME              STATUS   AGE
default           Active   125m
ibm-cert-store    Active   121m
ibm-system        Active   124m
kube-node-lease   Active   125m
kube-public       Active   125m
kube-system       Active   125m
here
Install Operator SDK
Configure Kubectl