I'm trying to install a package that exists on our private repo. The goal is to share the repo with a partner, but I need to make sure they can install it. In theory, it should work, but none of the documented solutions are working for me
I've tried adding the package to the package.json file
"dependencies": {
"package_name": "git+https://<deploy-token-name>:<deploy-token>@gitlab.domain.com/group/repo.git"
}
And then installing with npm but it seems to fail on the deploy token, but it's hard to say because the log isn't very helpful and then our whole gitlab deployment goes down for a moment #fun
29 error
29 error undefined
29 error exited with error code: 128
I've also tried with a private access token
"package-name": "https://oauth2:<access-token>@gitlab.domain.com/group/repo.git"
This results in an actual error that I can understand, except the error is saying there isn't a package.json in the repository, but there most certainly is
npm ERR! package.json Non-registry package missing package.json: package-name@https://oauth2:<access-token>@gitlab.domain.com/group/repo.git.
npm ERR! package.json npm can't find a package.json file in your current directory.
I've tried with ssh (with a ssh key setup that works for commits etc)
git+ssh://git@my-domain.com:my-project/my-repo#my-branch
And that results in an error
npm ERR! premature close
I've read through a dozen related issues and articles, but nothing is working for me