2 Commits

Author SHA1 Message Date
mr
cc8d599ce5 deploy demo alpr 2025-11-17 08:08:56 +01:00
mr
a7d1cc3429 argo.sh 2025-11-07 11:31:47 +01:00
3 changed files with 30 additions and 9 deletions

View File

@@ -1,7 +1,14 @@
# RUN DOCKER DEMO
ADD a clean argo
```
sudo ./clone_opencloud_microservices.sh
./run_argo.sh
```
Verify with `kubectl get pods -n argo -w` -> all server are running and 1/1
Any problem with this, can be a top problem from your k3s or k8s (FIX IT BEFORE)
```
sudo ./clone_opencloud_microservices.sh demo-alpr
cd ./docker
./start-demo.sh
```

View File

@@ -39,14 +39,9 @@ do
docker kill $i | true
docker rm $i | true
cd ./$i
cat > ./env.env <<EOF
KUBERNETES_SERVICE_HOST=$host
KUBERNETES_SERVICE_PORT=$port
KUBE_CA="$ca"
KUBE_CERT="$cert"
KUBE_DATA="$key"
EOF
docker build . -t $i --build-arg=HOST=$HOST && docker compose up -d
docker build . -t $i --build-arg=HOST=$HOST --build-arg=KUBERNETES_SERVICE_HOST=$host \
--build-arg=KUBERNETES_SERVICE_PORT=$port --build-arg=KUBE_CA=$ca --build-arg=KUBE_CERT=$cert \
--build-arg=KUBE_DATA=$key && docker compose up -d
cd ..
done

19
run_argo.sh Executable file
View File

@@ -0,0 +1,19 @@
#!/bin/bash
set -e
kubectl get pods -n kube-system -o name | xargs -n1 kubectl delete --force --grace-period=0 -n kube-system
NAMESPACE="argo"
ARGO_MANIFEST="https://raw.githubusercontent.com/argoproj/argo-workflows/stable/manifests/install.yaml"
echo "=== Create namespace if missing ==="
kubectl get ns $NAMESPACE >/dev/null 2>&1 || kubectl create ns $NAMESPACE
echo "=== Delete all dangling pods in $NAMESPACE ==="
kubectl delete pod --all -n $NAMESPACE --ignore-not-found
echo "=== Apply Argo manifests ==="
kubectl apply -n $NAMESPACE -f $ARGO_MANIFEST
echo "=== All done! ==="
kubectl get pods -n $NAMESPACE