While walking through the angular-phonecat tutorial, I came across the following error immediately after running the npm install command:
I looked in the log file, too, but it more or less repeats the same error message shown in the console. What am I missing?
My guess is that you're behind some network proxy or firewall that restricts the ports you can access. In this case, you can tell git to use https:// instead of git:// for cloning. Answer is based off of this question.
git config --global url.https://github.com/.insteadOf git://github.com/
Try making git use an http connection rather than a git one like so:
git config --global url."https://".insteadOf git://
Sometimes the git protocol is blocked, but the https one won't be.
A similar issue is referenced here
Related
I have a Nestjs Application which I try to run in a docker container. It all worked fine just until recently where I get the error Parse Error: Missing expected CR after header value. I'm trying to make a http GET Request to a webserver of an IoT device. Furthermore this error occurs only when I run the server-app inside a docker container. When I run it locally on a windows or macos machine everything works fine.
I tried using different versions of nodejs in docker. 14, 16 and 18. This error always comes up, independent of which version I use. I have no idea how I could debug this error, since it only occurs when I serve the app inside a docker container.
This is my dockerfile:
FROM node:slim
RUN mkdir -p /app
WORKDIR /app
COPY src .
COPY package.json .
RUN apt update && apt install python3 make g++ -y
RUN npm install --force
EXPOSE 3000
CMD ["npm", "run", "start:dev"]
According to this issue, this was recently implemented in Node v14.20.0, v16.16.0 and v18.5.0. Apparently it fixes a vulnerability in the HTTP parser of earlier versions.
Comments below the issue suggest various workarounds if it's not possible to fix the client, the easiest of which seems to be to set the insecureHTTPParser flag to true when creating the HTTP server.
Alternatively, revert to an older minor version of each of the Node.js versions mentioned above.
I have a bonobo server on my server that is running windows 10.
I'm trying to link a new hook on "Update", so the files from the node development server can get updated directly from git.
I tried to do so using a cmd file, examples to follow:
update file in hooks
cmd //C "start C:\webServer\node\testServer\update.bat"
update.bat on the same folder on testServer
set PATH=%PATH%;C:\Program Files\Git\cmd\git.exe
cd C://webServer/node/testServer
git pull
That was returning the following error:
git: 'pull' is not a git command. See 'git --help'
I did some research and found out this post "git pull" broken where they talk about using -exec-path on Mac, I tried to search the equivalent in Windows and found out some variables for path related issues, tried them an none of them worked, also tried to reinstall git without any other result, at that point I was tired of it and I tried to use a node library, simple-git, that allows me to do a pull request using node specifying the path! I tried it on the server, and it worked! (I will attach the code of the file below) so I thought to try it from the remote server, but then I got the same error again, pull is not a git command, I tried to call the node file in different ways, I tried some python script to run a cmd command that runs the node server, I tried using bat and sh files, even using node to run another instance of node, and nothing worked, it always returns pull is not a git command :/
Node simple-git code
require('simple-git')("C:\\webServer\\node\\testServer")
.pull(function(a,b){
console.log(a,b); //for debug
})
Has additional information, git is properly set up as an environmental variable and I can access it without problems from the server, this issue only happens when trying to execute the pull from the hooks!
If anyone can give me some tips on what to try that would be awesome, thanks!
Trying to set up project on github pages, but during following steps from
here
at step 2 I getting this error from images
Any idea?
I working on Win7
with NPM 5.6.0
Node 8.11.3
It seems you need to run as administrator, like so: sudo npm install --save gh-pages.
Or if you'd running on Windows could be:
right-click on CLI icon
open as administrator
Perform your command (now you're administrator)
The error you're getting indicates you need to elevate your shell's permission.
Use your environment's equivalent of sudo/"Run as Administrator" to grant the proper access to perform the functions required to install.
I have tried running the install with "Run as Admin" feature on windows too, but the same issue persists.
I see this question has been posted before but still no resolution given.
Basically the following error message comes in the middle of the install and the install stops. Please help.
Error message:
"Failed to contact install server. Please try again later."
Check if you have Node js already installed before installing meteorjs other wise it crashes on Windows sometimes hope it helped.
https://nodejs.org/en/download/
Install meteor with this installer: https://github.com/meteor/meteor/wiki/Preview-of-Meteor-on-Windows
If you are behind a proxy set these parameters HTTP_PROXY and HTTPS_PROXY: Using Meteor behind a proxy
Update your meteor installation: meteor update
The meteor will be updated to the last version.
install from https://github.com/meteor/meteor/wiki/Preview-of-Meteor-on-Windows (the >60MB file) and set the user.meteor folder in your path
the problem with windows installation is too long pathnames (>256) so better try a linux VM
I have nodejs and mongoDB installed on 32bit winXP veteran. And I am trying to link them.
In the mongoDB docs its stated that the easiest way is by this command:
npm install mongodb
Unfortunately it throws the following exception:
"Failed to replace env in config: ${APPDATA}"
I tried to point the NODE_PATH variable to the "npm\node_modules" folder but this does not solve my problem.
What additional configuration am I missing?
In the end just ran the cmd not as Administrator but simply from my account and the command("npm install mongodb") worked as expected.
After that I uninstalled it since this was kind of weird. And again tried as Administrator and it failed again. And again succeeded with my account. So I left it be.