Skip to content

Commit

Permalink
Add shell.nix
Browse files Browse the repository at this point in the history
With this on nixos the server can be launched with:

```sh
nix-shell --command ./otsd
```

Approach suggested https://wiki.nixos.org/wiki/Python

In comparison to the requirements.txt we are not specifying exact
version for each lib, in case of incompatibility deps must be packaged
like suggested in the mentioned guide.
  • Loading branch information
RCasatta committed May 27, 2024
1 parent 9133035 commit 7ae2b93
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions shell.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# shell.nix
let
# We pin to a specific nixpkgs commit for reproducibility.
# Last updated: 2024-04-29. Check for new commits at https://status.nixos.org.
pkgs = import (fetchTarball "https://github.com/NixOS/nixpkgs/archive/cf8cc1201be8bc71b7cbbbdaf349b22f4f99c7ae.tar.gz") {};
in pkgs.mkShell {
packages = [
(pkgs.python3.withPackages (python-pkgs: [
python-pkgs.opentimestamps
python-pkgs.leveldb
python-pkgs.pystache
python-pkgs.requests
python-pkgs.qrcode
python-pkgs.simplejson
python-pkgs.bitcoinlib
]))
];
}

0 comments on commit 7ae2b93

Please sign in to comment.