4 Commits

Author SHA1 Message Date
mr
8098a86dae One file to rule them all 2026-01-08 21:15:34 +01:00
mr
ec5c2972c3 command 2026-01-07 16:56:27 +01:00
mr
3d416169e3 Running all stack 2026-01-06 08:23:16 +01:00
mr
5a0651106d ReadMe Update 2025-11-12 13:37:04 +01:00
1915 changed files with 143024 additions and 399 deletions

2
.gitignore vendored
View File

@@ -1,3 +1,3 @@
opencloud/Chart.lock
deployed_config.sh
deployed_config
kind-logs

View File

@@ -30,6 +30,19 @@ go install sigs.k8s.io/kind@v0.30.0 && kind create cluster
Download suitable helm client here https://helm.sh/docs/intro/install/
# Generate values (optionnal)
Use command :
```
oc-k8s create values [release] [env_file (optionnal)]
```
or
```
./oc-k8s.sh create values [release] [env_file (optionnal)]
```
Map in a env file, any Variable you wish to override and give the path.
## Resume for a first start
```
oc-k8s start

BIN
cmd/kind-linux-amd64 Normal file

Binary file not shown.

144
cmd/main.go Normal file
View File

@@ -0,0 +1,144 @@
package main
import (
"fmt"
"oc-k8s/internal"
"os"
)
func main() {
defer func() {
if r := recover(); r != nil {
}
}()
if len(os.Args) < 2 {
internal.Help_Func()
fmt.Println("Error: Not enought arguments")
return
}
if err := action(); err != nil {
internal.Help_Func()
fmt.Println(err)
}
}
func action() error {
action := os.Args[1]
switch action {
case "start":
args := []string{}
if len(os.Args) > 2 {
args = os.Args[2:]
}
internal.Start(args...)
case "stop":
args := []string{}
if len(os.Args) > 2 {
args = os.Args[2:]
}
internal.Start(args...)
case "extract":
what := os.Args[2]
switch what {
case "charts":
return internal.ExtractTrees("assets", "./opencloud-chart")
}
case "help":
what := os.Args[2]
switch what {
case "helm":
internal.Help_Helm()
case "k3s":
internal.Help_K3S()
case "kind":
internal.Help_Kind()
case "cluster":
internal.Help_Cluster()
case "db":
internal.Help_DB()
case "services":
internal.Help_Service()
case "values":
internal.Help_Values()
default:
internal.Help_Func()
}
case "install":
if len(os.Args) < 3 {
return internal.Install_Func()
}
what := os.Args[2]
args := []string{}
if len(os.Args) > 3 {
args = os.Args[3:]
}
switch what {
case "helm":
return internal.Install_Helm()
case "k3s":
return internal.Install_K3S()
case "kind":
return internal.Install_Kind(args...)
default:
if len(os.Args) > 2 {
args = os.Args[2:]
}
internal.Install_Func(args...)
}
case "create":
what := os.Args[2]
args := []string{}
if len(os.Args) > 3 {
args = os.Args[3:]
}
switch what {
case "helm":
return internal.Create_Helm(args...)
case "cluster":
return internal.Create_Cluster(args...)
case "db":
return internal.Create_DB(args...)
case "services":
return internal.Create_Service(args...)
case "values":
return internal.Create_Values(args...)
default:
internal.Help_Func()
}
case "delete":
what := os.Args[2]
args := []string{}
if len(os.Args) > 3 {
args = os.Args[3:]
}
switch what {
case "helm":
return internal.Delete_Helm(args...)
case "cluster":
return internal.Delete_Cluster(args...)
case "db":
return internal.Delete_DB(args...)
default:
internal.Help_Func()
}
case "upgrade":
what := os.Args[2]
args := []string{}
if len(os.Args) > 3 {
args = os.Args[3:]
}
switch what {
case "helm":
return internal.Upgrade_Helm(args...)
case "db":
return internal.Upgrade_DB(args...)
default:
internal.Help_Func()
}
default:
internal.Help_Func()
}
return nil
}

BIN
cmd/oc-k8s Executable file

Binary file not shown.

View File

@@ -0,0 +1,39 @@
dependencies:
- name: openldap
repository: https://jp-gouin.github.io/helm-openldap/
version: 2.0.4
- name: traefik
repository: https://helm.traefik.io/traefik
version: 33.0.0
- name: nats
repository: https://nats-io.github.io/k8s/helm/charts/
version: 1.2.6
- name: mongodb
repository: https://charts.bitnami.com/bitnami
version: 16.3.1
- name: mongo-express
repository: https://cowboysysop.github.io/charts/
version: 6.5.2
- name: hydra
repository: https://k8s.ory.sh/helm/charts
version: 0.50.6
- name: keto
repository: https://k8s.ory.sh/helm/charts
version: 0.50.2
- name: loki
repository: https://grafana.github.io/helm-charts
version: 6.23.0
- name: grafana
repository: https://grafana.github.io/helm-charts
version: 8.6.4
- name: argo-workflows
repository: https://argoproj.github.io/argo-helm
version: 0.45.4
- name: docker-registry-ui
repository: https://helm.joxit.dev/
version: 1.1.3
- name: prometheus
repository: https://prometheus-community.github.io/helm-charts
version: 27.45.0
digest: sha256:11c96ddd86e2857872d7dafaa48b545870bef019169b0cc1c00ed3fb9f32b9ac
generated: "2026-01-08T21:09:54.004802973+01:00"

Binary file not shown.

Binary file not shown.

Some files were not shown because too many files have changed in this diff Show More