https://github.com/octohelm/kubepkg
WIP
https://github.com/octohelm/kubepkg
airgap kubepkg kubernetes operator
Last synced: 4 months ago
JSON representation
WIP
- Host: GitHub
- URL: https://github.com/octohelm/kubepkg
- Owner: octohelm
- License: mit
- Created: 2022-03-28T08:31:35.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2024-03-07T12:57:15.000Z (over 2 years ago)
- Last Synced: 2024-11-18T02:42:56.311Z (over 1 year ago)
- Topics: airgap, kubepkg, kubernetes, operator
- Language: Go
- Homepage:
- Size: 1.72 MB
- Stars: 2
- Watchers: 1
- Forks: 2
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# KubePkg
```mermaid
%%{init:{'theme':'base'}}%%
sequenceDiagram
actor dev
box centre
participant kubepkg_dashboard as KubePkg Dashboard
end
box k3s/k8s cluster
participant cluster_kubepkg_agent as KubePkg Agent
participant cluster_k8s_api as Kubernetes API
participant cluster_kubepkg_operator as KubePkg Operator
participant cluster_container_registry as Container Registry
participant cluster_pod as Workloads
end
par setup
cluster_kubepkg_agent ->> kubepkg_dashboard: register
end
par version
dev ->> kubepkg_dashboard: put KubePkg.yaml
end
par direct
kubepkg_dashboard ->> cluster_kubepkg_agent: put KubePkg.yaml
activate cluster_kubepkg_agent
cluster_kubepkg_agent ->> cluster_k8s_api: apply KubePkg.yaml
deactivate cluster_kubepkg_agent
end
par airgap
kubepkg_dashboard ->> dev: get KubePkg.yaml
activate dev
dev ->> dev: create KubePkg.airgap.tgz
dev ->> cluster_kubepkg_agent: update KubePkg.airgap.tgz
deactivate dev
activate cluster_kubepkg_agent
cluster_kubepkg_agent ->> cluster_container_registry: upload images
cluster_kubepkg_agent ->> cluster_k8s_api: apply KubePkg.yaml
deactivate cluster_kubepkg_agent
end
par CRD to Kubernetes resources
loop watch CRD kubepkg
cluster_k8s_api -->> cluster_kubepkg_operator: convert to Kubernetes resources
cluster_kubepkg_operator ->> cluster_k8s_api: apply kubepkg resources
end
par pod creation
cluster_container_registry ->> cluster_pod: pull images
loop watch kubepkg resources
cluster_k8s_api -->> cluster_kubepkg_operator: convert to KubePkg.State
end
end
end
```
## Requires
* Docker Image only support v2
* k3s/k8s 1.22+
## `kubepkg.airgap.tar`
* `kubepkg.json`: KubePkg CRD json
* [OCI Image Layout](https://github.com/opencontainers/image-spec/blob/main/image-layout.md)
```
kubepkg.json # must be first of all
blobs/ # blob contents
/
index.json # oci image layout required
oci-layout # oci image layout required
```