mirror of
https://codeberg.org/27/inception-of-things.git
synced 2025-12-31 21:56:41 +01:00
@ -6,7 +6,7 @@ metadata:
|
||||
spec:
|
||||
project: default
|
||||
source:
|
||||
repoURL: http://gitlab-webservice-default.gitlab.svc.cluster.local:8080/root/vvaas42.git
|
||||
repoURL: http://gitlab-webservice-default.default.svc.cluster.local:8181/root/iot.git
|
||||
targetRevision: HEAD
|
||||
path: '.'
|
||||
destination:
|
||||
|
||||
@ -8,7 +8,7 @@ if [ -z "$KUBECONFIG" ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# set -x
|
||||
set -x
|
||||
|
||||
### === Initial K3D Setup ===
|
||||
k3d cluster create inception-of-things
|
||||
@ -28,30 +28,12 @@ echo "> ArgoCD is starting (this takes around ~6 minutes)..."
|
||||
kubectl wait --namespace argocd \
|
||||
--for=condition=ready pod \
|
||||
--selector=app.kubernetes.io/name=argocd-server \
|
||||
--timeout=300s \
|
||||
1>/dev/null 2>/dev/null
|
||||
echo '> Starting watch...'
|
||||
sleep 5
|
||||
|
||||
# So we have a progress-ish indicator visual
|
||||
while true; do
|
||||
ready=$(kubectl get pods -n argocd --no-headers 2>/dev/null | grep -E "([0-9]+)/\1" | wc -l)
|
||||
total=$(kubectl get pods -n argocd --no-headers 2>/dev/null | wc -l)
|
||||
|
||||
clear
|
||||
kubectl get pods -n argocd
|
||||
|
||||
if [ "$ready" -eq "$total" ] && [ "$total" -gt 0 ]; then
|
||||
break
|
||||
fi
|
||||
|
||||
sleep 30
|
||||
done
|
||||
--timeout=300s
|
||||
|
||||
echo "ArgoCD is ready!"
|
||||
echo '> To setup port-forwarding, run:'
|
||||
echo '> kubectl port-forward -n argocd svc/argocd-server 8080:443'
|
||||
kubectl port-forward -n argocd svc/argocd-server 8080:443 1>/dev/null 2>/dev/null &
|
||||
#kubectl port-forward -n argocd svc/argocd-server 8080:443 1>/dev/null 2>/dev/null &
|
||||
|
||||
#TODO: The app will be imported via Gitlab, don't import it here
|
||||
# so we don't have 2 of the same deployment.
|
||||
@ -105,7 +87,8 @@ echo
|
||||
echo '> To setup port-forwarding, run:'
|
||||
echo '> kubectl port-forward -n gitlab svc/gitlab-webservice-default 8081:8181'
|
||||
|
||||
kubectl port-forward -n gitlab svc/gitlab-webservice-default 8081:8181 1>/dev/null 2>/dev/null &
|
||||
#kubectl port-forward -n gitlab svc/gitlab-webservice-default 8081:8181 1>/dev/null 2>/dev/null &
|
||||
|
||||
### === Setup /etc/hosts ===
|
||||
function add_host() {
|
||||
local ip=$1
|
||||
|
||||
Reference in New Issue
Block a user