Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[24.05] vaultwarden: 1.30.5 -> 1.31.0 -> 1.32.0 #334099

Merged
merged 5 commits into from
Aug 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 60 additions & 0 deletions pkgs/development/compilers/rust/1_79.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# New rust versions should first go to staging.
# Things to check after updating:
# 1. Rustc should produce rust binaries on x86_64-linux, aarch64-linux and x86_64-darwin:
# i.e. nix-shell -p fd or @GrahamcOfBorg build fd on github
# This testing can be also done by other volunteers as part of the pull
# request review, in case platforms cannot be covered.
# 2. The LLVM version used for building should match with rust upstream.
# Check the version number in the src/llvm-project git submodule in:
# https://github.com/rust-lang/rust/blob/<version-tag>/.gitmodules
# 3. Firefox and Thunderbird should still build on x86_64-linux.

{ stdenv, lib
, newScope, callPackage
, CoreFoundation, Security, SystemConfiguration
, pkgsBuildTarget, pkgsBuildBuild, pkgsBuildHost, pkgsTargetTarget
, makeRustPlatform
, wrapRustcWith
, llvmPackages_18, llvm_18
} @ args:

import ./default.nix {
rustcVersion = "1.79.0";
rustcSha256 = "sha256-Fy7PPH0fnZ+xbNKmKIaXgmcEFt7QEp5SSoZ1H5YUSMA=";

llvmSharedForBuild = pkgsBuildBuild.llvmPackages_18.libllvm.override { enableSharedLibraries = true; };
llvmSharedForHost = pkgsBuildHost.llvmPackages_18.libllvm.override { enableSharedLibraries = true; };
llvmSharedForTarget = pkgsBuildTarget.llvmPackages_18.libllvm.override { enableSharedLibraries = true; };

# For use at runtime
llvmShared = llvm_18.override { enableSharedLibraries = true; };

# Expose llvmPackages used for rustc from rustc via passthru for LTO in Firefox
llvmPackages = llvmPackages_18;

# Note: the version MUST be one version prior to the version we're
# building
bootstrapVersion = "1.78.0";

# fetch hashes by running `print-hashes.sh ${bootstrapVersion}`
bootstrapHashes = {
i686-unknown-linux-gnu = "8f3f5d2ab7b609ab30d584cfb5cecc3d8b16d2620fffb7643383c8a0a3881e21";
x86_64-unknown-linux-gnu = "1307747915e8bd925f4d5396ab2ae3d8d9c7fad564afbc358c081683d0f22e87";
x86_64-unknown-linux-musl = "c11ab908cbffbe98097d99ed62f5db00aa98496520b1e09583a151d36df7fca4";
arm-unknown-linux-gnueabihf = "2a2b1cf93b31e429624380e5b0d2bcce327274f8593b63657b863e38831f6421";
armv7-unknown-linux-gnueabihf = "fcce5ddb4f55bbdc9a1359a4cb6e65f2ff790d59ad228102cd472112ea65d3fe";
aarch64-unknown-linux-gnu = "131eda738cd977fff2c912e5838e8e9b9c260ecddc1247c0fe5473bf09c594af";
aarch64-unknown-linux-musl = "f328bcf109bf3eae01559b53939a9afbdb70ef30429f95109f7ea21030d60dfa";
x86_64-apple-darwin = "6c91ed3bd90253961fcb4a2991b8b22e042e2aaa9aba9f389f1e17008171d898";
aarch64-apple-darwin = "3be74c31ee8dc4f1d49e2f2888228de374138eaeca1876d0c1b1a61df6023b3b";
powerpc64le-unknown-linux-gnu = "c5aedb12c552daa18072e386697205fb7b91cef1e8791fe6fb74834723851388";
riscv64gc-unknown-linux-gnu = "847a925ace172d4c0a8d3da8d755b8678071ef73e659886128a3103bb896dcd9";
x86_64-unknown-freebsd = "b9cc84c60deb8da08a6c876426f8721758f4c7e7c553b4554385752ad37c63df";
};

selectRustPackage = pkgs: pkgs.rust_1_79;

rustcPatches = [ ];
}

(builtins.removeAttrs args [ "llvmPackages_18" "llvm_18"])
8 changes: 4 additions & 4 deletions pkgs/tools/security/vaultwarden/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,16 @@ in

rustPlatform.buildRustPackage rec {
pname = "vaultwarden";
version = "1.30.5";
version = "1.32.0";

src = fetchFromGitHub {
owner = "dani-garcia";
repo = pname;
repo = "vaultwarden";
rev = version;
hash = "sha256-OwFB5ULWBefDHSkUM3nT0v2jcc5vHUvs8Ex0JauDu8w=";
hash = "sha256-y8+hkvUKj0leJJ5w72HOVDSOtKW6y2Y44VfOZSetn4M=";
};

cargoHash = "sha256-K0T0uTERjxlI3bGG/Tz6sJ0A08J0ROAhpppdZcdQPB8=";
cargoHash = "sha256-1Z0ba1FhxQ5qVpofi0XD1MYz02QCvdXGeuViW3lU6JQ=";

# used for "Server Installed" version in admin panel
env.VW_VERSION = version;
Expand Down
8 changes: 4 additions & 4 deletions pkgs/tools/security/vaultwarden/webvault.nix
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@
}:

let
version = "2024.5.0";
version = "2024.6.2b";

bw_web_builds = fetchFromGitHub {
owner = "dani-garcia";
repo = "bw_web_builds";
rev = "v${version}";
hash = "sha256-di0oOM3ju3rkDVGmKpvS6sCaIXL/QGawr0TUrQjZ8dM=";
hash = "sha256-Gcn/TOXdhMqGq4NTCPQTTEvN5rOQS3LImPUYBsv8de8=";
};

in buildNpmPackage rec {
Expand All @@ -25,10 +25,10 @@ in buildNpmPackage rec {
owner = "bitwarden";
repo = "clients";
rev = "web-v${lib.removeSuffix "b" version}";
hash = "sha256-kQ2tWfkkG5aifA8UGb5X1wQkGZr6dcVlrb+b78RFX/k=";
hash = "sha256-HMQ0oQ04WkLlUgsYt6ZpcziDq05mnSA0+VnJCpteceg=";
};

npmDepsHash = "sha256-gprJGOE/uSSM3NHpcbelB7sueObEl4o522WRHIRFmwo=";
npmDepsHash = "sha256-zMzQEM5mV14gewzYhy1F2bNEugXjZSOviYwYVV2Cb8c=";

postPatch = ''
ln -s ${bw_web_builds}/{patches,resources} ..
Expand Down
6 changes: 6 additions & 0 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -16490,6 +16490,10 @@ with pkgs;
inherit (darwin.apple_sdk.frameworks) CoreFoundation Security SystemConfiguration;
llvm_17 = llvmPackages_17.libllvm;
};
rust_1_79 = callPackage ../development/compilers/rust/1_79.nix {
inherit (darwin.apple_sdk.frameworks) CoreFoundation Security SystemConfiguration;
llvm_18 = llvmPackages_18.libllvm;
};
rust = rust_1_77;

mrustc = callPackage ../development/compilers/mrustc { };
Expand All @@ -16499,6 +16503,7 @@ with pkgs;
};

rustPackages_1_77 = rust_1_77.packages.stable;
rustPackages_1_79 = rust_1_79.packages.stable;
rustPackages = rustPackages_1_77;

inherit (rustPackages) cargo cargo-auditable cargo-auditable-cargo-wrapper clippy rustc rustPlatform;
Expand Down Expand Up @@ -40209,6 +40214,7 @@ with pkgs;
vazir-code-font = callPackage ../data/fonts/vazir-code-font { };

vaultwarden = callPackage ../tools/security/vaultwarden {
inherit (rustPackages_1_79) rustPlatform;
inherit (darwin.apple_sdk.frameworks) Security CoreServices SystemConfiguration;
};
vaultwarden-sqlite = vaultwarden;
Expand Down
Loading