I\'m well aware of the root of this issue, as npm
wrote on their blog: http://blog.npmjs.org/post/78085451721/npms-self-signed-certificate-is-no-more
Th
I struggled with this as well. Fix: https://gist.github.com/anonymous/fb32a4b053fe121b0b03. When applied in container_commands
npm install
has already run.
Was having the same issue today. I fixed it by setting my global npmrc file, as follows:
02_no-cert:
command: "rm -rf /opt/elasticbeanstalk/node-install/node-v0.10.21-linux-x64/etc && mkdir /opt/elasticbeanstalk/node-install/node-v0.10.21-linux-x64/etc && echo 'ca = ' > /opt/elasticbeanstalk/node-install/node-v0.10.21-linux-x64/etc/npmrc"
ignoreErrors: true
So I figured out a way to make it work:
Put this in .ebextensions
:
commands:
01_enable_rootaccess:
command: echo Defaults:root \!requiretty >> /etc/sudoers
02_no-cert:
command: sudo /opt/elasticbeanstalk/node-install/node-v0.10.10-linux-x64/bin/npm config set ca ""
Worked like a charm in my case.
It did not work for me either.
What I did find: at the time that the "commands" block is run, the node-install folder is empty. I assume this is because the commands run before node + npm is fully deployed to the bare instance.
I will try and test this assumption later today, and provide further feedback.
Sadly, didn't work for me. Amazon gave me a different version, that has not worked either:
commands: 01-command: command: '$(find /opt/elasticbeanstalk/node-install/*/bin | grep "npm$" | head -n1) config set ca ""'