Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
Is anonymous publishing allowed? #212
We recently switched to sinopia to verdaccio (had an issue with scoped packages and discovered sinopia was dead) and we were able to move to a private network server.
In an attempt to make my developers' lives easier, I thought I could set $all for access and publish in our config. But it would seem no one can publish packages at the moment.
Steps to reproduce:
Using the config below, attempt to publish a package.
Current docker release
@mattwwarren that's right. According https://github.com/npm/npm-registry-client/blob/master/lib/publish.js#L27 a
Dirty hack, but it's a npm "issue".
&> yarn publish --registry http://localhost:4873/ // and in the config file I set (config.yaml) publish: $authenticated
yarn publish v0.24.5 [1/4] Bumping version... info Current version: 1.1.1 question New version: 1.2.1 info New version: 1.2.1 [2/4] Logging in... [3/4] Publishing... error An unexpected error occurred: "http://localhost:4873/npm_test: unregistered users are not allowed to publish package npm_test". info If you think this is a bug, please open a bug report with the information provided in "/Users/user/projects/npm_test/yarn-error.log". info Visit https://yarnpkg.com/en/docs/cli/publish for documentation about this command.
It fails as is expected, but, then with
yarn publish v0.24.5 [1/4] Bumping version... info Current version: 1.2.1 question New version: 1.3.1 info New version: 1.3.1 [2/4] Logging in... [3/4] Publishing... success Published. [4/4] Revoking token... info Not revoking login token, specified via config file. ✨ Done in 5.17s.
So, it seems the workaround seems to be either use
@juanpicado thanks for the tip about yarn. Many of my developers are switching to it and this will make them very happy.
@Meeeeow I also tried with max_users: -1 but as juan pointed out in the npm-registry-client lib, my request never even made it to the server.
In light of all this information, I'm going to close this issue. Thanks for the responses, all.