Important
This project has been moved to SafeDep/upkube, used internally.
upkube
is a ~60 MiB
container built using golang
with templ
html templating, no js. When deployed using UPKUBE_ENV=PROD
variables (recommended for production usage), it connects to the Kubernetes cluster using Pod Service Account. It does not have auth, it's built for usage behind Cloudflare Zero Trust.
...
serviceAccountName: upkube-sa
containers:
- name: upkube
image: ghcr.io/kunalsin9h/upkube:1.4.0
ports:
- containerPort: 8080
env:
- name: UPKUBE_ENV
value: "PROD"
- name: UPKUBE_HOST
value: "0.0.0.0"
- name: UPKUBE_PORT
value: "8080"
For full Kubernetes deployment example: k8s directory.
-
UPKUBE_HOST
- Set host for http service, default is127.0.0.1
-
UPKUBE_PORT
- Set port for http service, default is8080
-
UPKUBE_ENV
- Set application environment,PROD
orDEV
, default isDEV
.-
When using
PROD
environment (recommended for production usage),upkube
connects with in-cluster configuration to the Kubernetes cluster, which uses the service account Kubernetes provides to pods. -
When using
DEV
, it connects from a master url or a kubeconfig filepath. default is~/.kube/config
-
rules:
- apiGroups: ["apps"]
resources: ["deployments"]
verbs: ["get", "list", "patch", "update"]
- apiGroups: [""]
resources: ["pods"]
verbs: ["get", "list"]
While deployments
rule is essential, when you will also provide pods
list rules, upkube
will shows any error while fetching any image and its error.
- Support Activity Logs
- Request and Approve workflow
- go
- templ
- tailwindcss
- minikube
After cloning the repo...
Download dependencies and tools.
go mod download
Download and make sure minikube
is running, for local k8s testing.
minikube start
kubectl apply -f k8s/deployment.yml
Start live reloaded Application
go tool air
# or and run
make
This will start the application on specieif port (using env), or deafult is http://localhost:8080