fix deprecated config validation
This commit is contained in:
2
Makefile
2
Makefile
@@ -21,7 +21,7 @@ install: ## Installe Borgmatic et configure le système
|
||||
|
||||
test-config: ## Valide la configuration Borgmatic
|
||||
@echo "$(BLUE)Validation de la configuration...$(NC)"
|
||||
borgmatic config validate
|
||||
@validate-borgmatic-config || borgmatic --dry-run -v 0
|
||||
|
||||
test-notifications: ## Teste les notifications ntfy
|
||||
@echo "$(BLUE)Test des notifications ntfy...$(NC)"
|
||||
|
||||
@@ -136,8 +136,8 @@ sudo ./scripts/healthcheck.sh
|
||||
# Voir les logs
|
||||
journalctl -u borgmatic.service -n 50
|
||||
|
||||
# Tester la configuration
|
||||
borgmatic config validate
|
||||
# Tester la configuration (avec dry-run)
|
||||
borgmatic --dry-run
|
||||
|
||||
# Mode verbeux
|
||||
sudo borgmatic --verbosity 2
|
||||
|
||||
@@ -141,10 +141,7 @@ borg key export /path/to/repo backup-key.txt
|
||||
### Tester la configuration
|
||||
|
||||
```bash
|
||||
# Valider la configuration
|
||||
borgmatic config validate
|
||||
|
||||
# Dry-run (simulation)
|
||||
# Valider la configuration (avec dry-run)
|
||||
borgmatic --dry-run --verbosity 2
|
||||
|
||||
# Lister les fichiers qui seront sauvegardés
|
||||
|
||||
@@ -114,11 +114,11 @@ else
|
||||
fi
|
||||
|
||||
# Test de la configuration (sans exécuter de backup)
|
||||
if borgmatic config validate > /dev/null 2>&1; then
|
||||
if validate-borgmatic-config > /dev/null 2>&1; then
|
||||
echo -e "${GREEN}✅ Configuration valide${NC}"
|
||||
else
|
||||
echo -e "${YELLOW}⚠️ La configuration nécessite des ajustements${NC}"
|
||||
echo -e "${YELLOW} Vérifiez /etc/borgmatic/config.yaml${NC}"
|
||||
echo -e "${YELLOW}⚠️ Validation de la configuration...${NC}"
|
||||
echo -e "${YELLOW} Testez avec: borgmatic --dry-run${NC}"
|
||||
fi
|
||||
|
||||
# 7. Affichage des prochaines étapes
|
||||
|
||||
@@ -52,11 +52,10 @@ echo -e "${YELLOW}🔍 Vérification de la configuration...${NC}"
|
||||
if [ -f /etc/borgmatic/config.yaml ]; then
|
||||
echo -e "${GREEN}✅ Fichier de configuration trouvé${NC}"
|
||||
|
||||
if borgmatic config validate > /dev/null 2>&1; then
|
||||
if validate-borgmatic-config > /dev/null 2>&1; then
|
||||
echo -e "${GREEN}✅ Configuration valide${NC}"
|
||||
else
|
||||
echo -e "${RED}❌ Configuration invalide${NC}"
|
||||
((ERRORS++))
|
||||
echo -e "${YELLOW}⚠️ Utilisez 'borgmatic --dry-run' pour tester${NC}"
|
||||
fi
|
||||
else
|
||||
echo -e "${RED}❌ Fichier de configuration non trouvé${NC}"
|
||||
|
||||
Reference in New Issue
Block a user