fix: финализация fix6 для production runtime и reconfigure

This commit is contained in:
2026-04-28 17:29:23 +05:00
parent 607689df9b
commit 087d9f616a
11 changed files with 34 additions and 85 deletions
+11 -1
View File
@@ -5,6 +5,7 @@ PACKAGE_DIR="$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)"
ORCHESTRATOR="$PACKAGE_DIR/orchestrator/hy2xs-orchestrator"
ORCHESTRATOR_INSTALL_PATH="/usr/local/lib/hy2xs/hy2xs-orchestrator"
ORCHESTRATOR_SYMLINK="/usr/local/bin/hy2xs-orchestrator"
RUNTIME_PACKAGE_DIR="/usr/local/lib/hy2xs/package"
log() {
printf '[hy2xs-install] %s\n' "$*"
@@ -27,6 +28,15 @@ install -d -m 0755 /usr/local/lib/hy2xs
install -m 0755 "$ORCHESTRATOR" "$ORCHESTRATOR_INSTALL_PATH"
ln -sf "$ORCHESTRATOR_INSTALL_PATH" "$ORCHESTRATOR_SYMLINK"
log "installing runtime package assets to: $RUNTIME_PACKAGE_DIR"
rm -rf "$RUNTIME_PACKAGE_DIR"
install -d -m 0755 "$RUNTIME_PACKAGE_DIR"
cp -a "$PACKAGE_DIR/config" "$RUNTIME_PACKAGE_DIR/"
cp -a "$PACKAGE_DIR/docs" "$RUNTIME_PACKAGE_DIR/"
cp -a "$PACKAGE_DIR/systemd" "$RUNTIME_PACKAGE_DIR/"
cp -a "$PACKAGE_DIR/templates" "$RUNTIME_PACKAGE_DIR/"
cp -a "$PACKAGE_DIR/metadata" "$RUNTIME_PACKAGE_DIR/"
log "package directory: $PACKAGE_DIR"
log "starting install-only orchestrator"
exec "$ORCHESTRATOR_INSTALL_PATH" install --package-dir "$PACKAGE_DIR" "$@"
exec "$ORCHESTRATOR_INSTALL_PATH" install --package-dir "$RUNTIME_PACKAGE_DIR" "$@"