✦ Just launched — first posts live now

Cloud & tech,
explained simply.

I'm learning in public and writing the guides I wish existed when I was starting out. No jargon overload, no gatekeeping.

CB
The CloudBytze author
Engineer · writer · still figuring things out
All articles
NEW · BEGINNER
Jun 14, 2026·9 min read

What Is Cloud Computing? A Plain-English Explanation

Cloud computing powers almost everything you use online — but the definitions are always confusing. Here's what it actually means, with zero jargon.

Read article
SSH
Jun 12, 2026·7 min

What Is SSH? How Secure Shell Works, Explained Simply

SSH lets you control any computer in the world from your terminal. Here's what it is and how to use it.

☁️ vs 💻
Jun 10, 2026·6 min

Cloud Storage vs Local Storage: What's the Difference?

Should you store files on your computer or in the cloud? Here's the honest breakdown of both.

S3
Jun 8, 2026·8 min

What Even Is AWS S3? A Beginner's Plain-English Guide

S3 is everywhere but nobody explains it simply. Let's fix that from scratch.

{ }
Jun 5, 2026·6 min

Git Commands I Use Every Day (and What They Actually Do)

Skip the theory — the 10 commands that solve 90% of real situations.

May 28, 2026·9 min

Docker Explained: Why Everyone Is Obsessed With Containers

"It works on my machine" — Docker fixes that. Here's what it actually does.

Browse by topic
☁️
Cloud
🌿
Git
🐧
Linux
🐳
Docker
🔌
APIs
🌱
Beginner
About CloudBytze

Learning in public,
one byte at a time.

This blog is brand new. I'm a developer who got tired of tutorials that assume you already know everything — so I'm writing the guides I wish had existed when I was starting out.

No fake expertise, no inflated numbers. Just honest writing about cloud and tech, published as I learn. If that sounds useful, subscribe — it's free.

AWSDockerLinuxGitAPIsBeginner-friendly
about.sh
$ cat mission.txt
"Make cloud tech actually
understandable."

$ echo $status
just launched · building in public

$

Get new articles free.

I publish whenever I finish something worth sharing. Subscribe and each new article lands straight in your inbox.

No spam. Unsubscribe any time.

← Back to articles
NEW · BEGINNER · CLOUD

What Is Cloud Computing? A Plain-English Explanation

Quick answer

Cloud computing means using computers, storage, and software that live on the internet — owned and maintained by someone else — instead of running everything on your own hardware. You access it on demand and pay only for what you use.

You've heard the word "cloud" everywhere. Every app, company, and tech tutorial mentions it. But most explanations either assume you already know what it means, or they pile on buzzwords until you give up. Let's start completely from scratch.

What does "the cloud" actually mean?

The cloud is just someone else's computer. Specifically, it's a massive network of powerful computers (called servers) owned by companies like Amazon, Google, and Microsoft, housed in giant warehouses called data centers, and made available to anyone over the internet.

When you save a photo to iCloud, watch Netflix, or send a Gmail, your data isn't stored on your device. It lives on servers in one of these data centers, somewhere in the world. That's the cloud.

"The cloud is just someone else's computer" — and that's actually a feature, not a bug.

What did people use before cloud computing?

Before the cloud, if a company wanted to run software or store data, they had to buy physical servers, set them up in their own building, hire people to maintain them, and upgrade the hardware every few years. This was expensive, slow, and inflexible.

Cloud computing changed all of that. Now you can rent exactly as much computing power as you need, spin it up in minutes, and shut it down when you're done. No hardware to buy, no maintenance headaches.

The three types of cloud computing

Public cloud

Shared infrastructure owned by a cloud provider (AWS, Google Cloud, Azure) and made available to anyone over the internet. Most companies use the public cloud for most things. It's the cheapest and most flexible option.

Private cloud

Cloud infrastructure that is dedicated to a single organization. The hardware might still be in a data center, but only one company uses it. Banks and government agencies often use private clouds for security reasons.

Hybrid cloud

A mix of public and private cloud. A company might keep sensitive customer data on a private cloud, but run its website on the public cloud. Best of both worlds, but more complex to manage.

The three types of cloud services (IaaS, PaaS, SaaS)

This is where most people get confused — so let's use a pizza analogy.

IaaS — Infrastructure as a Service

You rent the raw ingredients. The provider gives you virtual machines, storage, and networking, and you build whatever you want on top. AWS EC2 and Google Compute Engine are examples. Best for developers and IT teams who want full control.

PaaS — Platform as a Service

You get a kitchen with all the tools set up. The provider manages the infrastructure; you just write your app. Heroku and Google App Engine are examples. Best for developers who want to focus on code, not servers.

SaaS — Software as a Service

You get a ready-made pizza delivered. The provider manages everything — infrastructure, platform, and the application itself. Gmail, Slack, Zoom, and Dropbox are all SaaS. You just open a browser and use it.

Real examples of cloud computing you already use

  • Google Drive / iCloud / Dropbox — storing files in the cloud instead of your hard drive
  • Netflix / Spotify — streaming media from cloud servers instead of local files
  • Gmail / Outlook — email stored and processed in the cloud
  • Zoom / Teams — video calls routed through cloud infrastructure
  • Online banking apps — your account data living on secure cloud servers
  • ChatGPT / Claude / Gemini — AI models running on cloud computing hardware

Why do companies choose cloud computing?

  • Cost savings — no upfront hardware purchases; pay only for what you use
  • Speed — spin up servers in seconds instead of weeks
  • Scale — handle traffic spikes automatically without buying extra hardware
  • Reliability — cloud providers run backups and redundancy you'd never afford yourself
  • Global reach — deploy your app in multiple countries with a few clicks

What are the biggest cloud providers?

Three companies dominate the cloud market:

  • AWS (Amazon Web Services) — the largest, most feature-rich cloud platform. Powers a huge portion of the internet.
  • Microsoft Azure — popular with enterprises, especially those already using Microsoft software.
  • Google Cloud Platform (GCP) — strong in AI, machine learning, and data analytics.

Frequently asked questions about cloud computing

Is cloud computing safe?
Generally yes — major cloud providers invest billions in security, far more than most companies could afford on their own. They use encryption, access controls, and redundant systems. That said, users can still make mistakes (weak passwords, misconfigured settings) that create vulnerabilities. Security is a shared responsibility between the provider and the user.
What is the difference between cloud computing and the internet?
The internet is the global network that connects devices. Cloud computing is a service that runs over the internet — it uses the internet to deliver computing resources like storage, processing power, and software. Think of the internet as the road and cloud computing as one of the things traveling on it.
Do I need to know programming to use cloud computing?
Not necessarily. SaaS products like Google Docs or Dropbox require no technical skills at all. IaaS and PaaS services like AWS EC2 do require some technical knowledge. But cloud providers all offer beginner-friendly consoles and extensive documentation — many developers learn cloud platforms without formal training.
What is a cloud server?
A cloud server is a virtual server — a simulated computer running on physical hardware inside a data center. It behaves exactly like a regular server (runs an operating system, hosts websites, processes data) but it's not a physical machine you can touch. You can create and delete cloud servers in seconds, and you pay by the hour or minute.
What is the difference between cloud computing and web hosting?
Web hosting is a specific use of cloud computing — renting server space to host a website. Cloud computing is the broader category that includes web hosting plus storage, databases, AI services, networking, and much more. All web hosting uses some form of cloud infrastructure, but cloud computing covers far more than just hosting websites.

Enjoying CloudBytze? ☁️

Get each new article free in your inbox.

☁️ Feed Byte $1
← Back to articles
BEGINNER · LINUX

What Is SSH? How Secure Shell Works, Explained Simply

Quick answer

SSH (Secure Shell) is a protocol that lets you securely connect to and control a remote computer over the internet using your terminal. It encrypts all communication so nobody can eavesdrop on your connection.

Every time a developer "SSHs into a server," they're opening a secure, encrypted tunnel between their computer and a remote machine. It's how you manage cloud servers, deploy code, and run commands on computers you're not physically sitting in front of. If you work with cloud infrastructure at any point, you will use SSH constantly.

What does SSH stand for?

SSH stands for Secure Shell. The "shell" part refers to a command-line interface — the text-based way of controlling a computer. The "secure" part means everything sent over the connection is encrypted.

Before SSH existed, developers used a protocol called Telnet to connect to remote machines. Telnet sent everything in plain text — including passwords — meaning anyone on the same network could read everything. SSH was created in 1995 to fix this.

How does SSH work?

When you connect to a server via SSH, several things happen:

  1. Your computer contacts the server and they agree on an encryption method
  2. The server proves its identity using a cryptographic key (to prevent fake servers)
  3. You prove your identity with either a password or your own cryptographic key
  4. An encrypted tunnel is established — everything you type and receive is scrambled in transit
  5. You now have a command-line session on the remote machine, as if you were sitting in front of it

The whole handshake takes about a second. After that, you type commands and the remote computer executes them — the output appears in your terminal.

How to use SSH — the basic command

The syntax is straightforward:

ssh username@server-ip-address

# Example:
ssh ubuntu@54.210.123.45

If it's your first time connecting to that server, you'll see a prompt like this:

The authenticity of host '54.210.123.45' can't be established.
ECDSA key fingerprint is SHA256:abc123...
Are you sure you want to continue connecting (yes/no)?

Type yes. This saves the server's fingerprint so you'll be warned if it ever changes (which could indicate someone intercepting your connection).

SSH keys vs passwords

There are two ways to authenticate with SSH. Passwords are simpler but less secure. SSH keys are the professional standard.

Using a password

You just type your password when prompted. Easy, but passwords can be guessed, phished, or brute-forced.

Using SSH keys (recommended)

SSH keys are pairs of cryptographic files — a private key that stays on your computer, and a public key that you put on the server. They work like a padlock and key: the server has the padlock (public key), and only your private key can open it. No password needed.

# Step 1: Generate a key pair on your local machine
ssh-keygen -t ed25519 -C "your@email.com"
# This creates two files:
# ~/.ssh/id_ed25519       (your private key — NEVER share this)
# ~/.ssh/id_ed25519.pub   (your public key — put this on servers)

# Step 2: Copy your public key to the server
ssh-copy-id ubuntu@54.210.123.45

# Step 3: Now connect without a password
ssh ubuntu@54.210.123.45

Connecting with a key file (AWS / DigitalOcean style)

Cloud providers like AWS give you a .pem key file when you create a server. Use it like this:

ssh -i ~/.ssh/my-key.pem ubuntu@54.210.123.45

The -i flag tells SSH which key file to use. On Mac/Linux, you may need to fix the file permissions first:

chmod 400 ~/.ssh/my-key.pem

Useful SSH tricks

# Run a single command without an interactive session
ssh ubuntu@server "ls -la /var/www"

# Copy a file TO a remote server (SCP — uses SSH)
scp myfile.txt ubuntu@server:/home/ubuntu/

# Copy a file FROM a remote server
scp ubuntu@server:/home/ubuntu/log.txt ./local-copy.txt

# Forward a remote port to your local machine (port tunneling)
ssh -L 8080:localhost:3000 ubuntu@server
# Now visit localhost:8080 in your browser to see the remote app

The SSH config file — stop typing long commands

If you SSH into the same servers often, add them to ~/.ssh/config:

Host myserver
  HostName 54.210.123.45
  User ubuntu
  IdentityFile ~/.ssh/my-key.pem

Now you just type ssh myserver and it fills in everything else. Game changer.

Frequently asked questions about SSH

What is SSH used for?
SSH is used to securely connect to and control remote computers over the internet. Common uses include managing cloud servers, transferring files securely, running deployment scripts, accessing databases, and tunneling network traffic. It is the standard way developers and system administrators interact with remote Linux servers.
Is SSH the same as a VPN?
No, they serve different purposes. SSH encrypts a connection to a specific remote computer, giving you a command-line session on that machine. A VPN encrypts all of your internet traffic and routes it through a different network. SSH is for accessing servers; VPNs are for protecting your general internet traffic or accessing a private network.
What port does SSH use?
SSH runs on port 22 by default. Some servers change this to a different port number as a security measure (called security through obscurity). If a server uses a non-standard port, you specify it with the -p flag: ssh -p 2222 ubuntu@server.
What is the difference between SSH and SFTP?
SFTP (SSH File Transfer Protocol) is a file transfer protocol that runs on top of SSH. Regular SSH gives you a command-line session to run commands. SFTP gives you a file-browser-style interface for transferring files, using the same encryption and authentication as SSH. Tools like FileZilla use SFTP under the hood.
Can I use SSH on Windows?
Yes. Windows 10 and 11 include a built-in SSH client — just open Command Prompt or PowerShell and type ssh. You can also use Windows Subsystem for Linux (WSL) for a full Linux terminal experience. Historically, Windows users used a tool called PuTTY for SSH, but the built-in client has mostly replaced it.

More articles like this ☁️

Subscribe free — new posts in your inbox.

☁️ Feed Byte $1
← Back to articles
NEW · BEGINNER · CLOUD

Cloud Storage vs Local Storage: What's the Difference?

Quick answer

Local storage means saving files on a physical device you own — your hard drive, SSD, or USB. Cloud storage means saving files on servers on the internet, managed by a company like Google or Apple. Cloud storage is accessible anywhere; local storage is faster and works without internet.

Every time you save a file you're making a choice — even if you never thought about it. It goes to your hard drive (local) or to the internet (cloud). Both are useful. Neither is always better. Here's how to think about which one to use when.

What is local storage?

Local storage is any physical storage device that you own and keep with you — the hard drive or SSD inside your laptop, an external hard drive, a USB stick, or a memory card. Files saved locally exist only on that device. If the device breaks, gets lost, or is stolen, the files are gone unless you made a separate copy.

What is cloud storage?

Cloud storage means your files live on servers maintained by another company, accessible through the internet. Examples include Google Drive, iCloud, Dropbox, OneDrive, and Amazon S3. You access your files via a browser or app. As long as you have internet access, your files are available from any device.

Cloud storage vs local storage — side by side

Accessibility

Local: Only accessible on the device (or network) where the file is stored. If it's on your laptop at home, you can't get it from your phone at work.
Cloud: Accessible from any device with internet. Open your phone, tablet, work computer — your files are there.

Speed

Local: Very fast. Reading and writing happens at the speed of your drive, no internet required. Great for large files, video editing, or gaming.
Cloud: Limited by your internet speed. Uploading a 10GB video file can take minutes or hours depending on your connection.

Cost

Local: One-time purchase. A 2TB external hard drive costs around $60 and lasts years. No monthly fee.
Cloud: Ongoing subscription. Google One starts at $3/month for 200GB. iCloud 2TB is $11/month. Costs add up over time but often include extra features.

Security and privacy

Local: You control it completely. Nobody can access it remotely (unless you share it). But physical theft or drive failure means losing your data.
Cloud: The provider can theoretically access your files (check the terms of service). Good providers encrypt your data in transit and at rest. You're protected from physical loss, but you're trusting a third party.

Backup and reliability

Local: No automatic backup. If your hard drive fails (and they all fail eventually), your data is gone unless you backed it up yourself.
Cloud: Built-in redundancy. Cloud providers store your files in multiple locations. If one server fails, another takes over. Your data survives hardware failures automatically.

Sharing and collaboration

Local: Sharing requires physically transferring files (USB, email) or setting up a network share. Hard to collaborate in real time.
Cloud: Share a link. Multiple people can view, edit, and comment on the same file simultaneously (Google Docs is the obvious example).

When to use local storage

  • Large files you access often (video projects, game installs, raw photo libraries)
  • Working in places without reliable internet
  • Sensitive data you don't want on third-party servers
  • Backups of your most important files (the classic rule: keep files in at least 2 places)
  • Speed-critical work like video editing

When to use cloud storage

  • Documents, photos, and files you want on every device
  • Collaboration with other people
  • Automatic backup of important files
  • Accessing work files from home (or vice versa)
  • Sharing large files without email attachments

The honest answer: use both

The best approach isn't either/or — it's both. Use cloud storage for files you need everywhere and want backed up automatically. Use local storage for large files and as an offline backup of your most important data. The classic backup rule is 3-2-1: three copies of your data, on two different media types, with one stored off-site (which the cloud handles perfectly).

Frequently asked questions

Is cloud storage safer than local storage?
It depends on what you mean by "safer." Cloud storage is safer against physical disasters — fire, flood, theft, or drive failure — because your files are backed up in multiple locations. Local storage is safer from unauthorized remote access because files aren't accessible over the internet. For maximum safety, use both: keep local copies and back them up to the cloud.
What happens to my cloud files if I lose internet access?
Most cloud storage apps (Google Drive, Dropbox, OneDrive) let you mark files for offline access — they sync to your device while you're connected, then remain accessible without internet. Without this setting, you won't be able to access files while offline. This is one reason local storage still matters even when you use the cloud heavily.
What is the best cloud storage service?
For most people, Google One (200GB for $3/month) or iCloud (200GB for $3/month) offer the best value. Apple users integrate best with iCloud; Android/cross-platform users benefit more from Google Drive. Dropbox has better desktop sync performance but costs more. For developers storing app data or large files, Amazon S3 is the industry standard.
Can cloud storage replace a hard drive?
For most everyday files — documents, photos, music — yes, cloud storage can replace a traditional hard drive as your primary storage, especially as internet speeds improve. However, for large local applications, games, video projects, and offline work, a local drive is still necessary. Laptops are increasingly shipping with smaller SSDs because cloud storage handles what used to require huge local disks.
Is cloud storage free?
Most cloud storage services offer a free tier: Google Drive gives 15GB free, iCloud gives 5GB free, and Dropbox gives 2GB free. These free tiers are enough for documents and basic photos but fill up quickly. Paid plans typically start around $3/month for 100-200GB and scale up from there.

Found this helpful? ☁️

Get more plain-English tech explainers in your inbox.

☁️ Feed Byte $1
← Back to articles
BEGINNER · AWS

What Even Is AWS S3? A Beginner's Plain-English Guide

The short version

AWS S3 (Simple Storage Service) is Amazon's cloud storage service — a place to store any kind of file on the internet. You put files into containers called buckets, access them from anywhere, and pay only for what you store. It costs about 2 cents per gigabyte per month.

S3 is everywhere. It powers the uploads on apps you use every day, stores backups for thousands of companies, and hosts more static websites than you'd guess. But every time someone tries to explain it, they lead with words like "object storage" and "scalable data infrastructure" — and that's where most beginners check out.

Let's try a different approach. Here's S3 from the very beginning, no assumed knowledge.

What is S3, actually?

S3 is a place on the internet where you can store files. That's it. Think of it like a hard drive that lives in Amazon's data centers instead of inside your laptop — one that never fills up, never breaks, and can be accessed from anywhere in the world.

You can store images, videos, PDFs, code files, database backups, log files, or any other kind of data. S3 doesn't care what the files are. It just stores them reliably and makes them available whenever you need them.

S3 is like Google Drive for your apps — except instead of a human clicking upload, your code does it automatically.

What's a bucket?

S3 organizes everything into buckets. A bucket is basically a top-level container — like a folder, except it lives at the root level and has its own unique name across all of AWS globally.

When you create a bucket, you give it a name (which must be unique across every AWS account in the world) and choose a region — a physical location for your data, like US East or EU West. Choosing a region close to your users reduces latency.

Inside a bucket, each file is called an object. Every object has:

  • A key — the file's path and name, like images/profile.jpg or backups/2026-06-08.zip
  • The data — the actual contents of the file
  • Metadata — information about the file, like its size, content type, and when it was last modified

How do you actually use S3?

There are three main ways to interact with S3, depending on what you're doing.

The AWS Console

The easiest way to start. Log into your AWS account, navigate to S3, click "Create bucket", pick a name and region, and you're in. You can drag and drop files directly in the browser, browse your objects, and configure settings with clicks. Good for learning the ropes and doing occasional manual work.

The AWS CLI

Once you've installed the AWS CLI on your computer, you can manage S3 entirely from the terminal:

# Upload a file to your bucket
aws s3 cp photo.jpg s3://my-bucket-name/photos/photo.jpg

# Download a file from S3 to your current folder
aws s3 cp s3://my-bucket-name/photos/photo.jpg ./photo.jpg

# List everything inside a bucket
aws s3 ls s3://my-bucket-name/

# Sync an entire folder to S3
aws s3 sync ./dist s3://my-bucket-name/website/

# Delete a file
aws s3 rm s3://my-bucket-name/photos/old-photo.jpg

Inside your application (using the SDK)

Most real-world S3 usage happens inside code. AWS has SDKs for every major language. Here's what uploading a file looks like in Node.js:

const { S3Client, PutObjectCommand } = require("@aws-sdk/client-s3");
const fs = require("fs");

const client = new S3Client({ region: "us-east-1" });

async function uploadFile(localPath, bucketName, key) {
  const fileContent = fs.readFileSync(localPath);

  await client.send(new PutObjectCommand({
    Bucket: bucketName,
    Key: key,
    Body: fileContent,
    ContentType: "image/jpeg",
  }));

  console.log(`Uploaded to s3://${bucketName}/${key}`);
}

uploadFile("./photo.jpg", "my-app-bucket", "uploads/photo.jpg");

What does S3 actually cost?

For most beginners and small projects, very little. AWS gives you 5 GB of S3 storage free for your first 12 months. After the free tier, pricing breaks down roughly like this:

  • Storage: ~$0.023 per GB per month (2.3 cents/GB)
  • GET requests (downloading/reading files): $0.0004 per 1,000 requests
  • PUT requests (uploading files): $0.005 per 1,000 requests
  • Data transfer out to the internet: ~$0.09 per GB

To put that in perspective: storing 100 GB of files costs about $2.30 per month. Running a small app that stores user profile photos for a few hundred users will likely cost less than a dollar a month.

What is S3 actually used for?

Once you start looking, S3 is behind a surprising number of things:

  • User uploads — profile pictures, documents, videos that users upload to your app
  • Static website hosting — you can serve a complete HTML/CSS/JS website directly from an S3 bucket
  • Database backups — automated database dumps stored safely off the main server
  • Log storage — application logs, access logs, and event logs that would fill up a server disk
  • Media storage for CDN — storing images and videos that get served through CloudFront (Amazon's CDN)
  • Data pipelines — raw data dropped into S3 that gets processed by other services like AWS Lambda or Athena
  • Software distribution — downloadable files, app builds, release packages

The thing that trips up almost every beginner

By default, everything in S3 is private. If you upload a file and try to open the URL directly in your browser, you'll get an "Access Denied" error. This is intentional and good for security — but confusing the first time.

There are a few ways to make files accessible:

  • Make the bucket public — allows anyone to read any file. Use only for static websites or genuinely public assets. Never do this for user data.
  • Pre-signed URLs — temporary links you generate in your code that expire after a set time (e.g., 15 minutes). The right approach for most user-facing use cases.
  • CloudFront — Amazon's CDN. You keep the bucket private but let CloudFront serve the files publicly through its global edge network.
// Generate a pre-signed URL that expires in 15 minutes
const { getSignedUrl } = require("@aws-sdk/s3-request-presigner");
const { GetObjectCommand } = require("@aws-sdk/client-s3");

const url = await getSignedUrl(
  client,
  new GetObjectCommand({ Bucket: "my-bucket", Key: "uploads/photo.jpg" }),
  { expiresIn: 900 } // 900 seconds = 15 minutes
);

// Share this URL — it works for 15 minutes, then expires

Questions people always ask about S3

Is AWS S3 the same as a database?
No. S3 is object storage — it stores files as discrete blobs. A database stores structured data you can query. You'd use a database (like PostgreSQL or DynamoDB) to store user records, and S3 to store the files those users upload. The two often work together: the database stores a reference to the S3 location of a file, and the app retrieves it from S3 when needed.
How is S3 different from a regular web server?
A web server runs code and responds to requests dynamically. S3 just stores and serves static files — it doesn't run any logic. You can host a static website (plain HTML, CSS, JavaScript) on S3 for almost nothing, but you can't run a Node.js or Python app directly on it. For dynamic apps, you'd use S3 for file storage and EC2, Lambda, or App Platform for the actual application code.
What happens if S3 goes down?
S3 is one of the most reliable services AWS offers. Amazon publishes an SLA of 99.9% uptime, and the actual track record is better than that. S3 stores each object redundantly across multiple facilities within the region, so a single hardware failure doesn't affect your data. There have been a handful of notable S3 outages over the years, but they're rare and typically short-lived.
Do I need an AWS account to use S3?
Yes, you need an AWS account. Creating one is free and takes about 10 minutes. You'll need a credit card on file, but AWS won't charge you during the free tier period (first 12 months, up to 5 GB of S3 storage). After that, charges only occur when you use the service, and they're billed at the end of each month.
Is S3 secure?
S3 is secure by default — all objects are private unless you explicitly make them public. Data is encrypted at rest using AES-256. Data in transit is encrypted using HTTPS/TLS. You can add additional controls like bucket policies, IAM permissions, and access logging. The most common S3 security mistakes come from misconfiguration (accidentally making buckets public), not from weaknesses in S3 itself.

Enjoying CloudBytze? ☁️

Get each new article free — straight to your inbox.

☁️ Feed Byte $1
← Back to articles
BEGINNER · GIT

Git Commands I Use Every Day (and What They Actually Do)

The short version

Git is a version control system — it tracks changes to your code over time so you can undo mistakes, collaborate with others, and maintain a full history of your project. These are the commands you'll use constantly once you start.

Most Git tutorials begin with a diagram explaining branching strategies and merge conflict resolution. That's fine eventually, but it's not what you need on day one. What you need is a handful of commands that cover the real situations that come up every single day — and an honest explanation of what each one actually does.

Here they are. No theory preamble, no git history lesson.

The commands you'll use every single day

git status — always start here

Before you do anything else in a project, run this. It tells you exactly what's happening: which files you've changed, which ones are staged and ready to commit, and which ones Git doesn't know about yet.

git status

Get into the habit of running it constantly. It's completely harmless — it never changes anything — and it saves you from a lot of confusion about what state your project is in.

git add — stage your changes

Staging means telling Git "I want to include these changes in my next commit." You can add specific files, a folder, or everything at once.

# Stage one specific file
git add index.js

# Stage everything that changed
git add .

# Stage all files in a specific folder
git add src/components/

# Stage parts of a file interactively (advanced)
git add -p

The reason staging exists (rather than just committing everything at once) is so you can bundle related changes into one commit even if you've been editing multiple unrelated things.

git commit — save a snapshot

A commit is a permanent snapshot of your staged changes, saved to your project's history. The message should describe what changed and — more importantly — why.

git commit -m "fix: redirect to login page when session expires"

# Stage everything and commit in one step (skips staging for tracked files)
git commit -am "update header styles for mobile"

Good commit messages make your history readable. Instead of "fixed stuff" or "changes", write something your future self will understand at a glance three months later.

git push — send your commits to GitHub

Commits live locally on your machine until you push them. Push sends them to the remote repository (GitHub, GitLab, etc.) so others can see them and so they're backed up.

# Push to the main branch
git push origin main

# Push a feature branch
git push origin feature/user-auth

# Push and set the upstream (first push of a new branch)
git push -u origin feature/user-auth

git pull — get the latest changes

Pull downloads and merges changes from the remote into your local branch. Always pull before you start working, especially when collaborating with others.

git pull

# Pull a specific branch
git pull origin main

The ones you need when things get more interesting

git log — see your project's history

Shows the list of commits, most recent first. The default output is verbose, so --oneline is your friend.

git log

# Compact, one line per commit
git log --oneline

# Show a visual graph of branches
git log --oneline --graph --all

git branch — work in isolation

Branches let you work on a feature without touching the main codebase. When you're done, you merge it back in. Always branch off main before starting anything new.

# See all your branches
git branch

# Create and immediately switch to a new branch
git checkout -b feature/add-dark-mode

# Switch between branches
git checkout main

# Modern alternative to checkout (Git 2.23+)
git switch main
git switch -c feature/add-dark-mode

git stash — shelve your unfinished work

Stash is for when you're mid-task but need to quickly switch to something else without committing half-done work. It saves your current changes to a temporary shelf, cleans your working directory, and lets you retrieve them later.

# Stash your current changes
git stash

# See what's in your stash
git stash list

# Get your stashed changes back (and remove them from the stash)
git stash pop

# Apply stash without removing it from the list
git stash apply

git diff — see exactly what changed

Shows the line-by-line differences between your current files and the last commit. Great for reviewing your own work before staging or committing.

# See unstaged changes
git diff

# See changes that are staged (ready to commit)
git diff --staged

# Compare two branches
git diff main feature/add-dark-mode

The ones you search for in a panic

git reset — undo a commit (locally)

There are two useful variants. Use --soft when you committed too early and want to un-commit but keep your changes staged. Leave off the flag to unstage everything but keep the files as-is.

# Undo the last commit, keep changes staged
git reset --soft HEAD~1

# Undo the last commit, unstage everything (but keep the file changes)
git reset HEAD~1

# Nuclear option: undo commit AND throw away all changes
# (cannot be undone — be very sure)
git reset --hard HEAD~1

git revert — undo a commit safely

Unlike reset, revert doesn't rewrite history. It creates a new commit that reverses a previous one. This is the right tool when you've already pushed the commit to a shared branch and can't just reset.

# Get the commit hash from git log --oneline, then:
git revert abc1234

# Revert without immediately creating a commit
git revert --no-commit abc1234

git restore — discard changes to a file

Throws away all unsaved changes in a file and restores it to what it looked like at the last commit. Cannot be undone.

# Discard changes to one file
git restore index.js

# Discard all unstaged changes in the whole project
git restore .

A workflow that actually works day to day

Here's the sequence I use every time I start on something new:

# 1. Make sure I'm on main and up to date
git checkout main
git pull

# 2. Branch off for this task
git checkout -b fix/broken-search-results

# 3. Do the work, check what changed
git status
git diff

# 4. Stage and commit with a clear message
git add .
git commit -m "fix: search results now return correct page count"

# 5. Push the branch
git push -u origin fix/broken-search-results

# 6. Open a pull request on GitHub

That loop handles the vast majority of real day-to-day development work. The other commands above are there for when things go sideways — and they will, occasionally. Now you're ready for that too.

Common Git questions

What is the difference between Git and GitHub?
Git is the version control software that runs on your computer and tracks changes to your code. GitHub is a website that hosts Git repositories online, making it easy to share code, collaborate with others, and back up your work. You use Git locally and push your changes to GitHub. GitLab and Bitbucket are alternatives to GitHub that work the same way.
What is a merge conflict and how do you fix one?
A merge conflict happens when two people change the same part of the same file in different branches, and Git can't figure out which version to keep. Git marks the conflicting sections in the file with special markers. You open the file, manually decide which version is correct (or combine both), remove the markers, stage the file, and complete the merge with git commit. Tools like VS Code show conflicts visually, which makes this much less painful.
How do I undo a git add before committing?
Use git restore --staged filename to unstage a specific file, or git restore --staged . to unstage everything. This removes the file from the staging area without affecting the actual changes you made to it — the file still has your edits, it just won't be included in the next commit.
What does HEAD mean in Git?
HEAD is just a pointer to whatever commit you're currently on — usually the latest commit on your current branch. When you see HEAD~1 in commands, it means "one commit before the current one." HEAD~2 means two commits back. It's shorthand so you don't have to look up and type out the full commit hash every time.
What is git fetch vs git pull?
git fetch downloads changes from the remote but doesn't apply them to your local branch. It just updates your local record of what the remote looks like. git pull does a fetch and then immediately merges those changes into your current branch. Most of the time you want git pull. Use git fetch when you want to inspect incoming changes before merging them.

More articles like this ☁️

Subscribe free — each new post goes straight to your inbox.

☁️ Feed Byte $1
← Back to articles
BEGINNER · DOCKER

Docker Explained: Why Everyone Is Obsessed With Containers

The short version

Docker lets you package an application and everything it needs to run — the code, runtime, libraries, config — into a single portable unit called a container. That container runs the same way on every machine, eliminating the "it works on my laptop" problem that has plagued developers for decades.

"It works on my machine." Four words responsible for more late-night debugging sessions than almost anything else in software. You spend hours setting up a project locally. Everything works. You deploy it to a server. It crashes immediately. The server has a slightly different version of Node, or a library you forgot to document, or an OS-level dependency you installed so long ago you don't even remember it. Docker was built specifically to kill this problem.

What is a container?

A container is a lightweight, isolated environment that packages your application with everything it needs to run. The operating system, runtime, libraries, environment variables, configuration files — all of it, bundled together into one portable unit.

The key property is that a container runs identically everywhere. On your MacBook, on a Windows machine, on an Ubuntu server in AWS, on your coworker's Linux laptop — same behavior. The container doesn't know or care what's on the host machine outside of it.

A container is like a shipping container. It doesn't matter what ship it goes on or what port it lands at — the contents are the same and arrive intact.

Containers vs virtual machines — what's the difference?

Virtual machines (VMs) solve a similar problem but in a much heavier way. A VM includes a complete operating system, its own kernel, and all the overhead that comes with it. Running a few VMs on a laptop would bring it to its knees.

Containers are different. They share the host machine's OS kernel and only bundle the parts of the environment that differ between applications. A container that runs a Node.js app might be 100–200 MB. A VM running the same app might be several gigabytes.

The result: containers start in seconds (sometimes milliseconds), use a fraction of the memory, and you can run dozens on a single machine. This is why the industry shifted so heavily toward containers over the past decade.

Images vs containers — this confuses everyone at first

Before going further, you need to understand the distinction between two terms Docker uses constantly:

  • An image is a blueprint — a static, read-only snapshot of the environment your application needs. Think of it like a recipe. You build it once; it doesn't change.
  • A container is a running instance of an image — the meal made from the recipe. You can run many containers from a single image, and each one is isolated from the others.

You build images. You run containers. The image is what you ship and version-control; the container is what's actually running in production.

The Dockerfile — how you define an image

A Dockerfile is a plain text file with a list of instructions for building your image. Docker reads it top to bottom and creates a new image layer for each instruction. Here's a real Dockerfile for a Node.js app:

# Start from the official Node.js image (alpine = smaller size)
FROM node:20-alpine

# Set the working directory inside the container
WORKDIR /app

# Copy package files first (for better layer caching)
COPY package*.json ./

# Install dependencies
RUN npm install

# Copy the rest of the application code
COPY . .

# Tell Docker this container listens on port 3000
EXPOSE 3000

# The command to run when the container starts
CMD ["node", "server.js"]

A few things worth knowing about this file: the order of instructions matters. Docker caches each layer, so putting COPY package*.json and RUN npm install before copying the rest of your code means Docker won't re-run npm install every time you change a source file. This dramatically speeds up rebuilds.

Essential Docker commands

# Build an image from the Dockerfile in the current directory
# -t gives it a name and optional tag
docker build -t my-app:latest .

# Run a container from that image
# -p maps host port 8080 to container port 3000
# -d runs it in the background (detached)
docker run -p 8080:3000 -d my-app:latest

# See running containers
docker ps

# See all containers including stopped ones
docker ps -a

# Stop a container
docker stop container-id

# Remove a stopped container
docker rm container-id

# See all images on your machine
docker images

# Remove an image
docker rmi my-app:latest

# View logs from a running container
docker logs container-id
docker logs -f container-id   # -f follows in real time

# Open a shell inside a running container
docker exec -it container-id sh

Environment variables — keeping config out of your image

Never hardcode database passwords, API keys, or environment-specific settings inside your Docker image. Pass them in at runtime:

# Pass individual variables at run time
docker run -p 3000:3000 \
  -e DATABASE_URL=postgres://user:pass@localhost:5432/mydb \
  -e NODE_ENV=production \
  my-app:latest

# Or load from an .env file
docker run -p 3000:3000 --env-file .env my-app:latest

Docker Compose — running multiple containers together

Real applications almost always need more than one service — a web app, a database, maybe a cache. Docker Compose lets you define and start all of them with a single file and a single command.

Create a file called docker-compose.yml:

version: '3.8'

services:
  app:
    build: .
    ports:
      - "3000:3000"
    environment:
      - DATABASE_URL=postgres://user:pass@db:5432/myapp
      - NODE_ENV=development
    depends_on:
      - db
    volumes:
      - .:/app              # mount local code into container for live reload
      - /app/node_modules   # keep container's node_modules intact

  db:
    image: postgres:15-alpine
    environment:
      - POSTGRES_USER=user
      - POSTGRES_PASSWORD=pass
      - POSTGRES_DB=myapp
    volumes:
      - postgres-data:/var/lib/postgresql/data  # persist data across restarts
    ports:
      - "5432:5432"

volumes:
  postgres-data:

Then start everything:

# Start all services (in background)
docker-compose up -d

# See logs from all services
docker-compose logs -f

# Stop everything
docker-compose down

# Stop and delete volumes (wipes database data)
docker-compose down -v

The .dockerignore file

Just like .gitignore for Git, .dockerignore tells Docker which files to exclude from the build context. Without it, Docker will try to copy your entire project into the image — including node_modules, .git, and other things you definitely don't want in there.

node_modules
.git
.env
*.log
dist
coverage
.DS_Store

Why should you actually learn Docker?

Because almost every modern deployment pipeline uses it. Kubernetes (the industry-standard container orchestration system), AWS ECS, Google Cloud Run, DigitalOcean App Platform, Render, Railway — they all run containers. If you want to deploy apps professionally in 2026, Docker is the layer everything else builds on.

On a more practical level: once you've containerized a project, setting it up on any new machine takes one command — docker-compose up — instead of an afternoon of installing dependencies, debugging version conflicts, and reading README files. Your team members can clone the repo and be running the full stack in under two minutes, regardless of what OS they use.

Common Docker questions

What is Docker Hub?
Docker Hub is a public registry of Docker images. When your Dockerfile says FROM node:20-alpine, Docker automatically pulls that image from Docker Hub. You can also push your own images there (publicly or privately) and pull them from any machine. It's essentially GitHub for Docker images. AWS ECR, Google Artifact Registry, and GitHub Container Registry are alternatives.
What is the difference between Docker and Kubernetes?
Docker creates and runs individual containers. Kubernetes (often called K8s) is an orchestration system that manages large numbers of containers across multiple machines — handling things like auto-scaling, load balancing, rolling deployments, and self-healing. Docker is the foundation; Kubernetes sits on top of it. Most teams use Docker without Kubernetes for smaller projects, and bring in Kubernetes when scale demands it.
How is Docker different from a virtual machine?
Virtual machines emulate a complete computer, including a full operating system and kernel. Containers share the host's OS kernel and only isolate the application environment. This makes containers much lighter — a container starts in seconds and uses far less memory than a VM running the same application. The tradeoff is that containers offer slightly less isolation than VMs, though in practice this rarely matters for most applications.
Is Docker free?
Docker Engine (the core software) is free and open-source. Docker Desktop (the GUI application for Mac and Windows) is free for personal use and small businesses but requires a paid subscription for larger companies. Docker Hub has a free tier that allows unlimited public images and a limited number of private images. For most individual developers and small teams, Docker is effectively free.
Should I use Docker for every project?
Not necessarily. For simple static websites or very small scripts, Docker adds overhead without much benefit. It really shines for applications with multiple services (web app + database + cache), projects with multiple team members, anything you're deploying to production, and situations where you need consistent environments across different machines. If you're asking "does this project need Docker?", a good rule of thumb is: if it has more than one service or more than one developer, Docker is probably worth it.

Found this useful? ☁️

Subscribe for free — new articles in your inbox when they're ready.

☁️ Feed Byte $1
🎉
NOM NOM!
Byte says thank you!