How did you import the module? Looking at the error it has either not been imported correcly or NODE_FUNCTION_ALLOW_EXTERNAL has not been set to include it.
Hey Jon! Thanks for your reply.
We tried so many things and I was barely able to follow lol.
But in short, in the end we managed to install @hashgraph/sdk and it worked in n8n! However, once we would restart docker it would be removed again.
So my friend came up with a solution using a docker file:
USER root
RUN npm install --save @hashgraph/sdk
USER node
and in docker-compose:
build:
dockerfile: Dockerfile
This gave us a “invalid host header” error (no idea what it means).
We also tried directly adding it directly to the docker compose file:
I’m pretty sure I scoured the forum finding similar cases - I think I did find one (not more, maybe I used the wrong keywords) that helped me get here.
With the code for the Dockerfile you mention in your message, would that be the only thing to be changed? Or do you also need to make the adjustments I made in the docker-compose.yml file?