refs #2506 -- More parameter rearranging

modificar-imagen-branch
Vadim Trochinsky 2025-08-04 11:26:34 +02:00
parent a56065b842
commit 1e8680ff08
1 changed files with 19 additions and 19 deletions

View File

@ -361,7 +361,7 @@ class ogAdmClientWorker (ogLiveWorker):
return self.respuestaEjecucionComando (cmd, herror, ids)
def do_CrearImagenGit (self, post_params):
for k in ['nfn', 'ids', 'disk', 'partition', 'repo']:
for k in ['nfn', 'ids', 'disk', 'partition', 'repository']:
if k not in post_params:
logger.error (f'required parameter ({k}) not in POST params')
return {}
@ -369,10 +369,10 @@ class ogAdmClientWorker (ogLiveWorker):
nfn = post_params['nfn']
ids = post_params['ids']
disk = post_params['disk'] ## Numero de disco
partition = post_params['partition'] ## Numero de partición
repo = post_params['gitrepo'] ## URL a repositorio
disk = post_params['disk'] ## Numero de disco
partition = post_params['partition'] ## Numero de partición
repo = post_params['repository'] ## URL a repositorio
msg = post_params['message'] ## Mensaje de commit (opcional)
self.muestraMensaje (7)
@ -411,7 +411,7 @@ class ogAdmClientWorker (ogLiveWorker):
def do_ModificarImagenGit (self, post_params):
for k in ['nfn', 'ids', 'disk', 'partition', 'repo', 'branch', 'options', 'msg']:
for k in ['nfn', 'ids', 'disk', 'partition', 'repository', 'branch', 'options', 'message']:
if k not in post_params:
logger.error (f'required parameter ({k}) not in POST params')
return {}
@ -419,14 +419,12 @@ class ogAdmClientWorker (ogLiveWorker):
nfn = post_params['nfn']
ids = post_params['ids']
disk = post_params['disk'] ## Disco
partition = post_params['partition'] ## Número de partición
repo = post_params['repo'] ## Ip del repositorio
branch = post_params['branch'] ## Rama nueva a crear
options = post_params['options'] ## Opciones (force push, etc)
msg = post_params['msg'] ## Commit message
msg = post_params['msg'] ## Mensaje de commit
disk = post_params['disk'] ## Disco
partition = post_params['partition'] ## Número de partición
repo = post_params['repository'] ## Ip del repositorio
branch = post_params['branch'] ## Rama nueva a crear
options = post_params['options'] ## Opciones (force push, etc)
msg = post_params['message'] ## Commit message
self.muestraMensaje (7)
@ -459,7 +457,8 @@ class ogAdmClientWorker (ogLiveWorker):
'disk' : disk, ## Número de disco
'partition' : partition, ## Número de partición de donde se creó
'repo' : repo, ## Ip del repositorio donde se alojó
'inv_sft': inv_sft
'branch' : branch, ## Rama creada
'inv_sft' : inv_sft
}
return self.respuestaEjecucionComando (cmd, herror, ids)
@ -511,7 +510,7 @@ class ogAdmClientWorker (ogLiveWorker):
return self.respuestaEjecucionComando (cmd, herror, ids)
def do_RestaurarImagenGit (self, post_params):
for k in ['nfn', 'ids', 'disk', 'partition', 'repo', 'commit']:
for k in ['nfn', 'ids', 'disk', 'partition', 'repository', 'commit']:
if k not in post_params:
logger.error (f'required parameter ({k}) not in POST params')
return {}
@ -521,9 +520,9 @@ class ogAdmClientWorker (ogLiveWorker):
disk = post_params['disk'] ## Numero de disco
partition = post_params['partition'] ## Numero de partición
repo = post_params['repo'] ## URL a repositorio
commit = post_params['commit'] ## Referencia de git a restaurar
branch = post_params['branch'] ## Referencia de git a restaurar, opcional
repo = post_params['repository'] ## URL a repositorio
branch = post_params['branch'] ## Rama de git seleccionada para restaurar
commit = post_params['commit'] ## Referencia de git a restaurar. Debe ser un commit dentro de la rama indicada.
self.muestraMensaje (3)
@ -550,6 +549,7 @@ class ogAdmClientWorker (ogLiveWorker):
'nfn': 'RESPUESTA_RestaurarImagenGit',
'disk' : disk, ## Número de disco
'partition': partition, ## Número de partición
'repo' : repo, ## Repositorio de git
'cfg': self.cfg2obj(cfg), ## Configuración de discos
}
return self.respuestaEjecucionComando (cmd, herror, ids)