Difficulty: Introduction
Estimated Time: 10 minutes

Go Apps in Containers on Kubernetes

These next steps provide an ideal place to start writing applications in Go to run on Kubernetes. Each step will take you from raw Go code, to packaging it in a container to running your contained application on Kubernetes.

You will learn how:

  • write some basic Go applications
  • write a basic microservice in Go
  • package a Go microservice in a container
  • run a Go microservice on Kubernetes

Go is an open-source programming language that makes it easy to build simple, reliable, and efficient software.


You now understand different techniques for writing Go apps and packaging them in efficient containers for Kubernetes. Go is a popular language to write containerized apps. The language was designed for simplicity and efficiency. These are attractive goals when you are writing many application containers for Kubernetes.

Lessons Learned

With these steps you have learned:

  • ✔ how to write some basic Go applications,
  • ✔ how to write a basic microservice in Go,
  • ✔ how to package a Go microservice in a container,
  • ✔ how to run a Go microservice on Kubernetes.

Hopefully you also understand how Kubernetes is a new type of data center operating system that can run your applications - across multiple nodes on your local laptop, a rack of servers, or any cloud target.


For a deeper understanding of these topics and more join
Jonathan Johnson
at various conferences, symposiums, workshops, and meetups.

Software Architectures ★ Speaker ★ Workshop Hosting ★ Kubernetes & Java Specialist

Go Apps in Containers on Kubernetes

Step 1 of 6

Your Kubernetes Cluster

For this scenario, Katacoda has just started a fresh Kubernetes cluster for you. Verify it's ready for your use.

kubectl version --short && \ kubectl get componentstatus && \ kubectl get nodes && \ kubectl cluster-info

The Helm package manager used for installing applications on Kubernetes is also available.

helm version --short

Kubernetes Dashboard

You can administer your cluster with the kubectl CLI tool or use the visual Kubernetes Dashboard. Use this script to access the protected Dashboard.


Creating Katacoda Scenarios

Thanks for creating Katacoda scenarios. This tab is designed to help you as an author have quick access the information you need when creating scenarios.

This tab will not be visible to users.

Here are some useful links to get you started.

Running Katacoda Workshops

If you are planning to use Katacoda for workshops, please contact [email protected] to arrange capacity.

Debugging Scenarios

Below is the response from any background scripts run or files uploaded. This stream can aid debugging scenarios.

If you still need assistance, please contact [email protected]