From e5b11503282988ff09bd35a71d69de5719ff991e Mon Sep 17 00:00:00 2001 From: Pawan Pinjarkar Date: Wed, 17 Dec 2025 15:28:18 -0500 Subject: [PATCH 1/2] AGENT-1309: Modify OVE storage requirements --- .../bin/configure-assisted-hw-requirements.sh | 15 +++++++++++++++ .../assisted-service.env.template | 2 +- .../units/assisted-service.service.template | 8 +++++++- pkg/asset/agent/image/ignition_test.go | 1 + 4 files changed, 24 insertions(+), 2 deletions(-) create mode 100644 data/data/agent/files/usr/local/bin/configure-assisted-hw-requirements.sh diff --git a/data/data/agent/files/usr/local/bin/configure-assisted-hw-requirements.sh b/data/data/agent/files/usr/local/bin/configure-assisted-hw-requirements.sh new file mode 100644 index 00000000000..b81cc8ff5ac --- /dev/null +++ b/data/data/agent/files/usr/local/bin/configure-assisted-hw-requirements.sh @@ -0,0 +1,15 @@ +#!/bin/bash +set -e + +ASSISTED_SERVICE_ENV_FILE="/usr/local/share/assisted-service/assisted-service.env" +# default value +HW_VALIDATOR_REQUIREMENTS="[{\"version\":\"default\",\"master\":{\"cpu_cores\":4,\"ram_mib\":16384,\"disk_size_gb\":100,\"installation_disk_speed_threshold_ms\":10,\"network_latency_threshold_ms\":100,\"packet_loss_percentage\":0},\"arbiter\":{\"cpu_cores\":2,\"ram_mib\":8192,\"disk_size_gb\":50,\"installation_disk_speed_threshold_ms\":10,\"network_latency_threshold_ms\":1000,\"packet_loss_percentage\":0},\"worker\":{\"cpu_cores\":2,\"ram_mib\":8192,\"disk_size_gb\":100,\"installation_disk_speed_threshold_ms\":10,\"network_latency_threshold_ms\":1000,\"packet_loss_percentage\":10},\"sno\":{\"cpu_cores\":8,\"ram_mib\":16384,\"disk_size_gb\":100,\"installation_disk_speed_threshold_ms\":10}}]" + +# Increase disk size requirements for NoRegistryClusterInstall +if [ -f /etc/assisted/extra-manifests/internalreleaseimage.yaml ]; then + # shellcheck disable=SC2001 + HW_VALIDATOR_REQUIREMENTS=$(echo "$HW_VALIDATOR_REQUIREMENTS" |sed 's/"disk_size_gb":[0-9]\+/"disk_size_gb":220/g') +fi + +# Replace the final value in the env file +sed -i "s|^HW_VALIDATOR_REQUIREMENTS=.*|HW_VALIDATOR_REQUIREMENTS=$HW_VALIDATOR_REQUIREMENTS|" "$ASSISTED_SERVICE_ENV_FILE" \ No newline at end of file diff --git a/data/data/agent/files/usr/local/share/assisted-service/assisted-service.env.template b/data/data/agent/files/usr/local/share/assisted-service/assisted-service.env.template index 973c02cb8df..48cbb4624a2 100644 --- a/data/data/agent/files/usr/local/share/assisted-service/assisted-service.env.template +++ b/data/data/agent/files/usr/local/share/assisted-service/assisted-service.env.template @@ -9,7 +9,7 @@ DISK_ENCRYPTION_SUPPORT=true DUMMY_IGNITION=false ENABLE_SINGLE_NODE_DNSMASQ=true EPHEMERAL_INSTALLER_CLUSTER_TLS_CERTS_OVERRIDE_DIR=/opt/agent/tls -HW_VALIDATOR_REQUIREMENTS=[{"version":"default","master":{"cpu_cores":4,"ram_mib":16384,"disk_size_gb":100,"installation_disk_speed_threshold_ms":10,"network_latency_threshold_ms":100,"packet_loss_percentage":0},"arbiter":{"cpu_cores":2,"ram_mib":8192,"disk_size_gb":50,"installation_disk_speed_threshold_ms":10,"network_latency_threshold_ms":1000,"packet_loss_percentage":0},"worker":{"cpu_cores":2,"ram_mib":8192,"disk_size_gb":100,"installation_disk_speed_threshold_ms":10,"network_latency_threshold_ms":1000,"packet_loss_percentage":10},"sno":{"cpu_cores":8,"ram_mib":16384,"disk_size_gb":100,"installation_disk_speed_threshold_ms":10}}] +HW_VALIDATOR_REQUIREMENTS=TO_BE_REPLACED_BY_SYSTEMD INSTALL_INVOKER=agent-installer IPV6_SUPPORT=true TNA_CLUSTERS_SUPPORT=true diff --git a/data/data/agent/systemd/units/assisted-service.service.template b/data/data/agent/systemd/units/assisted-service.service.template index 66f6bc7c647..79fbac3acef 100644 --- a/data/data/agent/systemd/units/assisted-service.service.template +++ b/data/data/agent/systemd/units/assisted-service.service.template @@ -9,15 +9,21 @@ After=network-online.target assisted-service-pod.service [Service] Environment=PODMAN_SYSTEMD_UNIT=%n EnvironmentFile=/usr/local/share/assisted-service/agent-images.env + Restart=on-failure TimeoutStartSec=500 TimeoutStopSec=300 + ExecStartPre=/bin/rm -f %t/%n.ctr-id +ExecStartPre=/usr/local/bin/configure-assisted-hw-requirements.sh + ExecStart=/usr/bin/podman run --net host --cidfile=%t/%n.ctr-id --cgroups=no-conmon --log-driver=journald --rm --pod-id-file=%t/assisted-service-pod.pod-id --sdnotify=conmon --replace -d --name=service -v /opt/agent/tls:/opt/agent/tls:z {{ if .HaveMirrorConfig }}-v /etc/containers:/etc/containers{{ end }} {{.CaBundleMount}} --env-file=/etc/assisted/rendezvous-host.env --env-file=/usr/local/share/assisted-service/assisted-service.env --env-file=/usr/local/share/assisted-service/images.env --env-file=/etc/assisted/node0 --env-file=/usr/local/share/assisted-service/agent-images.env $SERVICE_IMAGE + ExecStop=/usr/bin/podman stop --ignore --cidfile=%t/%n.ctr-id ExecStopPost=/usr/bin/podman rm -f --ignore --cidfile=%t/%n.ctr-id + Type=notify NotifyAccess=all [Install] -WantedBy=multi-user.target +WantedBy=multi-user.target \ No newline at end of file diff --git a/pkg/asset/agent/image/ignition_test.go b/pkg/asset/agent/image/ignition_test.go index 50e5d3ce040..580b2efe12f 100644 --- a/pkg/asset/agent/image/ignition_test.go +++ b/pkg/asset/agent/image/ignition_test.go @@ -411,6 +411,7 @@ func commonFiles() []string { "/usr/local/bin/add-node.sh", "/usr/local/bin/agent-auth-token-status.sh", "/usr/local/bin/common.sh", + "/usr/local/bin/configure-assisted-hw-requirements.sh", } } From fc464bc1321a4aceb643e39814b24911a796d8a6 Mon Sep 17 00:00:00 2001 From: Pawan Pinjarkar Date: Mon, 19 Jan 2026 12:18:16 -0500 Subject: [PATCH 2/2] AGENT-1425: TUI does not show local web UI URL The agent-ui service was previously updated to 'Type=notify' to improve startup ordering and reliability. However, the lack of container monitor '--sdnotify=conmon' flag, resulted in UI URL to be not displayed on the TUI. Without this flag, agent-ui systemd waits for a readiness signal which never comes and the service remains in 'activating' state. This causes the TUI availability check to fail, making the user only see "Waiting for services" instead of UI URL ( even though the UI is already avaialble via the usual URL) This commit adds the missing flag, ensuring the notification handshake between the container running UI and the agent-ui systemd completes successfully and unblocking the TUI. This commit also fixes the stale dependency in agent-register-infraenv related to agent-ui systemd naming. --- .../systemd/units/agent-register-infraenv.service.template | 2 +- data/data/agent/systemd/units/agent-ui.service.template | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/data/data/agent/systemd/units/agent-register-infraenv.service.template b/data/data/agent/systemd/units/agent-register-infraenv.service.template index 027aff4a585..c24a8da8669 100644 --- a/data/data/agent/systemd/units/agent-register-infraenv.service.template +++ b/data/data/agent/systemd/units/agent-register-infraenv.service.template @@ -23,4 +23,4 @@ RestartSec=30 RemainAfterExit=true [Install] -WantedBy=start-cluster-installation.service agent-add-node.service agent-start-ui.service +WantedBy=start-cluster-installation.service agent-add-node.service agent-ui.service diff --git a/data/data/agent/systemd/units/agent-ui.service.template b/data/data/agent/systemd/units/agent-ui.service.template index 325418132c7..9e51ff14a70 100644 --- a/data/data/agent/systemd/units/agent-ui.service.template +++ b/data/data/agent/systemd/units/agent-ui.service.template @@ -13,7 +13,7 @@ EnvironmentFile=/etc/assisted/rendezvous-host.env Restart=on-failure ExecStartPre=/bin/rm -f %t/%n.ctr-id ExecStartPre=/usr/local/bin/wait-for-assisted-service.sh -ExecStart=/usr/bin/podman run --net host --cidfile=%t/%n.ctr-id --cgroups=no-conmon --log-driver=journald --rm --pod-id-file=%t/assisted-service-pod.pod-id --replace -d --name=agent-installer-ui --env AIUI_APP_API_URL $INSTALLER_UI_IMAGE +ExecStart=/usr/bin/podman run --sdnotify=conmon --net host --cidfile=%t/%n.ctr-id --cgroups=no-conmon --log-driver=journald --rm --pod-id-file=%t/assisted-service-pod.pod-id --replace -d --name=agent-installer-ui --env AIUI_APP_API_URL $INSTALLER_UI_IMAGE ExecStop=/usr/bin/podman stop --ignore --cidfile=%t/%n.ctr-id ExecStopPost=/usr/bin/podman rm -f --ignore --cidfile=%t/%n.ctr-id