21 lines
339 B
Nix
21 lines
339 B
Nix
|
{ pkgs ? import <nixpkgs> { } }:
|
||
|
let
|
||
|
|
||
|
myPython = pkgs.python3.withPackages (python-packages:
|
||
|
with python-packages; [
|
||
|
paho-mqtt
|
||
|
]);
|
||
|
|
||
|
startServer = pkgs.writers.writeBashBin "start-server" ''
|
||
|
${myPython}/bin/python ./main.py
|
||
|
'';
|
||
|
|
||
|
in pkgs.mkShell {
|
||
|
|
||
|
buildInputs = with pkgs; [
|
||
|
myPython
|
||
|
startServer
|
||
|
];
|
||
|
|
||
|
}
|