feat: Add onboarding scripts and documentation for OpenClaw
- Created install_packages.sh to automate package installation in Ubuntu VM. - Developed onboarding_simulation.sh for executing onboarding scripts and displaying guides. - Added openclaw_check.sh to run OpenClaw doctor and help commands. - Implemented scan_secrets.sh for scanning sensitive patterns in the VM. - Introduced onboarding README.md and examples.md for contributor guidance. - Created guide_contributeur.md and guide_vm_sandbox.md for detailed onboarding instructions. - Added supports_visuels.md with diagrams and video tutorials for better understanding. - Developed test_openclaw_actions.py for automated testing of OpenClaw actions. - Created vm_test_report.md template for documenting VM test results. - Added setup_python_secure.sh for secure Python environment setup. - Implemented test_openclaw_sanitizer.py for testing sanitization functionality.
This commit is contained in:
@@ -0,0 +1,45 @@
|
||||
#!/bin/bash
|
||||
# Script de setup sécurisé pour Python dans le repo Kill_LIFE
|
||||
# Crée un environnement virtuel, installe les dépendances, audite la sécurité
|
||||
|
||||
set -e
|
||||
|
||||
# 1. Création de l'environnement virtuel
|
||||
if [ ! -d ".venv" ]; then
|
||||
echo "Création de l'environnement virtuel (.venv)..."
|
||||
python3 -m venv .venv
|
||||
else
|
||||
echo "Environnement virtuel déjà présent."
|
||||
fi
|
||||
|
||||
# 2. Activation de l'environnement
|
||||
source .venv/bin/activate
|
||||
|
||||
# 3. Mise à jour des outils de base
|
||||
pip install --upgrade pip setuptools wheel
|
||||
|
||||
# 4. Installation des dépendances
|
||||
if [ -f requirements-mistral.txt ]; then
|
||||
pip install -r requirements-mistral.txt
|
||||
fi
|
||||
if [ -f requirements.txt ]; then
|
||||
pip install -r requirements.txt
|
||||
fi
|
||||
|
||||
# 5. Audit de sécurité
|
||||
if ! pip show pip-audit > /dev/null 2>&1; then
|
||||
pip install pip-audit
|
||||
fi
|
||||
pip-audit || echo "Avertissement : pip-audit a détecté des vulnérabilités."
|
||||
|
||||
# 6. Conseils supplémentaires
|
||||
cat <<EOF
|
||||
|
||||
Conseils sécurité :
|
||||
- Ne versionnez pas .venv ni vos secrets.
|
||||
- Ajoutez .venv à .gitignore.
|
||||
- Mettez à jour vos dépendances régulièrement.
|
||||
- Utilisez pip-audit pour vérifier les vulnérabilités.
|
||||
EOF
|
||||
|
||||
# 7. Fin
|
||||
Reference in New Issue
Block a user