Loading nixos/tests/vaultwarden.nix +1 −2 Original line number Diff line number Diff line Loading @@ -54,9 +54,8 @@ let services.postgresql = { enable = true; initialScript = pkgs.writeText "postgresql-init.sql" '' CREATE DATABASE bitwarden; CREATE USER bitwardenuser WITH PASSWORD '${dbPassword}'; GRANT ALL PRIVILEGES ON DATABASE bitwarden TO bitwardenuser; CREATE DATABASE bitwarden WITH OWNER bitwardenuser; ''; }; Loading pkgs/tools/security/vaultwarden/Cargo.lock +580 −360 File changed.Preview size limit exceeded, changes collapsed. Show changes pkgs/tools/security/vaultwarden/default.nix +2 −2 Original line number Diff line number Diff line Loading @@ -9,13 +9,13 @@ in rustPlatform.buildRustPackage rec { pname = "vaultwarden"; version = "1.29.2"; version = "1.30.0"; src = fetchFromGitHub { owner = "dani-garcia"; repo = pname; rev = version; hash = "sha256-ByMPS68GBOvjB/RpoLAvgE+NcbbIa1qfU1TQ4yhbH+I="; hash = "sha256-mBKedJvb67FR4e8ZzdL8umg9XTgch1OWhbR1k46Lkn4="; }; cargoLock = { Loading pkgs/tools/security/vaultwarden/update.nix +17 −14 Original line number Diff line number Diff line { writeShellScript { writeShellApplication , lib , nix , nix-prefetch-git Loading @@ -8,20 +8,23 @@ , gnugrep , gnused , jq , yq }: writeShellScript "update-vaultwarden" '' PATH=${lib.makeBinPath [ curl git gnugrep gnused jq nix nix-prefetch-git nix-update ]} set -euxo pipefail lib.getExe (writeShellApplication { name = "update-vaultwarden"; runtimeInputs = [ curl git gnugrep gnused jq yq nix nix-prefetch-git nix-update ]; text = '' VAULTWARDEN_VERSION=$(curl --silent https://api.github.com/repos/dani-garcia/vaultwarden/releases/latest | jq -r '.tag_name') nix-update "vaultwarden" --version "$VAULTWARDEN_VERSION" URL="https://raw.githubusercontent.com/dani-garcia/vaultwarden/''${VAULTWARDEN_VERSION}/docker/Dockerfile.j2" WEBVAULT_VERSION=$(curl --silent "$URL" | grep "set vault_version" | sed -E "s/.*\"v([^\"]+)\".*/\\1/") old_hash=$(nix --extra-experimental-features nix-command eval -f default.nix --raw vaultwarden.webvault.bw_web_builds.outputHash) new_hash=$(nix --extra-experimental-features nix-command hash to-sri --type sha256 $(nix-prefetch-git https://github.com/dani-garcia/bw_web_builds.git --rev "v$WEBVAULT_VERSION" | jq --raw-output ".sha256")) sed -e "s#$old_hash#$new_hash#" -i pkgs/tools/security/vaultwarden/webvault.nix URL="https://raw.githubusercontent.com/dani-garcia/vaultwarden/''${VAULTWARDEN_VERSION}/docker/DockerSettings.yaml" WEBVAULT_VERSION="$(curl --silent "$URL" | yq -r ".vault_version" | sed s/^v//)" old_hash="$(nix --extra-experimental-features nix-command eval -f default.nix --raw vaultwarden.webvault.bw_web_builds.outputHash)" new_hash="$(nix-prefetch-git https://github.com/dani-garcia/bw_web_builds.git --rev "v$WEBVAULT_VERSION" | jq --raw-output ".sha256")" new_hash_sri="$(nix --extra-experimental-features nix-command hash to-sri --type sha256 "$new_hash")" sed -e "s#$old_hash#$new_hash_sri#" -i pkgs/tools/security/vaultwarden/webvault.nix nix-update "vaultwarden.webvault" --version "$WEBVAULT_VERSION" '' ''; }) pkgs/tools/security/vaultwarden/webvault.nix +4 −4 Original line number Diff line number Diff line Loading @@ -7,13 +7,13 @@ }: let version = "2023.7.1"; version = "2023.10.0"; bw_web_builds = fetchFromGitHub { owner = "dani-garcia"; repo = "bw_web_builds"; rev = "v${version}"; hash = "sha256-B7FGLKuwxldlHnIIzQbDjZT9cs5+lixo/fBtlexNLQc="; hash = "sha256-5vfmMJIGKyZlTQDi/t1YKAALbW/6BFAcWODfkypk/eA="; }; in buildNpmPackage rec { pname = "vaultwarden-webvault"; Loading @@ -23,10 +23,10 @@ in buildNpmPackage rec { owner = "bitwarden"; repo = "clients"; rev = "web-v${lib.removeSuffix "b" version}"; hash = "sha256-HEEUboaIY/Zi/wUhp9y7oIOuQl6csjo97eygTLPNfNo="; hash = "sha256-egXToXWfb9XV7JuCRBYJO4p/e+WOwMncPKz0oBgeALQ="; }; npmDepsHash = "sha256-8Epkvjzllt//kdrKT4jUDOhj47Fnb0qSFU1qJthL2Mo="; npmDepsHash = "sha256-iO8ZozVl1vOOqowQARnRJWSFUFnau46+dKfcMSkyU3o="; postPatch = '' ln -s ${bw_web_builds}/{patches,resources} .. Loading Loading
nixos/tests/vaultwarden.nix +1 −2 Original line number Diff line number Diff line Loading @@ -54,9 +54,8 @@ let services.postgresql = { enable = true; initialScript = pkgs.writeText "postgresql-init.sql" '' CREATE DATABASE bitwarden; CREATE USER bitwardenuser WITH PASSWORD '${dbPassword}'; GRANT ALL PRIVILEGES ON DATABASE bitwarden TO bitwardenuser; CREATE DATABASE bitwarden WITH OWNER bitwardenuser; ''; }; Loading
pkgs/tools/security/vaultwarden/Cargo.lock +580 −360 File changed.Preview size limit exceeded, changes collapsed. Show changes
pkgs/tools/security/vaultwarden/default.nix +2 −2 Original line number Diff line number Diff line Loading @@ -9,13 +9,13 @@ in rustPlatform.buildRustPackage rec { pname = "vaultwarden"; version = "1.29.2"; version = "1.30.0"; src = fetchFromGitHub { owner = "dani-garcia"; repo = pname; rev = version; hash = "sha256-ByMPS68GBOvjB/RpoLAvgE+NcbbIa1qfU1TQ4yhbH+I="; hash = "sha256-mBKedJvb67FR4e8ZzdL8umg9XTgch1OWhbR1k46Lkn4="; }; cargoLock = { Loading
pkgs/tools/security/vaultwarden/update.nix +17 −14 Original line number Diff line number Diff line { writeShellScript { writeShellApplication , lib , nix , nix-prefetch-git Loading @@ -8,20 +8,23 @@ , gnugrep , gnused , jq , yq }: writeShellScript "update-vaultwarden" '' PATH=${lib.makeBinPath [ curl git gnugrep gnused jq nix nix-prefetch-git nix-update ]} set -euxo pipefail lib.getExe (writeShellApplication { name = "update-vaultwarden"; runtimeInputs = [ curl git gnugrep gnused jq yq nix nix-prefetch-git nix-update ]; text = '' VAULTWARDEN_VERSION=$(curl --silent https://api.github.com/repos/dani-garcia/vaultwarden/releases/latest | jq -r '.tag_name') nix-update "vaultwarden" --version "$VAULTWARDEN_VERSION" URL="https://raw.githubusercontent.com/dani-garcia/vaultwarden/''${VAULTWARDEN_VERSION}/docker/Dockerfile.j2" WEBVAULT_VERSION=$(curl --silent "$URL" | grep "set vault_version" | sed -E "s/.*\"v([^\"]+)\".*/\\1/") old_hash=$(nix --extra-experimental-features nix-command eval -f default.nix --raw vaultwarden.webvault.bw_web_builds.outputHash) new_hash=$(nix --extra-experimental-features nix-command hash to-sri --type sha256 $(nix-prefetch-git https://github.com/dani-garcia/bw_web_builds.git --rev "v$WEBVAULT_VERSION" | jq --raw-output ".sha256")) sed -e "s#$old_hash#$new_hash#" -i pkgs/tools/security/vaultwarden/webvault.nix URL="https://raw.githubusercontent.com/dani-garcia/vaultwarden/''${VAULTWARDEN_VERSION}/docker/DockerSettings.yaml" WEBVAULT_VERSION="$(curl --silent "$URL" | yq -r ".vault_version" | sed s/^v//)" old_hash="$(nix --extra-experimental-features nix-command eval -f default.nix --raw vaultwarden.webvault.bw_web_builds.outputHash)" new_hash="$(nix-prefetch-git https://github.com/dani-garcia/bw_web_builds.git --rev "v$WEBVAULT_VERSION" | jq --raw-output ".sha256")" new_hash_sri="$(nix --extra-experimental-features nix-command hash to-sri --type sha256 "$new_hash")" sed -e "s#$old_hash#$new_hash_sri#" -i pkgs/tools/security/vaultwarden/webvault.nix nix-update "vaultwarden.webvault" --version "$WEBVAULT_VERSION" '' ''; })
pkgs/tools/security/vaultwarden/webvault.nix +4 −4 Original line number Diff line number Diff line Loading @@ -7,13 +7,13 @@ }: let version = "2023.7.1"; version = "2023.10.0"; bw_web_builds = fetchFromGitHub { owner = "dani-garcia"; repo = "bw_web_builds"; rev = "v${version}"; hash = "sha256-B7FGLKuwxldlHnIIzQbDjZT9cs5+lixo/fBtlexNLQc="; hash = "sha256-5vfmMJIGKyZlTQDi/t1YKAALbW/6BFAcWODfkypk/eA="; }; in buildNpmPackage rec { pname = "vaultwarden-webvault"; Loading @@ -23,10 +23,10 @@ in buildNpmPackage rec { owner = "bitwarden"; repo = "clients"; rev = "web-v${lib.removeSuffix "b" version}"; hash = "sha256-HEEUboaIY/Zi/wUhp9y7oIOuQl6csjo97eygTLPNfNo="; hash = "sha256-egXToXWfb9XV7JuCRBYJO4p/e+WOwMncPKz0oBgeALQ="; }; npmDepsHash = "sha256-8Epkvjzllt//kdrKT4jUDOhj47Fnb0qSFU1qJthL2Mo="; npmDepsHash = "sha256-iO8ZozVl1vOOqowQARnRJWSFUFnau46+dKfcMSkyU3o="; postPatch = '' ln -s ${bw_web_builds}/{patches,resources} .. Loading