docs: merge docs/project files into appropriate doc directories
Some checks failed
Cross-Node Transaction Testing / transaction-test (push) Successful in 3s
Deploy to Testnet / deploy-testnet (push) Successful in 1m6s
Documentation Validation / validate-docs (push) Failing after 9s
Documentation Validation / validate-policies-strict (push) Successful in 5s
Multi-Node Stress Testing / stress-test (push) Successful in 3s
Node Failover Simulation / failover-test (push) Failing after 4s

- Moved ai-economics/ to docs/ai-economics/
- Moved completion/ to docs/completion/
- Merged cli/ with docs/cli/
- Merged infrastructure/ with docs/infrastructure/
- Moved planning/ to docs/planning/
- Moved requirements/ to docs/requirements/
- Moved workspace/ to docs/development/workspace/
- Moved 1_files.md to docs/reference/REPOSITORY_STRUCTURE.md
- Moved 2_roadmap.md to docs/ROADMAP.md
- Moved 3_infrastructure.md to docs/infrastructure/INFRASTRUCTURE.md
- Moved SECURITY.md to docs/security/SECURITY.md
- Moved PROJECT_STRUCTURE.md to docs/archive/GPU_PROJECT_STRUCTURE.md
- Moved WORKING_SETUP.md to docs/guides/getting-started/WORKING_SETUP.md
- Moved E2E_TEST_CREATION_SUMMARY.md to docs/reports/E2E_TEST_CREATION_SUMMARY.md
- Moved SQLMODEL_METADATA_FIX_SUMMARY.md to docs/reports/SQLMODEL_METADATA_FIX_SUMMARY.md
- Moved GITHUB_PULL_SUMMARY.md to docs/reports/GITHUB_PULL_SUMMARY.md
- Moved GIFT_CERTIFICATE_newuser.md to docs/guides/getting-started/GIFT_CERTIFICATE.md
- Moved user_profile_newuser.md to docs/guides/getting-started/USER_PROFILE.md
- Moved aitbc.md to docs/infrastructure/NODE_AITBC.md
- Moved aitbc1.md to docs/infrastructure/NODE_AITBC1.md
- Updated project/README.md with new documentation locations
- Removed empty subdirectories from docs/project/
- Created docs/MERGE_PLAN.md for reference
This commit is contained in:
aitbc
2026-05-09 21:52:55 +02:00
parent 157048ea1f
commit a7fbf58462
28 changed files with 156 additions and 37 deletions

View File

@@ -0,0 +1,170 @@
# AITBC Workspace Strategy Guide
## 🎯 Current Workspace Usage
### In-Repo Workspaces (Current)
```
/opt/aitbc/
├── python-packages-workspace/ # Created inside repo
├── javascript-packages-workspace/ # Created inside repo
├── security-workspace/ # Created inside repo
└── compatibility-workspace/ # Created inside repo
```
## ✅ Benefits of Outside-Repo Workspaces
### 1. **Clean Repository**
- No workspace directories in git status
- Cleaner commits and PRs
- No .gitignore conflicts
### 2. **Better Isolation**
- Each workspace has isolated environment
- No cross-contamination between tests
- Easier cleanup and reset
### 3. **Resource Management**
- Workspaces can use different base directories
- Better disk space management
- Parallel test execution possible
### 4. **CI/CD Best Practices**
- Standard industry practice
- GitHub Actions, GitLab CI use this pattern
- Container-friendly approach
## 🚀 Recommended Workspace Structure
### Outside-Repo Strategy
```bash
# Base workspace directory
/var/lib/aitbc-workspaces/
├── python-packages/
├── javascript-packages/
├── security-tests/
├── integration-tests/
├── compatibility-tests/
└── temp/
```
### Alternative: /opt Structure
```bash
/opt/aitbc-workspaces/
├── python-packages/
├── javascript-packages/
├── security/
├── integration/
└── build-artifacts/
```
## 📝 Implementation Examples
### Current (Inside Repo)
```yaml
- name: Setup Python Workspace
run: |
cd /opt/aitbc
rm -rf python-packages-workspace
mkdir -p python-packages-workspace
cd python-packages-workspace
git clone http://10.0.3.107:3000/oib/aitbc.git repo
```
### Improved (Outside Repo)
```yaml
- name: Setup Python Workspace
run: |
# Use dedicated workspace directory
WORKSPACE_BASE="/var/lib/aitbc-workspaces/python-packages"
rm -rf "$WORKSPACE_BASE"
mkdir -p "$WORKSPACE_BASE"
cd "$WORKSPACE_BASE"
git clone http://10.0.3.107:3000/oib/aitbc.git repo
cd repo
```
### Even Better (With Cleanup)
```yaml
- name: Setup Workspace
run: |
# Clean workspace function
cleanup_workspace() {
local workspace="$1"
rm -rf "$workspace" 2>/dev/null || true
mkdir -p "$workspace"
}
# Setup different workspaces
cleanup_workspace "/var/lib/aitbc-workspaces/python"
cleanup_workspace "/var/lib/aitbc-workspaces/javascript"
cleanup_workspace "/var/lib/aitbc-workspaces/security"
```
## 🔧 Workspace Management Functions
### Reusable Setup Script
```bash
#!/bin/bash
# /opt/aitbc/scripts/setup-workspace.sh
setup_workspace() {
local workspace_type="$1"
local workspace_base="/var/lib/aitbc-workspaces"
local workspace_dir="$workspace_base/$workspace_type"
local repo_url="http://10.0.3.107:3000/oib/aitbc.git"
echo "=== Setting up $workspace_type workspace ==="
# Cleanup and create
rm -rf "$workspace_dir"
mkdir -p "$workspace_dir"
cd "$workspace_dir"
# Clone repository
git clone "$repo_url" repo
cd repo
echo "✅ $workspace_type workspace ready at $workspace_dir/repo"
}
# Usage examples
setup_workspace "python-packages"
setup_workspace "javascript-packages"
setup_workspace "security-tests"
```
## 📊 Comparison
| Aspect | Inside Repo | Outside Repo |
|--------|-------------|--------------|
| **Clean Git History** | ❌ Workspaces in status | ✅ Clean status |
| **Isolation** | ❌ Shared space | ✅ Isolated |
| **Cleanup** | ❌ Complex | ✅ Simple |
| **Parallel Tests** | ❌ Conflicts | ✅ Possible |
| **Disk Usage** | ❌ In repo size | ✅ Separate |
| **Industry Standard** | ❌ Non-standard | ✅ Standard |
## 🎯 Recommendation
**Switch to outside-repo workspaces for:**
1. **All CI/CD workflows**
2. **Package testing** (Python, JavaScript, Solidity)
3. **Security scanning**
4. **Integration testing**
5. **Build artifacts**
**Keep inside-repo only for:**
1. **Development scripts**
2. **Documentation**
3. **Configuration files**
## 🚀 Next Steps
1. Create `/var/lib/aitbc-workspaces/` directory
2. Update CI workflows to use outside-repo workspaces
3. Add workspace management scripts
4. Update .gitignore to exclude any workspace directories
5. Test with existing workflows
This will provide cleaner, more maintainable CI/CD pipelines!