Recently, I have been doing an ios build where I remotely run a slave Mac using a remote web interface through my IP address.
I already tried to remove node / npm and reinstall it, but it still gets the same error after installing cordova .
I also checked if my directory was for node, and that is fine:

I already tried the solution put set +eat the top of my shell script, but after that it still doesn't work.
I have been trying to understand this problem for 5 days, and it still has not been resolved, so I hope you guys can try to help me in this situation.
This error occurs when the assembly starts ios.
Started by upstream project "CordovaHelloWorld" build number 97
originally caused by:
Started by user (user)
Building remotely on mac-slave (ios) in workspace
/Users/(username)/Desktop/jenkinsMacSlave/workspace/CordovaHelloWorld/PLATFORM/ios
> git rev-parse --is-inside-work-tree
Fetching changes from the remote Git repository
> git config remote.origin.url https://github.com/(user)/Jenkins
Fetching upstream changes from https://github.com/(user)/Jenkins
> git --version
> git fetch --tags --progress https://github.com/(user)/Jenkins
+refs/heads/:refs/remotes/origin/
Checking out Revision b08e07983673bdc08dcb6e81d65e83a3cb5edc5c
(origin/Jenkinsios)
> git config core.sparsecheckout
> git checkout -f b08e07983673bdc08dcb6e81d65e83a3cb5edc5c
> git rev-list b08e07983673bdc08dcb6e81d65e83a3cb5edc5c
[ios] $ /bin/sh -xe
/var/folders/sj/01rfz4rx1ws_smjvggb_klzw0000gq/T/jenkins150886583207745932.sh
+ set +e
+ /usr/local/bin/cordova platform rm ios --no-telemetry --no-update-notifier
env: node: No such file or directory
+ /usr/local/bin/cordova platform add ios --no-telemetry --no-update-notifier
env: node: No such file or directory
+ /usr/local/bin/cordova build ios --no-telemetry --no-update-notifier
env: node: No such file or directory
Build step 'Execute shell' marked build as failure
Finished: FAILURE
, .
, , !
EDIT:
: