diff --git a/scripts/install b/scripts/install index ca5b7f8..42ece2d 100644 --- a/scripts/install +++ b/scripts/install @@ -117,9 +117,9 @@ ynh_script_progression --message="Making install..." --weight=780 # Set right permissions chown -R "$app":"$app" $final_path -# Install rustup +# Install rustup with the toolchain needed by bitwarden_rs pushd $final_path - sudo -u "$app" RUSTUP_HOME=$final_path/.rustup CARGO_HOME=$final_path/.cargo bash -c 'curl -sSf -L https://static.rust-lang.org/rustup.sh | sh -s -- -y --default-toolchain=nightly' + sudo -u "$app" RUSTUP_HOME=$final_path/.rustup CARGO_HOME=$final_path/.cargo bash -c 'curl -sSf -L https://static.rust-lang.org/rustup.sh | sh -s -- -y --default-toolchain=$(cat build/rust-toolchain)' popd export PATH="$PATH:$final_path/.cargo/bin:$final_path/.local/bin:/usr/local/sbin" diff --git a/scripts/upgrade b/scripts/upgrade index 32c63af..f6d409f 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -126,9 +126,9 @@ chown -R "$app":"$app" $final_path if [ "$upgrade_type" == "UPGRADE_APP" ] then - # Install rustup + # Install rustup with the toolchain needed by bitwarden_rs pushd $final_path - sudo -u "$app" RUSTUP_HOME=$final_path/.rustup CARGO_HOME=$final_path/.cargo bash -c 'curl -sSf -L https://static.rust-lang.org/rustup.sh | sh -s -- -y --default-toolchain=nightly' + sudo -u "$app" RUSTUP_HOME=$final_path/.rustup CARGO_HOME=$final_path/.cargo bash -c 'curl -sSf -L https://static.rust-lang.org/rustup.sh | sh -s -- -y --default-toolchain=$(cat build/rust-toolchain)' popd export PATH="$PATH:$final_path/.cargo/bin:$final_path/.local/bin:/usr/local/sbin"