Prerequisites
Before building custom TinySystems modules, ensure you have the following tools installed and configured.
Required Software
Go 1.25+
TinySystems modules are written in Go. The SDK requires Go 1.25 or newer:
# macOS (Homebrew)
brew install go
# Linux (apt)
sudo apt update && sudo apt install golang-go
# Verify installation
go version
# go version go1.25.x linux/amd64
Kubernetes Cluster
You need a Kubernetes cluster for testing. Options:
Local Development (Recommended for getting started):
# kind (Kubernetes in Docker)
brew install kind
kind create cluster --name tinysystems-dev
# or minikube
brew install minikube
minikube start
Cloud Providers:
- Google Kubernetes Engine (GKE)
- Amazon EKS
- Azure AKS
- DigitalOcean Kubernetes
kubectl
The Kubernetes command-line tool:
# macOS
brew install kubectl
# Linux
curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl"
chmod +x kubectl
sudo mv kubectl /usr/local/bin/
# Verify
kubectl version --client
Docker
Required for building and pushing module images:
# macOS
brew install --cask docker
# Linux
curl -fsSL https://get.docker.com | sh
# Verify
docker --version
Optional Tools
Helm
For deploying modules to Kubernetes:
brew install helm
# or
curl https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 | bash
IDE
Recommended editors with Go support:
- VS Code with Go extension
- GoLand (JetBrains)
- Neovim with gopls
Verify Your Setup
Run this script to verify all prerequisites:
#!/bin/bash
echo "Checking prerequisites..."
# Go
if command -v go &> /dev/null; then
echo "✓ Go: $(go version)"
else
echo "✗ Go not installed"
fi
# kubectl
if command -v kubectl &> /dev/null; then
echo "✓ kubectl: $(kubectl version --client --short 2>/dev/null)"
else
echo "✗ kubectl not installed"
fi
# Docker
if command -v docker &> /dev/null; then
echo "✓ Docker: $(docker --version)"
else
echo "✗ Docker not installed"
fi
# Kubernetes cluster
if kubectl cluster-info &> /dev/null; then
echo "✓ Kubernetes cluster accessible"
else
echo "✗ No Kubernetes cluster accessible"
fi
# Helm (optional)
if command -v helm &> /dev/null; then
echo "✓ Helm: $(helm version --short)"
else
echo "○ Helm not installed (optional)"
fi
Cluster Setup for Development
If using a local cluster, install the TinySystems CRDs. The tinysystems-crd Helm chart ships all of them, or apply them individually:
kubectl apply -f https://raw.githubusercontent.com/tiny-systems/module/main/config/crd/bases/operator.tinysystems.io_tinymodules.yaml
kubectl apply -f https://raw.githubusercontent.com/tiny-systems/module/main/config/crd/bases/operator.tinysystems.io_tinynodes.yaml
kubectl apply -f https://raw.githubusercontent.com/tiny-systems/module/main/config/crd/bases/operator.tinysystems.io_tinyflows.yaml
kubectl apply -f https://raw.githubusercontent.com/tiny-systems/module/main/config/crd/bases/operator.tinysystems.io_tinyprojects.yaml
kubectl apply -f https://raw.githubusercontent.com/tiny-systems/module/main/config/crd/bases/operator.tinysystems.io_tinyscenarios.yaml
kubectl apply -f https://raw.githubusercontent.com/tiny-systems/module/main/config/crd/bases/operator.tinysystems.io_tinywidgetpages.yaml
Verify:
kubectl get crds | grep tinysystems
# tinyflows.operator.tinysystems.io
# tinymodules.operator.tinysystems.io
# tinynodes.operator.tinysystems.io
# tinyprojects.operator.tinysystems.io
# tinyscenarios.operator.tinysystems.io
# tinywidgetpages.operator.tinysystems.io
Project Structure Overview
A typical module project looks like:
my-module/
+-- cmd/
| +-- main.go # Entry point (cobra root command)
+-- components/
| +-- mycomponent/
| +-- mycomponent.go # Component implementation
+-- go.mod
+-- go.sum
+-- Dockerfile
+-- README.md
The fastest way to get this layout is the official template: open github.com/tiny-systems/example-module and click Use this template.
Next Steps
- SDK Installation - Install the TinySystems SDK
- Hello World Component - Build your first component