Name the overlapping mount paths and fix new OCI review translations

This commit is contained in:
MacRimi
2026-10-18 11:49:48 +02:00
parent 2aa6e0ba44
commit 9861a85ccd
5 changed files with 30 additions and 16 deletions
+4 -4
View File
@@ -2991,7 +2991,7 @@
"Inaccessible device during VM startup": "Périphérique inaccessible lors du démarrage de la VM", "Inaccessible device during VM startup": "Périphérique inaccessible lors du démarrage de la VM",
"Inactive": "Inactif", "Inactive": "Inactif",
"Inactive (entry in fstab, not currently mounted)": "Inactif (entrée dans fstab, non monté actuellement)", "Inactive (entry in fstab, not currently mounted)": "Inactif (entrée dans fstab, non monté actuellement)",
"Include these changes in oci-compose?": "inclure ces modifications dans oci-compose ?", "Include these changes in oci-compose?": "Inclure ces modifications dans oci-compose ?",
"Include these resources in oci-compose?": "inclure ces ressources dans oci-compose ?", "Include these resources in oci-compose?": "inclure ces ressources dans oci-compose ?",
"Includes /etc/network (may drop SSH immediately)": "Inclut /etc/network (peut supprimer SSH immédiatement)", "Includes /etc/network (may drop SSH immediately)": "Inclut /etc/network (peut supprimer SSH immédiatement)",
"Includes /etc/zfs": "Inclut /etc/zfs", "Includes /etc/zfs": "Inclut /etc/zfs",
@@ -6817,7 +6817,7 @@
"These values are asked during the installation:": "Ces valeurs sont demandées lors de l'installation:", "These values are asked during the installation:": "Ces valeurs sont demandées lors de l'installation:",
"They are described in the image documentation:": "Ils sont décrits dans la documentation de l'image :", "They are described in the image documentation:": "Ils sont décrits dans la documentation de l'image :",
"They will be added to oci-compose before continuing. Unsupported or changed resources are not imported.": "Ils seront ajoutés à oci-compose avant de continuer. Les ressources non prises en charge ou modifiées ne sont pas importées.", "They will be added to oci-compose before continuing. Unsupported or changed resources are not imported.": "Ils seront ajoutés à oci-compose avant de continuer. Les ressources non prises en charge ou modifiées ne sont pas importées.",
"They will be saved in oci-compose before continuing.": "Ils seront enregistrés dans oci-compose avant de continuer.", "They will be saved in oci-compose before continuing.": "Elles seront enregistrées dans oci-compose avant de continuer.",
"This CIFS share is mounted with restrictive permissions.": "Ce partage CIFS est monté avec des autorisations restrictives.", "This CIFS share is mounted with restrictive permissions.": "Ce partage CIFS est monté avec des autorisations restrictives.",
"This GPU is considered incompatible with GPU passthrough to a VM in ProxMenux.": "Ce GPU est considéré comme incompatible avec le relais GPU vers une VM dans ProxMenux.", "This GPU is considered incompatible with GPU passthrough to a VM in ProxMenux.": "Ce GPU est considéré comme incompatible avec le relais GPU vers une VM dans ProxMenux.",
"This NFS share is fully restricted — even the host root cannot write to it.": "Ce partage NFS est entièrement restreint : même la racine de l'hôte ne peut pas y écrire.", "This NFS share is fully restricted — even the host root cannot write to it.": "Ce partage NFS est entièrement restreint : même la racine de l'hôte ne peut pas y écrire.",
@@ -7672,7 +7672,7 @@
"active VF(s)": "FV active(s)", "active VF(s)": "FV active(s)",
"active VFs": "VF actives", "active VFs": "VF actives",
"active Virtual Functions. Changing its driver binding would destroy every VF.": "Fonctions virtuelles actives. Changer la liaison de son pilote détruirait chaque VF.", "active Virtual Functions. Changing its driver binding would destroy every VF.": "Fonctions virtuelles actives. Changer la liaison de son pilote détruirait chaque VF.",
"added in Proxmox": "ajouté dans Proxmox", "added in Proxmox": "ajoutée dans Proxmox",
"after copy; source tree is incomplete.": "après copie ; l'arborescence des sources est incomplète.", "after copy; source tree is incomplete.": "après copie ; l'arborescence des sources est incomplète.",
"after update.": "après mise à jour.", "after update.": "après mise à jour.",
"all guests": "tous les invités", "all guests": "tous les invités",
@@ -8040,7 +8040,7 @@
"remapped users": "utilisateurs remappés", "remapped users": "utilisateurs remappés",
"remove the (now-empty) directory if possible": "supprimez le répertoire (maintenant vide) si possible", "remove the (now-empty) directory if possible": "supprimez le répertoire (maintenant vide) si possible",
"removed from Proxmox": "supprimé de Proxmox", "removed from Proxmox": "supprimé de Proxmox",
"removed in Proxmox": "supprimé dans Proxmox", "removed in Proxmox": "supprimée dans Proxmox",
"removed successfully from Proxmox.": "supprimé avec succès de Proxmox.", "removed successfully from Proxmox.": "supprimé avec succès de Proxmox.",
"requires running the official installer, which restarts the Monitor service.": "nécessite l'exécution du programme d'installation officiel, qui redémarre le service Monitor.", "requires running the official installer, which restarts the Monitor service.": "nécessite l'exécution du programme d'installation officiel, qui redémarre le service Monitor.",
"requires the package": "nécessite le paquet", "requires the package": "nécessite le paquet",
+5 -5
View File
@@ -2991,7 +2991,7 @@
"Inaccessible device during VM startup": "Dispositivo inaccessibile durante l'avvio della VM", "Inaccessible device during VM startup": "Dispositivo inaccessibile durante l'avvio della VM",
"Inactive": "Inattivo", "Inactive": "Inattivo",
"Inactive (entry in fstab, not currently mounted)": "Inattivo (presente in fstab, attualmente non montato)", "Inactive (entry in fstab, not currently mounted)": "Inattivo (presente in fstab, attualmente non montato)",
"Include these changes in oci-compose?": "includere queste modifiche in oci-compose?", "Include these changes in oci-compose?": "Includere queste modifiche in oci-compose?",
"Include these resources in oci-compose?": "Includere queste risorse in oci-compose?", "Include these resources in oci-compose?": "Includere queste risorse in oci-compose?",
"Includes /etc/network (may drop SSH immediately)": "Include /etc/network (potrebbe interrompere immediatamente la connessione SSH)", "Includes /etc/network (may drop SSH immediately)": "Include /etc/network (potrebbe interrompere immediatamente la connessione SSH)",
"Includes /etc/zfs": "Include /etc/zfs", "Includes /etc/zfs": "Include /etc/zfs",
@@ -6806,7 +6806,7 @@
"These Proxmox resources were added outside ProxMenux:": "Queste risorse Proxmox sono state aggiunte fuori da ProxMenux:", "These Proxmox resources were added outside ProxMenux:": "Queste risorse Proxmox sono state aggiunte fuori da ProxMenux:",
"These VMIDs are not free:": "Questi VMID non sono disponibili:", "These VMIDs are not free:": "Questi VMID non sono disponibili:",
"These are the changes that will be made": "Verranno apportate queste modifiche", "These are the changes that will be made": "Verranno apportate queste modifiche",
"These changes were made in Proxmox outside ProxMenux:": "queste modifiche sono state apportate in Proxmox all'esterno di ProxMenux:", "These changes were made in Proxmox outside ProxMenux:": "Queste modifiche sono state apportate in Proxmox al di fuori di ProxMenux:",
"These container mount paths have an extension-like suffix:": "Questi percorsi di mount del container hanno un suffisso simile a un'estensione:", "These container mount paths have an extension-like suffix:": "Questi percorsi di mount del container hanno un suffisso simile a un'estensione:",
"These containers were restored from a backup and this host has no record of their OCI application:": "Questi container sono stati ripristinati da un backup e questo host non ha il record della loro applicazione OCI:", "These containers were restored from a backup and this host has no record of their OCI application:": "Questi container sono stati ripristinati da un backup e questo host non ha il record della loro applicazione OCI:",
"These host backups run with this job and expect its storage:": "Questi backup dell’host vengono eseguiti con questo job e richiedono il suo storage:", "These host backups run with this job and expect its storage:": "Questi backup dell’host vengono eseguiti con questo job e richiedono il suo storage:",
@@ -6818,7 +6818,7 @@
"These values are asked during the installation:": "Questi valori verranno richiesti durante l’installazione:", "These values are asked during the installation:": "Questi valori verranno richiesti durante l’installazione:",
"They are described in the image documentation:": "Sono descritti nella documentazione dell'immagine:", "They are described in the image documentation:": "Sono descritti nella documentazione dell'immagine:",
"They will be added to oci-compose before continuing. Unsupported or changed resources are not imported.": "Se confermi e la verifica finale riesce, queste risorse verranno registrate in oci-compose prima di proseguire. Le risorse non supportate o modificate non vengono acquisite.", "They will be added to oci-compose before continuing. Unsupported or changed resources are not imported.": "Se confermi e la verifica finale riesce, queste risorse verranno registrate in oci-compose prima di proseguire. Le risorse non supportate o modificate non vengono acquisite.",
"They will be saved in oci-compose before continuing.": "verranno salvati in oci-compose prima di continuare.", "They will be saved in oci-compose before continuing.": "Verranno salvate in oci-compose prima di continuare.",
"This CIFS share is mounted with restrictive permissions.": "Questa condivisione CIFS è montata con autorizzazioni restrittive.", "This CIFS share is mounted with restrictive permissions.": "Questa condivisione CIFS è montata con autorizzazioni restrittive.",
"This GPU is considered incompatible with GPU passthrough to a VM in ProxMenux.": "Questa GPU è considerata incompatibile con il passthrough GPU a una VM in ProxMenux.", "This GPU is considered incompatible with GPU passthrough to a VM in ProxMenux.": "Questa GPU è considerata incompatibile con il passthrough GPU a una VM in ProxMenux.",
"This NFS share is fully restricted — even the host root cannot write to it.": "Questa condivisione NFS è completamente limitata: nemmeno l'utente root dell'host può scrivervi.", "This NFS share is fully restricted — even the host root cannot write to it.": "Questa condivisione NFS è completamente limitata: nemmeno l'utente root dell'host può scrivervi.",
@@ -7673,7 +7673,7 @@
"active VF(s)": "VF attive", "active VF(s)": "VF attive",
"active VFs": "VF attive", "active VFs": "VF attive",
"active Virtual Functions. Changing its driver binding would destroy every VF.": "funzioni virtuali attive. La modifica del collegamento del driver distruggerebbe ogni VF.", "active Virtual Functions. Changing its driver binding would destroy every VF.": "funzioni virtuali attive. La modifica del collegamento del driver distruggerebbe ogni VF.",
"added in Proxmox": "aggiunto in Proxmox", "added in Proxmox": "aggiunta in Proxmox",
"after copy; source tree is incomplete.": "dopo la copia; l'albero dei sorgenti è incompleto.", "after copy; source tree is incomplete.": "dopo la copia; l'albero dei sorgenti è incompleto.",
"after update.": "dopo l'aggiornamento.", "after update.": "dopo l'aggiornamento.",
"all guests": "tutti i guest", "all guests": "tutti i guest",
@@ -8041,7 +8041,7 @@
"remapped users": "utenti rimappati", "remapped users": "utenti rimappati",
"remove the (now-empty) directory if possible": "rimuovere la directory (ora vuota) se possibile", "remove the (now-empty) directory if possible": "rimuovere la directory (ora vuota) se possibile",
"removed from Proxmox": "rimosso da Proxmox", "removed from Proxmox": "rimosso da Proxmox",
"removed in Proxmox": "rimosso in Proxmox", "removed in Proxmox": "rimossa in Proxmox",
"removed successfully from Proxmox.": "rimosso con successo da Proxmox.", "removed successfully from Proxmox.": "rimosso con successo da Proxmox.",
"requires running the official installer, which restarts the Monitor service.": "richiede l'esecuzione del programma di installazione ufficiale, che riavvia il servizio Monitor.", "requires running the official installer, which restarts the Monitor service.": "richiede l'esecuzione del programma di installazione ufficiale, che riavvia il servizio Monitor.",
"requires the package": "richiede il pacchetto", "requires the package": "richiede il pacchetto",
+4 -4
View File
@@ -6818,7 +6818,7 @@
"These values are asked during the installation:": "Estes valores são questionados durante a instalação:", "These values are asked during the installation:": "Estes valores são questionados durante a instalação:",
"They are described in the image documentation:": "Estão descritos na documentação da imagem:", "They are described in the image documentation:": "Estão descritos na documentação da imagem:",
"They will be added to oci-compose before continuing. Unsupported or changed resources are not imported.": "Eles serão adicionados ao oci-compose antes de continuar. Recursos não suportados ou alterados não são importados.", "They will be added to oci-compose before continuing. Unsupported or changed resources are not imported.": "Eles serão adicionados ao oci-compose antes de continuar. Recursos não suportados ou alterados não são importados.",
"They will be saved in oci-compose before continuing.": "Eles serão salvos em oci-compose antes de continuar.", "They will be saved in oci-compose before continuing.": "Elas serão salvas no oci-compose antes de continuar.",
"This CIFS share is mounted with restrictive permissions.": "Este compartilhamento CIFS é montado com permissões restritivas.", "This CIFS share is mounted with restrictive permissions.": "Este compartilhamento CIFS é montado com permissões restritivas.",
"This GPU is considered incompatible with GPU passthrough to a VM in ProxMenux.": "Esta GPU é considerada incompatível com a passagem de GPU para uma VM no ProxMenux.", "This GPU is considered incompatible with GPU passthrough to a VM in ProxMenux.": "Esta GPU é considerada incompatível com a passagem de GPU para uma VM no ProxMenux.",
"This NFS share is fully restricted — even the host root cannot write to it.": "Este compartilhamento NFS é totalmente restrito — até mesmo o host root não pode gravar nele.", "This NFS share is fully restricted — even the host root cannot write to it.": "Este compartilhamento NFS é totalmente restrito — até mesmo o host root não pode gravar nele.",
@@ -7673,7 +7673,7 @@
"active VF(s)": "FV ativa(s)", "active VF(s)": "FV ativa(s)",
"active VFs": "FVs ativas", "active VFs": "FVs ativas",
"active Virtual Functions. Changing its driver binding would destroy every VF.": "Funções virtuais ativas. Alterar a ligação do driver destruiria todos os VF.", "active Virtual Functions. Changing its driver binding would destroy every VF.": "Funções virtuais ativas. Alterar a ligação do driver destruiria todos os VF.",
"added in Proxmox": "adicionado em Proxmox", "added in Proxmox": "adicionada no Proxmox",
"after copy; source tree is incomplete.": "após cópia; a árvore de origem está incompleta.", "after copy; source tree is incomplete.": "após cópia; a árvore de origem está incompleta.",
"after update.": "após a atualização.", "after update.": "após a atualização.",
"all guests": "todos os convidados", "all guests": "todos os convidados",
@@ -8041,7 +8041,7 @@
"remapped users": "usuários remapeados", "remapped users": "usuários remapeados",
"remove the (now-empty) directory if possible": "remova o diretório (agora vazio), se possível", "remove the (now-empty) directory if possible": "remova o diretório (agora vazio), se possível",
"removed from Proxmox": "removido do Proxmox", "removed from Proxmox": "removido do Proxmox",
"removed in Proxmox": "removido em Proxmox", "removed in Proxmox": "removida no Proxmox",
"removed successfully from Proxmox.": "removido com sucesso do Proxmox.", "removed successfully from Proxmox.": "removido com sucesso do Proxmox.",
"requires running the official installer, which restarts the Monitor service.": "requer a execução do instalador oficial, que reinicia o serviço Monitor.", "requires running the official installer, which restarts the Monitor service.": "requer a execução do instalador oficial, que reinicia o serviço Monitor.",
"requires the package": "requer o pacote", "requires the package": "requer o pacote",
@@ -8145,7 +8145,7 @@
"using": "usando", "using": "usando",
"using direct path (not guaranteed to survive reboots).": "usando caminho direto (não é garantido que sobreviva às reinicializações).", "using direct path (not guaranteed to survive reboots).": "usando caminho direto (não é garantido que sobreviva às reinicializações).",
"vCPUs:": "vCPUs:", "vCPUs:": "vCPUs:",
"value changed in Proxmox": "valor alterado em Proxmox", "value changed in Proxmox": "valor alterado no Proxmox",
"vfio-pci IDs configured": "IDs vfio-pci configurados", "vfio-pci IDs configured": "IDs vfio-pci configurados",
"vfio-pci IDs in /etc/modprobe.d/vfio.conf": "IDs vfio-pci em /etc/modprobe.d/vfio.conf", "vfio-pci IDs in /etc/modprobe.d/vfio.conf": "IDs vfio-pci em /etc/modprobe.d/vfio.conf",
"video": "vídeo", "video": "vídeo",
+4 -3
View File
@@ -571,9 +571,10 @@ def preflight(record, candidate, config, coordinated=None, in_place=False, basel
target = host_mounts.valid_path(mount['container_path']) target = host_mounts.valid_path(mount['container_path'])
if mount['type'] == 'host-bind' and mount['source'] in declared and mount.get('read_only'): if mount['type'] == 'host-bind' and mount['source'] in declared and mount.get('read_only'):
continue continue
if (any(target == p or target.startswith(p.rstrip('/') + '/') other = next((p for p in paths if target == p or target.startswith(p.rstrip('/') + '/')
or p.startswith(target.rstrip('/') + '/') for p in paths)): or p.startswith(target.rstrip('/') + '/')), None)
raise ValueError(translate('Mount paths must not overlap')) if other:
raise ValueError(f"{translate('Mount paths must not overlap')}: {target} - {other}")
if mount['type'] == 'managed-volume': if mount['type'] == 'managed-volume':
if mount.get('backup') is not True or not isinstance(mount.get('size_gb'), int) or mount['size_gb'] < 1: if mount.get('backup') is not True or not isinstance(mount.get('size_gb'), int) or mount['size_gb'] < 1:
raise ValueError(translate('Managed disks must have backup enabled and a valid size')) raise ValueError(translate('Managed disks must have backup enabled and a valid size'))
+13
View File
@@ -1,4 +1,5 @@
"""Regression tests for explicit adoption of external OCI resources.""" """Regression tests for explicit adoption of external OCI resources."""
import copy
import json import json
from pathlib import Path from pathlib import Path
import sys import sys
@@ -216,5 +217,17 @@ class EnvironmentAdoptionTests(unittest.TestCase):
reconcile.propose(record, config) reconcile.propose(record, config)
class OverlapMessageTests(unittest.TestCase):
def test_the_refusal_names_both_paths(self):
from test_modify_review import installation
saved, config = installation()
candidate = copy.deepcopy(saved)
volume = {'type': 'managed-volume', 'source': 'local-lvm', 'size_gb': 1, 'backup': True, 'read_only': False}
candidate['deployment']['mounts'] = [dict(volume, container_path='/source'),
dict(volume, container_path='/source/archivos')]
with self.assertRaisesRegex(ValueError, '/source/archivos - /source$'):
reconcile.transaction.preflight(saved, candidate, config)
if __name__ == '__main__': if __name__ == '__main__':
unittest.main() unittest.main()