This content originally appeared on Level Up Coding - Medium and was authored by Chamith Madusanka

Introduction
Before diving directly into Kubernetes, I want to lay the foundation by addressing the key concepts. I’ll start by discussing common problems developers face when building applications and gradually guide you towards understanding Kubernetes. This will be part of a series of blog posts.
We’ll begin by exploring some of the challenges in application development and how container-based development has emerged as a solution to many of these issues.
Developer’s Dilemma
It’s a common challenge managing software across different environments — development (Dev), testing (Test), and production (Prod). Dependencies such as libraries and packages may also vary, causing the application to behave inconsistently. Additionally, configuration settings like DNS service names and database connections can differ between environments, further complicating deployment. These discrepancies result in frustration for developers, and lead to unreliable deployments and increased time and cost for troubleshooting. Docker addresses these issues by packaging the application code, runtime engine, dependencies, and configuration into a single container image. This container image remains consistent across all environments, ensuring that the application runs uniformly and predictably, thus eliminating the environment-specific problems highlighted in the image.
Docker
What is a Docker Image?
A Docker image is essentially a blueprint for running a Docker container. It consists of a series of read-only layers, each representing an instruction in the Dockerfile. This includes the application code, dependencies, libraries, binaries, and the necessary environment to run the application.
What is a container?
A container is an atomic, self contained package of software that includes everything needs to run (code, runtimes, libraries, packages, etc.)

Docker image vs Container

A Docker image is a lightweight, standalone, executable package that includes everything needed to run a piece of software, including the code, a runtime, libraries, environment variables, and config files. A container is a runtime instance of a Docker image.
1. Build Phase
Inputs: Code, Configuration, Dependencies, Runtime Engine
- Code: The source code of your application.
- Configuration: Configuration files that specify how your application should run.
- Dependencies: Libraries and dependencies required for your application to function.
- Runtime Engine: The runtime environment needed for your application, such as a specific version of Node.js, Python, etc.
These components are packaged together to create a Docker Image (or Container Image). The Docker image contains everything your application needs to run, bundled into a single package.
2. Docker Image
- The Docker image is a lightweight, standalone, and executable software package. It includes the code, runtime, libraries, environment variables, and configuration files.
- Once the image is built, it can be stored and shared through a Docker registry (like Docker Hub).
3. Run Phase
- When you run a Docker image, it creates an instance of that image known as a Container.
- A container is a running instance of a Docker image. It isolates your application and its dependencies from the underlying system, ensuring that it runs uniformly regardless of where it is deployed.
Container Orchestrator
The next step in the lifecycle of a containerised application is often managed by a Container Orchestrator. This powerful tool, such as Kubernetes, ensures that the containers run smoothly, handling tasks like scaling, load-balancing, and distributing tasks among multiple containers.

Stay tuned for the next part of this blog series, where we’ll delve deeper into orchestration and how it lays the groundwork for Kubernetes.
Thank you for reading this post. If you like this post, give a Cheer!!! 👏
Happy Learning ❤️!
Kubernetes 1 : Understanding Containers was originally published in Level Up Coding on Medium, where people are continuing the conversation by highlighting and responding to this story.
This content originally appeared on Level Up Coding - Medium and was authored by Chamith Madusanka

Chamith Madusanka | Sciencx (2025-02-24T13:37:08+00:00) Kubernetes 1 : Understanding Containers. Retrieved from https://www.scien.cx/2025/02/24/kubernetes-1-understanding-containers/
Please log in to upload a file.
There are no updates yet.
Click the Upload button above to add an update.