fix: Restore all files lost during destructive rebase
A previous `git pull --rebase origin main` dropped 177 local commits,
losing 3400+ files across admin-v2, backend, studio-v2, website,
klausur-service, and many other services. The partial restore attempt
(660295e2) only recovered some files.
This commit restores all missing files from pre-rebase ref 98933f5e
while preserving post-rebase additions (night-scheduler, night-mode UI,
NightModeWidget dashboard integration).
Restored features include:
- AI Module Sidebar (FAB), OCR Labeling, OCR Compare
- GPU Dashboard, RAG Pipeline, Magic Help
- Klausur-Korrektur (8 files), Abitur-Archiv (5+ files)
- Companion, Zeugnisse-Crawler, Screen Flow
- Full backend, studio-v2, website, klausur-service
- All compliance SDKs, agent-core, voice-service
- CI/CD configs, documentation, scripts
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
32
dsms-node/Dockerfile
Normal file
32
dsms-node/Dockerfile
Normal file
@@ -0,0 +1,32 @@
|
||||
# DSMS Node - Dezentrales Daten Speicher System
|
||||
# Basiert auf IPFS für BreakPilot PWA
|
||||
|
||||
FROM ipfs/kubo:v0.24.0
|
||||
|
||||
LABEL maintainer="BreakPilot <dev@breakpilot.app>"
|
||||
LABEL description="DSMS Node for BreakPilot - Decentralized Storage System"
|
||||
|
||||
# Environment variables
|
||||
ENV IPFS_PATH=/data/ipfs
|
||||
ENV IPFS_PROFILE=server
|
||||
|
||||
# Expose ports
|
||||
# 4001 - Swarm (P2P)
|
||||
# 5001 - API
|
||||
# 8080 - Gateway
|
||||
EXPOSE 4001
|
||||
EXPOSE 5001
|
||||
EXPOSE 8080
|
||||
|
||||
# Copy initialization script with correct permissions for ipfs user
|
||||
USER root
|
||||
COPY init-dsms.sh /container-init.d/001-init-dsms.sh
|
||||
RUN chmod 755 /container-init.d/001-init-dsms.sh && chown 1000:users /container-init.d/001-init-dsms.sh
|
||||
USER ipfs
|
||||
|
||||
# Health check - use ipfs id which works for standalone node
|
||||
HEALTHCHECK --interval=30s --timeout=10s --start-period=60s --retries=3 \
|
||||
CMD ipfs id > /dev/null 2>&1 || exit 1
|
||||
|
||||
# Default command
|
||||
CMD ["daemon", "--migrate=true", "--enable-gc"]
|
||||
57
dsms-node/init-dsms.sh
Normal file
57
dsms-node/init-dsms.sh
Normal file
@@ -0,0 +1,57 @@
|
||||
#!/bin/sh
|
||||
# DSMS Node Initialization Script
|
||||
# Creates a private IPFS network for BreakPilot
|
||||
|
||||
set -e
|
||||
|
||||
echo "=== DSMS Node Initialization ==="
|
||||
|
||||
# Generate swarm key for private network if not exists
|
||||
if [ ! -f "$IPFS_PATH/swarm.key" ]; then
|
||||
echo "Generating private network swarm key..."
|
||||
|
||||
# Use predefined swarm key for BreakPilot private network
|
||||
# In production, this should be securely generated and shared between nodes
|
||||
cat > "$IPFS_PATH/swarm.key" << 'EOF'
|
||||
/key/swarm/psk/1.0.0/
|
||||
/base16/
|
||||
b3c7e8f4a9d2e1c5f8b7a6d4c3e2f1a0b9c8d7e6f5a4b3c2d1e0f9a8b7c6d5e4
|
||||
EOF
|
||||
|
||||
echo "Swarm key created for private network"
|
||||
fi
|
||||
|
||||
# Configure IPFS for private network
|
||||
echo "Configuring IPFS for DSMS private network..."
|
||||
|
||||
# Remove default bootstrap nodes (we want a private network)
|
||||
ipfs bootstrap rm --all 2>/dev/null || true
|
||||
|
||||
# Configure API to listen on all interfaces (for Docker)
|
||||
ipfs config Addresses.API /ip4/0.0.0.0/tcp/5001
|
||||
|
||||
# Configure Gateway
|
||||
ipfs config Addresses.Gateway /ip4/0.0.0.0/tcp/8080
|
||||
|
||||
# Enable CORS for BreakPilot
|
||||
ipfs config --json API.HTTPHeaders.Access-Control-Allow-Origin '["http://localhost:8000", "http://backend:8000", "*"]'
|
||||
ipfs config --json API.HTTPHeaders.Access-Control-Allow-Methods '["GET", "POST", "PUT", "DELETE"]'
|
||||
ipfs config --json API.HTTPHeaders.Access-Control-Allow-Headers '["Authorization", "Content-Type", "X-Requested-With"]'
|
||||
|
||||
# Configure for server profile (less aggressive DHT)
|
||||
ipfs config Routing.Type dht
|
||||
ipfs config --json Swarm.ConnMgr.LowWater 50
|
||||
ipfs config --json Swarm.ConnMgr.HighWater 200
|
||||
ipfs config --json Swarm.ConnMgr.GracePeriod '"60s"'
|
||||
|
||||
# Enable garbage collection
|
||||
ipfs config --json Datastore.GCPeriod '"1h"'
|
||||
ipfs config --json Datastore.StorageMax '"10GB"'
|
||||
|
||||
# Configure for BreakPilot metadata tagging
|
||||
ipfs config --json Experimental.FilestoreEnabled true
|
||||
|
||||
echo "=== DSMS Node Configuration Complete ==="
|
||||
echo "Private Network Key: $(cat $IPFS_PATH/swarm.key | tail -1 | head -c 16)..."
|
||||
echo "API: http://0.0.0.0:5001"
|
||||
echo "Gateway: http://0.0.0.0:8080"
|
||||
Reference in New Issue
Block a user