teepot/packages/container-vault-admin/default.nix
Harald Hoyer eb39705ff1
feat: compat code for non x86_64-linux
- do not build packages, which require `x86_64-linux`
- use Phala `dcap-qvl` crate for remote attestation, if possible
- nix: exclude `nixsgx` on non `x86_64-linux` platforms

Signed-off-by: Harald Hoyer <harald@matterlabs.dev>
2025-04-10 11:57:46 +02:00

32 lines
673 B
Nix

# SPDX-License-Identifier: Apache-2.0
# Copyright (c) 2024 Matter Labs
{ dockerTools
, buildEnv
, stdenv
, teepot
, openssl
, curl
, nixsgx
}:
if (stdenv.hostPlatform.system != "x86_64-linux") then { } else
dockerTools.buildLayeredImage {
name = "vault-admin";
config.Entrypoint = [ "${teepot.teepot.vault_admin}/bin/vault-admin" ];
contents = buildEnv {
name = "image-root";
paths = with dockerTools; with nixsgx;[
openssl.out
curl.out
sgx-dcap.quote_verify
sgx-dcap.default_qpl
usrBinEnv
binSh
caCertificates
fakeNss
teepot.teepot.vault_admin
];
pathsToLink = [ "/bin" "/lib" "/etc" ];
};
}