Setup an Operator SDK on Ubuntu in a Virtual Server Instance

That blog post is about a partly automated setup of an Operator SDK on an Ubuntu Virtual Server Instance on IBM Cloud. The setup is automatically verified by cloning and building an operator bundle.

The automation of the script in the GitHub project uses content from the awesome blog post of my colleague Alain Airom with the topic: How to provision a VSI and Install Docker Tools for Development on IBM Cloud.

Step 1: Create an Ubuntu Virtual Service Instance in a Virtual Private Cloud environment

You can follow the blog post HOW TO CREATE A SINGLE VIRTUAL SERVER INSTANCE (VSI) IN A VIRTUAL PRIVATE CLOUD (VPC) INFRASTRUCTURE ON IBM CLOUD. The difference during the creation of the VSI is that you create an Ubuntu instead of a Centos instance.

Step 1: Clone the project to the local machine

git clone

Step 2: Navigate to the scripts folder

cd example-tools-build-container-image/scripts

Step 3: Save the actual path as rootfolder


Step 4: Get the IP address of your remote machine on IBM Cloud

  • Log on to IBM Cloud
ibmcloud login #-sso
  • Install needed ibmcloud cli plugin
ibmcloud plugin install vpc-infrastructure
  • Define ibmcloud targets and VSI name
export RESOURCE_GROUP=default
export REGION=us-south
  • Get VSI IP address
ibmcloud target -g $RESOURCE_GROUP
ibmcloud target -r $REGION
VSI_IP=$(ibmcloud is instances | grep "$VSI_NAME" | awk '{print $5;}')

Step 5: Copy the and to your remote machine

  • Verify your existing private keys
cd ~/.ssh

Note: Maybe you need to clean the known_hosts file

  • Save the key location in a variable
  • Return to the folder we want to copy from
  • Execute copy of the scripts to your VSI
scp -i $PATH_TO_PRIVATE_KEY_FILE setup-*.sh root@$VSI_IP:/home

  • Example output:
Enter passphrase for key '/Users/thomassuedbroecker/.ssh/EXAMPLE':                                                                100%  773     4.6KB/s   00:00                                                                                  100% 2176    12.8KB/s   00:00 

Step 6: Log in to VSI


Step 7: In the VSI navigate to the home folder

  • Inside the VSI navigate to the home folder
cd ..
cd home
export ROOT=$(pwd)

Step 8: Run bash setup-on-ubuntu-vsi.shscript

  • Inside the VSI execute following script

The script does …

… install:

  • Buildah
  • Kubernetes
  • Docker community addition
  • IBM Cloud CLI and following plugings: container-service, container-registry, code-engine, cloud-databases

… adds a brew user for the brew installation

Step 9: Run bash script

  • Inside the VSI execute following script
cd ..

The script does …

… install:

… clone the Multi Tenancy Frontend Operator project 

… builds a bundle image using the operator-sdk

I hope this was useful to you and let’s see what’s next?



#ubuntu, #operatorsdk, #kubernetes, #bundle

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Blog at

Up ↑

%d bloggers like this: