Preface – Serverless Architectures with Kubernetes

Preface

About

This section briefly introduces the authors, the coverage of this book, the technical skills you'll need to get started, and the hardware and software requirements required to complete all of the included activities and exercises.

About the Book

Kubernetes has established itself as the standard platform for container management, orchestration, and deployment. By learning Kubernetes, you'll be able to design your own serverless architecture by implementing the Function-as-a-service (FaaS) model.

After an accelerated, hands-on overview of the serverless architecture and various Kubernetes concepts, you'll cover a wide range of real-world development challenges faced by real-world developers and explore various techniques to overcome them. You'll learn how to create production-ready Kubernetes clusters and run serverless applications on them. You'll see how Kubernetes platforms and serverless frameworks such as Kubeless, Apache OpenWhisk, and OpenFaaS provide the tooling you need to develop serverless applications on Kubernetes. You'll also learn how to select the appropriate framework for your upcoming project.

By the end of this book, you'll have the skills and confidence to design your own serverless applications using the power and flexibility of Kubernetes.

About the Author

Onur Yılmaz is a senior software engineer at a multinational enterprise software company. He is a Certified Kubernetes Administrator (CKA) and works on Kubernetes and cloud management systems. He is a keen supporter of cutting-edge technologies including Docker, Kubernetes, and cloud-native applications. He has one master's and two bachelor's degrees in the engineering field.

Sathsara Sarathchandra is a DevOps engineer and has experience in building and managing Kubernetes based production deployments both in the cloud and on-premises. He has over 8 years of experience, having worked for several companies ranging from small start-ups to enterprises. He is a Certified Kubernetes Administrator (CKA) and a Certified Kubernetes Application Developer (CKAD). He holds a master's degree in business administration and a bachelor's degree in computer science.

Learning Objectives

By the end of this book, you will be able to:

  • Deploy a Kubernetes cluster locally with Minikube
  • Use AWS Lambda and Google Cloud Functions
  • Create, build, and deploy a web page generated by the serverless functions in the cloud
  • Create a Kubernetes cluster running on the virtual kubelet hardware abstraction
  • Create, test, troubleshoot, and delete an OpenFass function
  • Create a sample Slackbot with Apache OpenWhisk actions

Audience

This book is for software developers and DevOps engineers who have basic or intermediate knowledge about Kubernetes and want to learn how to create serverless applications that run on Kubernetes. Those who want to design and create serverless applications running on the cloud, or on-premise Kubernetes clusters, will also find this book useful.

Approach

This book provides examples of engaging projects that have a direct correlation to how serverless developers work in the real world with Kubernetes clusters. You'll build example applications and tackle programming challenges that'll prepare you for large, complex engineering problems. Each component is designed to engage and stimulate you so that you can retain and apply what you learn in a practical context with the maximum impact. By completing the book, you'll walk away feeling capable of tackling real-world serverless Kubernetes applications development.

Hardware Requirements

For the optimal student experience, we recommend the following hardware configuration:

  • Processor: Intel Core i5 or equivalent
  • Memory: 8 GB RAM (16 GB preferred)
  • Hard disk: 10 GB available space
  • Internet connection

Software Requirements

We also recommend that you have the following software installed in advance:

  • Sublime Text (latest version), Atom IDE (latest version), or another similar text editor application
  • Git

Additional Requirements

  • Azure account
  • Google cloud account
  • AWS account
  • Docker Hub account
  • Slack account

Conventions

Code words in the text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles are shown as follows:

"Write hello-from-lambda as the function name and Python 3.7 as the runtime."

New terms and important words are shown in bold. Words that you see on the screen, for example, in menus or dialog boxes, appear in the text like this: "Open the AWS Management Console, write Lambda in the Find Services search box, and click Lambda - Run Code without Thinking about Servers."

A block of code is set as follows:

import json

def lambda_handler(event, context):

    return {

        'statusCode': '200',

        'body': json.dumps({"message": "hello", "platform": "lambda"}),

        'headers': {

            'Content-Type': 'application/json',

        }

    }

Installation and Setup

Before we can do awesome things with data, we need to be prepared with the most productive environment. In this short section, we will see how to do that. Following are the requisites that need to be fulfilled:

Additional Resources

The code bundle for this book is also hosted on GitHub at https://github.com/TrainingByPackt/Serverless-Architectures-with-Kubernetes. We also have other code bundles from our rich catalog of books and videos available at https://github.com/PacktPublishing/. Check them out!