Project

General

Profile

Anomalie #2112

Demander si on veut vraiment relancer gen_conteneurs

Added by Emmanuel GARETTE (2) over 11 years ago. Updated over 11 years ago.

Status:
Fermé
Priority:
Normal
Assigned To:
Category:
-
Start date:
09/26/2011
Due date:
% Done:

100%

Spent time:
Distribution:

Description

Lorsqu'on relance gen_conteneurs, l'ensemble des conteneurs sont arrêtés. Il serait bien de demander si on est sûr de vouloir relancer gen_conteneurs.

--- gen_conteneurs    2011-09-26 21:17:18.695856936 +0200
+++ /usr/bin/gen_conteneurs    2011-09-26 21:18:39.596553299 +0200
@@ -13,6 +13,7 @@
 from creole.config import network_containers_file, containers_file
 from creole.error import VirtError
 from pyeole.ansiprint import print_title, print_orange, print_red
+from pyeole.ihm import question_ouinon

 try:
     from creole import config
@@ -30,6 +31,8 @@

 network_containers = {}
 if isfile(network_containers_file):
+    if question_ouinon("L'ensemble vont être arrêté, voulez-vous continuer ?") == 'non':
+        sys.exit()
     execfile(network_containers_file, {}, network_containers)

 if network_containers.has_key('adresse_network_br0'):

Associated revisions

Revision ff5deef3 (diff)
Added by Daniel Dehennin over 11 years ago

Fix typo.

  • eole-conteneur/gen_conteneurs: Make a french sentence (Fixes: #2112).

History

#1 Updated by Daniel Dehennin over 11 years ago

  • Assigned To set to Daniel Dehennin
  • Target version set to Mises à jour 2.3 - 02 RC
  • % Done changed from 0 to 40

Signed-off-by: Daniel Dehennin <>

#2 Updated by Daniel Dehennin over 11 years ago

  • Status changed from Nouveau to Résolu
  • % Done changed from 40 to 100

#3 Updated by Joël Cuissinat over 11 years ago

Si un jour, on souhaite que le script soit lancé automatiquement, il faudra penser à ajouter une option qui ne pose pas la question ;)

#4 Updated by Daniel Dehennin over 11 years ago

Joël Cuissinat a écrit :

Si un jour, on souhaite que le script soit lancé automatiquement, il faudra penser à ajouter une option qui ne pose pas la question ;)

Il faudrait peut-être :
  • modifier pyeole.question_ouinon pour un mode sans interaction ;
  • modifier gen_conteneurs pour inclure un argument définissant la valeur par défaut à pyeole.question_ouinon.

Non ?

#5 Updated by Joël Cuissinat over 11 years ago

  • Status changed from Résolu to Fermé
root@amonecoleng:~# gen_conteneurs
L'ensemble des conteneurs va être arrêté, voulez-vous continuer ? [oui/non]
[non] :

Also available in: Atom PDF