Skip to content
Snippets Groups Projects
Commit c4877fff authored by Jean-Paul Calderone's avatar Jean-Paul Calderone
Browse files

accept stripe secret key config and pass it along

parent d5bd3fd3
No related branches found
No related tags found
1 merge request!20Deploy PaymentServer with Stripe API key
......@@ -49,6 +49,13 @@ in {
``Ristretto``.
'';
};
services.private-storage-issuer.stripeSecretKeyPath = lib.mkOption {
type = lib.types.path;
description = ''
The path to a file containing a Stripe secret key to use for charge
and payment management.
'';
};
services.private-storage-issuer.database = lib.mkOption {
default = "Memory";
type = lib.types.enum [ "Memory" "SQLite3" ];
......@@ -124,8 +131,9 @@ in {
else
# Only for automated testing.
"--http-port 80";
stripeArgs = "--stripe-key ${builtins.readFile cfg.stripeSecretKeyPath}";
in
"${cfg.package}/bin/PaymentServer-exe ${issuerArgs} ${databaseArgs} ${httpsArgs}";
"${cfg.package}/bin/PaymentServer-exe ${issuerArgs} ${databaseArgs} ${httpsArgs} ${stripeArgs}";
};
# Certificate renewal. We must declare that we *require* it in our
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment