Not able to use Crypto module
-
Hello to all,
I'm trying a bit N8N, to see the performance on various tasks that now we use some bash or python script to do.
But I wasn't able to use the Node Crypto function, even when I set the ENV to
export NODE_FUNCTION_ALLOW_EXTERNAL=*or
export NODE_FUNCTION_ALLOW_EXTERNAL=cryptoI even try with the API to add ENV to the container directly but Nada.
my test crypt in the Function node is this:
let crypto; const items = [{ json: { "is disable": "yes" } }] try { crypto = await import('crypto'); } catch (err) { return items }
I'm not a good JS dev, and my understanding is pretty basic (i live tnx to the debuggers) so is highly possible that is my code doesn't work, but maybe is some weird implementation with the docker container.
-
Hello to all,
I'm trying a bit N8N, to see the performance on various tasks that now we use some bash or python script to do.
But I wasn't able to use the Node Crypto function, even when I set the ENV to
export NODE_FUNCTION_ALLOW_EXTERNAL=*or
export NODE_FUNCTION_ALLOW_EXTERNAL=cryptoI even try with the API to add ENV to the container directly but Nada.
my test crypt in the Function node is this:
let crypto; const items = [{ json: { "is disable": "yes" } }] try { crypto = await import('crypto'); } catch (err) { return items }
I'm not a good JS dev, and my understanding is pretty basic (i live tnx to the debuggers) so is highly possible that is my code doesn't work, but maybe is some weird implementation with the docker container.
@MooCloud_Matt said in Not able to use Crypto module:
But I wasn't able to use the Node Crypto function, even when I set the ENV to
export NODE_FUNCTION_ALLOW_EXTERNAL=*orDid you restart the app after setting the env?
-
Hello to all,
I'm trying a bit N8N, to see the performance on various tasks that now we use some bash or python script to do.
But I wasn't able to use the Node Crypto function, even when I set the ENV to
export NODE_FUNCTION_ALLOW_EXTERNAL=*or
export NODE_FUNCTION_ALLOW_EXTERNAL=cryptoI even try with the API to add ENV to the container directly but Nada.
my test crypt in the Function node is this:
let crypto; const items = [{ json: { "is disable": "yes" } }] try { crypto = await import('crypto'); } catch (err) { return items }
I'm not a good JS dev, and my understanding is pretty basic (i live tnx to the debuggers) so is highly possible that is my code doesn't work, but maybe is some weird implementation with the docker container.
@MooCloud_Matt Since
cryptois a node built-in, you have to do:export NODE_FUNCTION_ALLOW_BUILTIN=cryptoI fixed up our docs at https://docs.cloudron.io/apps/n8n/#built-in-node-modules
-
@MooCloud_Matt Since
cryptois a node built-in, you have to do:export NODE_FUNCTION_ALLOW_BUILTIN=cryptoI fixed up our docs at https://docs.cloudron.io/apps/n8n/#built-in-node-modules
-
G girish marked this topic as a question on
-
G girish has marked this topic as solved on
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login