mirror of
https://github.com/MacRimi/ProxMenux.git
synced 2025-06-28 04:06:54 +00:00
Update configure_igpu.sh
This commit is contained in:
parent
80e18586ed
commit
f018313eb7
@ -54,15 +54,23 @@ load_language() {
|
|||||||
# ==========================================================
|
# ==========================================================
|
||||||
|
|
||||||
|
|
||||||
# Validar que el contenedor seleccionado es válido
|
# Validate that the selected container is valid
|
||||||
validate_container_id() {
|
validate_container_id() {
|
||||||
if [ -z "$CONTAINER_ID" ]; then
|
if [ -z "$CONTAINER_ID" ]; then
|
||||||
msg_error "ID del contenedor no definido. Asegúrate de seleccionar un contenedor primero."
|
msg_error "$(translate 'Container ID not defined. Make sure to select a container first.')"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Check if the container is running and stop it before configuration
|
||||||
|
if pct status "$CONTAINER_ID" | grep -q "running"; then
|
||||||
|
msg_info "$(translate 'Stopping the container before applying configuration...')"
|
||||||
|
pct stop "$CONTAINER_ID"
|
||||||
|
msg_ok "$(translate 'Container stopped.')"
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Select LXC container
|
# Select LXC container
|
||||||
select_container() {
|
select_container() {
|
||||||
clear
|
clear
|
||||||
|
Loading…
x
Reference in New Issue
Block a user