Deployment scripts into installation directory#513
Merged
EnekoGonzalez3 merged 35 commits intodevelopfrom Feb 12, 2026
Merged
Conversation
…lve dependency issues.
…multiple modules. Streamlined target properties for better maintainability and enhanced include directories and link libraries for various executables and tests, ensuring proper encapsulation of dependencies.
…nolog library. This includes generating and installing configuration files for CMake and pkg-config, enhancing the library's usability and integration with other projects.
…nd pkg-config. This includes new CMakeLists and test executables to verify correct package discovery and linking functionality.
…ts to streamline test configuration.
…d add json-c requirement in pkg-config file. Solve tests to actually work.
…new dependency paths for improved package configuration and discovery tests.
…nd testing. Ensure required dependencies are found and provide clearer messages for uninstalled packages. Enhance test executables to utilize build tree when necessary.
…ript. This way the deploy functionalities are modularized like build and install and main script is simplified.
…olog client library. Updated test outputs to confirm successful linking in both CMake and pkg-config discovery scenarios.
…417-deployment-scripts-into-installation-directory
…417-deployment-scripts-into-installation-directory
…race from VISOR_BIN assignment
Resolved conflicts by prioritizing develop branch changes.
These files were incorrectly removed during the merge conflict resolution. They are required by ChronoStore/test/CMakeLists.txt.
Re-add the installation step for deploy_local.sh and deploy_cluster.sh that was removed during the develop merge. These scripts need to be installed to the tools directory.
- local_single_user_deploy.sh now delegates start/stop/clean to deploy_local.sh - single_user_deploy.sh now delegates start/stop/clean to deploy_cluster.sh - Both scripts retain build/install modes that require the source repo - Removes ~900 lines of duplicated code - Ensures consistency between repo scripts and installed scripts
The pgrep command returns exit code 1 when no processes match, which with set -e causes the script to exit. Adding '|| true' allows the script to continue when no ChronoLog processes are running, which is the expected case for the clean operation.
The stop and clean steps were not passing the -w flag to local_single_user_deploy.sh, causing them to default to $HOME/chronolog-install/chronolog (/root/chronolog-install/chronolog in the container) instead of the correct install path at /home/grc-iit/chronolog-install/chronolog.
stop_service and kill_service were using basename for pkill -f matching (e.g. "chrono_player"), which matched any process with that string in its command line — including the parent bash -c process in CI whose argument text contained the literal process names. This caused the stop step to SIGTERM itself (exit 143). Use the full binary path for pkill/pgrep -f so only actual daemon processes are matched.
Same issue as deploy_local.sh: pkill -ef was matching against basename
(e.g. "chrono_player") which could match the parent bash -c process in
CI. Changed parallel_remote_{stop,kill,check}_processes to accept and
use full binary paths instead of basenames for pkill/pgrep -f matching.
deploy_cluster.sh: The -e (verbose) short option was outside the -o string, causing getopt to treat it as the start of parameters. This made --long unrecognized, so no arguments were parsed and the script silently did nothing — root cause of distributed-deployment CI failure. single_user_deploy.sh: Added missing commas between the first 7 long option names (build-type:build-dir:... -> build-type:,build-dir:,...). Without commas getopt treats them as a single long option name.
In deploy_cluster.sh, `set -e` is enabled and `check_op_validity()` uses `((count++))` to count selected operations. When count is 0, the post-increment `((count++))` evaluates to 0 (falsy), returning exit code 1. Since it's the last command in a `&&` chain, `set -e` triggers and the script exits before ever calling start(). This caused the distributed deployment CI to silently fail with no processes launched. Fix by using `count=$((count + 1))` which is an assignment (always succeeds) instead of an arithmetic evaluation that can return non-zero. Also fix single_user_deploy.sh to propagate errors from delegated operations instead of always printing "Done" and exiting 0.
deploy_cluster.sh uses `set -e` but has 25 instances of
`[[ "${verbose}" == "true" ]] && echo "..."` for debug logging.
When verbose is false (the default), `[[ ]]` returns 1, `&&`
short-circuits, and the line returns 1. When this is the last
statement in a function, the function returns 1, and `set -e`
kills the script at the call site.
The second CI run showed this: check_op_validity now passes (first
fix worked), but check_recording_group_mapping returns 1 from its
verbose line, killing the start flow at prepare_hosts.
Fix all 25 verbose lines by appending `|| true` to ensure they
always return 0 regardless of the verbose flag.
Also fix parallel-ssh pkill calls (lines 514, 531) which return
non-zero when no matching process exists — would break stop/clean.
ibrodkin
approved these changes
Feb 11, 2026
fkengun
approved these changes
Feb 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.