diff --git a/pkgs/by-name/od/odoo17/package.nix b/pkgs/by-name/od/odoo17/package.nix index 74358118c520..8befd6786dbc 100644 --- a/pkgs/by-name/od/odoo17/package.nix +++ b/pkgs/by-name/od/odoo17/package.nix @@ -55,6 +55,13 @@ python.pkgs.buildPythonApplication rec { }" ]; + postPatch = '' + # hardcode the location of the unwrapped python scrip, otherwise the websocket + # server (called longpoll in codebase) will fail to start. + substituteInPlace odoo/service/server.py \ + --replace-fail 'sys.argv[0]' "'${placeholder "out"}/bin/.odoo-wrapped'" + ''; + build-system = with python.pkgs; [ setuptools ];