Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -40,5 +40,3 @@ yarn-error.log*
# Misc
.DS_Store
*.pem

/db/data
12 changes: 0 additions & 12 deletions db.compose.yml

This file was deleted.

Empty file removed db/.gitinclude
Empty file.
76 changes: 61 additions & 15 deletions forward-local-net.sh
Original file line number Diff line number Diff line change
@@ -1,29 +1,75 @@
#!/bin/bash

# Find Minikube IP
MINIKUBE_IP=$(minikube ip)
set -euo pipefail

# Find all NodePort services with their ports
echo "[INFO] Fetching all NodePort services..."
echo "[INFO] Getting NodePort services..."
NODEPORTS=$(kubectl get svc --all-namespaces \
-o jsonpath='{range .items[?(@.spec.type=="NodePort")]}{.metadata.namespace} {.metadata.name} {.spec.ports[*].nodePort}{"\n"}{end}')
-o jsonpath='{range .items[?(@.spec.type=="NodePort")]}{.metadata.namespace}{" "}{.metadata.name}{" "}{.spec.ports[*].nodePort}{"\n"}{end}')

if [[ -z "$NODEPORTS" ]]; then
echo "[INFO] No NodePort services found."
exit 0
fi

echo ""
echo "[INFO] Found NodePort services:"
echo "$NODEPORTS"
echo ""

echo "$NODEPORTS" | while IFS= read -r line; do
[[ -z "$line" ]] && continue

# Loop through services and ports
while read -r line; do
NAMESPACE=$(echo "$line" | awk '{print $1}')
NAME=$(echo "$line" | awk '{print $2}')
PORTS=$(echo "$line" | cut -d' ' -f3-)

echo "────────────────────────────────────────────"
echo "[SERVICE] $NAMESPACE/$NAME (NodePort(s): $PORTS)"

for PORT in $PORTS; do
echo "[FORWARDING] $NAMESPACE/$NAME on port $PORT"
echo "[INFO] Starting tunnel for $NAME (NodePort: $PORT)..."

# Launch minikube tunnel in background and capture output
TMPFILE=$(mktemp)
(minikube service "$NAME" -n "$NAMESPACE" --url >"$TMPFILE") &
TUNNEL_PID=$!

echo "[INFO] Waiting for tunnel to start..."
i=0
while ! grep -q "http://" "$TMPFILE"; do
sleep 0.2
i=$((i + 1))
if [[ $i -gt 50 ]]; then
echo " [ERROR] Timed out waiting for tunnel to start"
kill $TUNNEL_PID >/dev/null 2>&1 || true
rm -f "$TMPFILE"
continue 2
fi
done

# Check if socat already listening
if lsof -i TCP:$PORT >/dev/null; then
echo " [SKIP] Port $PORT already in use locally"
RAW_URL=$(cat "$TMPFILE")
TUNNELED_PORT=$(echo "$RAW_URL" | sed -E 's|.*:([0-9]+)$|\1|')

echo "[DEBUG] RAW_URL = '$RAW_URL'"
echo "[INFO] Minikube is forwarding to: $RAW_URL"
echo "[INFO] We will bind localhost:$PORT → localhost:$TUNNELED_PORT"

if lsof -iTCP:$PORT >/dev/null 2>&1; then
echo " [SKIP] Port $PORT already in use locally"
else
# Run socat in background
socat TCP4-LISTEN:$PORT,fork TCP4:$MINIKUBE_IP:$PORT &
echo " [OK] Forwarded port $PORT from Minikube to local"
echo "[INFO] Launching socat..."
nohup socat TCP4-LISTEN:$PORT,fork,reuseaddr TCP4:127.0.0.1:$TUNNELED_PORT \
>/tmp/socat-tunnel-$PORT.log 2>&1 &

SOCAT_PID=$!
echo "[OK] socat launched with PID $SOCAT_PID"
echo "[INFO] Log file: /tmp/socat-tunnel-$PORT.log"
fi

rm -f "$TMPFILE"
echo "[INFO] Leaving Minikube tunnel running in background (PID: $TUNNEL_PID)"
done
done <<<"$NODEPORTS"
done

echo ""
echo "[DONE] All NodePorts are now mapped to localhost properly."
10 changes: 0 additions & 10 deletions infrastructure/control-panel/biome.json

This file was deleted.

1 change: 0 additions & 1 deletion infrastructure/control-panel/project.inlang/.gitignore

This file was deleted.

1 change: 0 additions & 1 deletion infrastructure/eid-wallet/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@
"@tauri-apps/api": "^2",
"@tauri-apps/plugin-barcode-scanner": "^2.2.0",
"@tauri-apps/plugin-biometric": "^2.2.0",
"@tauri-apps/plugin-deep-link": "^2.4.1",
"@tauri-apps/plugin-opener": "^2",
"@tauri-apps/plugin-store": "^2.2.0",
"@veriff/incontext-sdk": "^2.4.0",
Expand Down
103 changes: 1 addition & 102 deletions infrastructure/eid-wallet/src-tauri/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion infrastructure/eid-wallet/src-tauri/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,4 @@ thiserror = { version = "2.0.11" }
tauri-plugin-barcode-scanner = "2"
tauri-plugin-biometric = "2.2.0"
tauri-plugin-crypto-hw = "0.1.0"
tauri-plugin-deep-link = { git = "https://github.com/sosweetham/plugins-workspace", rev = "0668697" }

11 changes: 0 additions & 11 deletions infrastructure/eid-wallet/src-tauri/Info.ios.plist
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,5 @@
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>
<key>CFBundleURLTypes</key>
<array>
<dict>
<key>CFBundleURLName</key>
<string>foundation.metastate.eid-wallet</string>
<key>CFBundleURLSchemes</key>
<array>
<string>w3ds</string>
</array>
</dict>
</array>
</dict>
</plist>
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@
"opener:default",
"store:default",
"biometric:default",
"barcode-scanner:default",
"deep-link:default"
"barcode-scanner:default"
],
"platforms": ["iOS", "android"]
}

This file was deleted.

Loading
Loading