-
Type: Task
-
Status: Resolved
-
Priority: Major
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: Continuous Integration, Package Repositories
-
Tags:
-
Team:GANG
Today you cannot build Web UI without access to https://mavenin.nuxeo.com/nexus/#browse/search/npm=group%3Dnuxeo
We'll eventually publish to npmjs central public repo when releasing but not the snapshot.
I understand that https://packages.nuxeo.com would be publically available for this kind of purpose
In https://mavenin.nuxeo.com/nexus/#browse/search/npm=group%3Dnuxeo, we publish:
- nuxeo-elements
- nuxeo-ui-elements
- nuxeo-dataviz-elements
which are direct dependencies of Web UI and build by our CI. For now, it is https://qa.nuxeo.org/jenkins/job/master/job/nuxeo-elements-master/configure that push packages to mavenin.
Could we even do the same with https://packages.nuxeo.com? No
Small attempt told:
18:48:06 npm notice 18:48:06 npm ERR! code ENEEDAUTH 18:48:06 npm ERR! need auth auth required for publishing 18:48:06 npm ERR! need auth You need to authorize this machine using `npm adduser` 18:48:06 18:48:06 npm ERR! A complete log of this run can be found in: 18:48:06 npm ERR! /opt/jenkins/.npm/_logs/2019-09-24T16_48_06_255Z-debug.log
https://qa.nuxeo.org/jenkins/job/master/job/nuxeo-elements-master/302/console.
Anyway, let's say it our JenkinsX future pipeline that would be in charge -> need to update https://github.com/nuxeo/nuxeo-elements/blob/master/Jenkinsfile#L133:
sh "npx lerna exec --ignore @nuxeo/nuxeo-elements-storybook -- npm publish --registry=http://nexus/repository/npmjs-nuxeo/ --tag SNAPSHOT"
in order to publish to https://packages.nuxeo.com/.
We also have forked libraries under the nuxeo scope:
- papertypeahead
- chart-elements
- page
We could manually publish them
git clone --single-branch --branch 0.6-p3 git@github.com:nuxeo/paper-typeahead.git git clone --single-branch --branch webui-p3 git@github.com:nuxeo/page.js.git git clone --single-branch --branch 4.0.0-p3 git@github.com:nuxeo/chart-elements.git
then
npm login --registry=https://packages.nuxeo.com/repository/npmjs-nuxeo/ npm adduser --registry=https://packages.nuxeo.com/repository/npmjs-nuxeo/ --scope=@nuxeo
finally
npm publish --registry=https://packages.nuxeo.com/repository/npmjs-nuxeo/
Npm Repo settings
So far, I am able to login to https://packages.nuxeo.com/ with a GH Personal access tokens with read:org permission. I am admin right there, couple of observation:
- Realms was missing npm Bearer token Realm which is needed to be able to issue
npm login ..
command
- The npmjs-nuxeo repo has Allow redeploy policy which is good and needed to republish snapshot
- The roles:nuxeodev has
nx-repository-view-*-*-*
which should include
nx-repository-view-npm-npmjs-nuxeo-*-*
OK
- depends on
-
NXBT-3022 Fix npm publish to packages.nuxeo.com
- Resolved
-
ELEMENTS-1073 Publish elements to packages.nuxeo.com
- Resolved