Compare commits

...

5 Commits

Author SHA1 Message Date
MickLesk 43c2766181 bump version to v3.0.1 and update plugin build process to avoid monorepo issues 2026-07-02 23:46:10 +02:00
MickLesk 4adb74e304 add MISE_EXPERIMENTAL=1 2026-07-02 23:19:39 +02:00
MickLesk 20ee92cc32 regenerate ml start.sh if missing 2026-07-02 23:17:08 +02:00
MickLesk b3cdbc1582 npm modules forcing
In setup_nodejs, all three global-module install/update branches now fall back to npm install -g --force when the normal install fails. --force is npm's own recommended resolution for this EEXIST
2026-07-02 23:10:48 +02:00
MickLesk 52168aac12 Handle mise monorepo_root rename for Immich
Updated both Immich setup scripts (`ct/immich.sh` and `install/immich-install.sh`) to patch `mise.toml` before running `mise //:plugins`. The change ensures `monorepo_root = true` is present while retaining `experimental_monorepo_root = true`, so plugin builds work across old and new mise versions after the v2026.7.0 key rename.
2026-07-02 23:06:42 +02:00
3 changed files with 43 additions and 7 deletions
+25 -2
View File
@@ -110,7 +110,7 @@ EOF
msg_ok "Image-processing libraries up to date"
fi
RELEASE="v3.0.0"
RELEASE="v3.0.1"
if check_for_gh_release "Immich" "immich-app/immich" "${RELEASE}" "each release is tested individually before the version is updated. Please do not open issues for this"; then
if [[ $(cat ~/.immich) > "2.5.1" ]]; then
msg_info "Enabling Maintenance Mode"
@@ -202,10 +202,16 @@ EOF
[[ -f "$INSTALL_DIR"/start.sh ]] && mv "$INSTALL_DIR"/start.sh "$APP_DIR"/bin
# plugins
# Build the plugin(s) directly instead of via the `mise //:plugins` monorepo task path,
# which repeatedly breaks across mise releases (experimental/monorepo_root setting churn).
# mise is used only to provide the build tools (extism-js, wasm-opt, etc.) via `mise install`
# and `mise exec`, both of which are stable and do not depend on the monorepo feature.
cd "$SRC_DIR"
export MISE_TRUSTED_CONFIG_PATHS="$SRC_DIR"/mise.toml
export MISE_DISABLE_TOOLS=github:jellyfin/jellyfin-ffmpeg
$STD mise //:plugins
$STD mise install
$STD mise exec -- pnpm --filter @immich/sdk --filter @immich/plugin-sdk --filter @immich/plugin-core install --frozen-lockfile
$STD mise exec -- pnpm --filter @immich/sdk --filter @immich/plugin-sdk --filter @immich/plugin-core build
mkdir -p "$PLUGIN_DIR"
cp -r ./packages/plugin-core/dist "$PLUGIN_DIR"/dist
cp ./packages/plugin-core/manifest.json "$PLUGIN_DIR"
@@ -253,6 +259,23 @@ EOF
cd "$SRC_DIR"
cp -a machine-learning/{ann,immich_ml} "$ML_DIR"
[[ -f "$INSTALL_DIR"/ml_start.sh ]] && mv "$INSTALL_DIR"/ml_start.sh "$ML_DIR"
# Regenerate ml_start.sh if it is missing (e.g. lost by a previously interrupted update),
# otherwise immich-ml.service fails to start with status=203/EXEC
if [[ ! -f "$ML_DIR"/ml_start.sh ]]; then
cat <<EOF >"$ML_DIR"/ml_start.sh
#!/usr/bin/env bash
cd ${ML_DIR}
. ${VIRTUAL_ENV}/bin/activate
set -a
. ${INSTALL_DIR}/.env
set +a
python3 -m immich_ml
EOF
chmod +x "$ML_DIR"/ml_start.sh
fi
[[ -f ~/.openvino ]] && sed -i "/intra_op/s/int = 0/int = os.cpu_count() or 0/" "$ML_DIR"/immich_ml/config.py
ln -sf "$APP_DIR"/resources "$INSTALL_DIR"
cd "$APP_DIR"
+8 -2
View File
@@ -311,7 +311,7 @@ ML_DIR="${APP_DIR}/machine-learning"
GEO_DIR="${INSTALL_DIR}/geodata"
mkdir -p {"${APP_DIR}","${UPLOAD_DIR}","${GEO_DIR}","${INSTALL_DIR}"/cache}
fetch_and_deploy_gh_release "Immich" "immich-app/immich" "tarball" "v3.0.0" "$SRC_DIR"
fetch_and_deploy_gh_release "Immich" "immich-app/immich" "tarball" "v3.0.1" "$SRC_DIR"
PNPM_VERSION="$(jq -r '.packageManager | split("@")[1] | split("+")[0]' ${SRC_DIR}/package.json)"
NODE_VERSION="24" NODE_MODULE="corepack,pnpm@${PNPM_VERSION}" setup_nodejs
@@ -347,10 +347,16 @@ cp -a web/build "$APP_DIR"/www
cp LICENSE "$APP_DIR"
# plugins
# Build the plugin(s) directly instead of via the `mise //:plugins` monorepo task path,
# which repeatedly breaks across mise releases (experimental/monorepo_root setting churn).
# mise is used only to provide the build tools (extism-js, wasm-opt, etc.) via `mise install`
# and `mise exec`, both of which are stable and do not depend on the monorepo feature.
cd "$SRC_DIR"
export MISE_TRUSTED_CONFIG_PATHS="$SRC_DIR"/mise.toml
export MISE_DISABLE_TOOLS=github:jellyfin/jellyfin-ffmpeg
$STD mise //:plugins
$STD mise install
$STD mise exec -- pnpm --filter @immich/sdk --filter @immich/plugin-sdk --filter @immich/plugin-core install --frozen-lockfile
$STD mise exec -- pnpm --filter @immich/sdk --filter @immich/plugin-sdk --filter @immich/plugin-core build
mkdir -p "$PLUGIN_DIR"
cp -r ./packages/plugin-core/dist "$PLUGIN_DIR"/dist
cp ./packages/plugin-core/manifest.json "$PLUGIN_DIR"
+10 -3
View File
@@ -7627,7 +7627,10 @@ setup_nodejs() {
MODULE_INSTALLED_VERSION="$(npm list -g --depth=0 "$MODULE_NAME" 2>&1 | grep "$MODULE_NAME@" | awk -F@ '{print $2}' 2>/dev/null | tr -d '[:space:]' || echo '')"
if [[ "$MODULE_REQ_VERSION" != "latest" && "$MODULE_REQ_VERSION" != "$MODULE_INSTALLED_VERSION" ]]; then
msg_info "Updating $MODULE_NAME to v$MODULE_REQ_VERSION"
if $STD npm install -g "${MODULE_NAME}@${MODULE_REQ_VERSION}" 2>/dev/null; then
# Retry with --force to overwrite corepack-provided shims (pnpm/yarn), which now
# ship with recent corepack and cause EEXIST on /usr/bin/<tool>
if $STD npm install -g "${MODULE_NAME}@${MODULE_REQ_VERSION}" 2>/dev/null ||
$STD npm install -g --force "${MODULE_NAME}@${MODULE_REQ_VERSION}" 2>/dev/null; then
msg_ok "Updated $MODULE_NAME"
else
msg_warn "Failed to update $MODULE_NAME to version $MODULE_REQ_VERSION"
@@ -7635,7 +7638,8 @@ setup_nodejs() {
fi
elif [[ "$MODULE_REQ_VERSION" == "latest" ]]; then
msg_info "Updating $MODULE_NAME to latest version"
if $STD npm install -g "${MODULE_NAME}@latest" 2>/dev/null; then
if $STD npm install -g "${MODULE_NAME}@latest" 2>/dev/null ||
$STD npm install -g --force "${MODULE_NAME}@latest" 2>/dev/null; then
msg_ok "Updated $MODULE_NAME"
else
msg_warn "Failed to update $MODULE_NAME to latest version"
@@ -7644,7 +7648,10 @@ setup_nodejs() {
fi
else
msg_info "Installing $MODULE_NAME@$MODULE_REQ_VERSION"
if $STD npm install -g "${MODULE_NAME}@${MODULE_REQ_VERSION}" 2>/dev/null; then
# Retry with --force to overwrite corepack-provided shims (pnpm/yarn), which now
# ship with recent corepack and cause EEXIST on /usr/bin/<tool>
if $STD npm install -g "${MODULE_NAME}@${MODULE_REQ_VERSION}" 2>/dev/null ||
$STD npm install -g --force "${MODULE_NAME}@${MODULE_REQ_VERSION}" 2>/dev/null; then
msg_ok "Installed $MODULE_NAME"
else
msg_warn "Failed to install $MODULE_NAME@$MODULE_REQ_VERSION"