From 2b7f3967973d19288ca61686bda3a33f4f95959d Mon Sep 17 00:00:00 2001 From: Jens Meisner Date: Tue, 25 Nov 2025 14:39:41 +0100 Subject: [PATCH 1/2] switched from npm.coremedia.io to nexus --- .github/workflows/build.yml | 6 +++--- .github/workflows/env.yml | 4 ++-- .github/workflows/list.yml | 4 ++-- .github/workflows/pre-release-gc.yml | 8 ++++---- .github/workflows/pre-release.yml | 12 ++++++------ .github/workflows/release.yml | 16 ++++++++-------- .github/workflows/unpublish.yml | 12 ++++++------ README.md | 3 ++- 8 files changed, 33 insertions(+), 32 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3052e52f92..023e5ab1ac 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -49,9 +49,9 @@ on: required: false default: false secrets: - CM_NPM_USER: + PLUGINS_NEXUS_USER: required: true - CM_NPM_PASSWORD: + PLUGINS_NEXUS_PASSWORD: required: true run-name: | @@ -90,7 +90,7 @@ jobs: - id: authorize name: "NPM Authorization" run: | - result=$(curl -s -H "Accept: application/json" -H "Content-Type:application/json" -X PUT --data '{"name": "${{ secrets.CM_NPM_USER }}", "password": "${{ secrets.CM_NPM_PASSWORD }}"}' "${{ env.npmUrl }}/-/user/org.couchdb.user:${{ secrets.CM_NPM_USER }}" | jq --raw-output .token) + result=$(curl -s -H "Accept: application/json" -H "Content-Type:application/json" -X PUT --data '{"name": "${{ secrets.PLUGINS_NEXUS_USER }}", "password": "${{ secrets.PLUGINS_NEXUS_PASSWORD }}"}' "${{ env.npmUrl }}/-/user/org.couchdb.user:${{ secrets.PLUGINS_NEXUS_USER }}" | jq --raw-output .token) # Ensure, the token is not exposed in output. echo "::add-mask::${result}" echo "NODE_AUTH_TOKEN=${result}" >> $GITHUB_ENV diff --git a/.github/workflows/env.yml b/.github/workflows/env.yml index b2125e1527..dba5afdb5b 100644 --- a/.github/workflows/env.yml +++ b/.github/workflows/env.yml @@ -10,7 +10,7 @@ on: description: "URL of NPM repository to use (without trailing '/'" value: ${{ jobs.init.outputs.npm-url }} -permissions: {} +permissions: { } jobs: init: @@ -24,7 +24,7 @@ jobs: - id: npm name: "NPM Repository" run: | - host="npm.coremedia.io" + host="repository.coremedia.com/nexus/repository/coremedia-npm" url="https://${host}" echo "host=${host}" >> $GITHUB_OUTPUT echo "url=${url}" >> $GITHUB_OUTPUT diff --git a/.github/workflows/list.yml b/.github/workflows/list.yml index 1003472e2c..c37d507790 100644 --- a/.github/workflows/list.yml +++ b/.github/workflows/list.yml @@ -16,7 +16,7 @@ on: required: false type: number -permissions: {} +permissions: { } jobs: env: @@ -35,7 +35,7 @@ jobs: - id: authorize name: "NPM Authorization" run: | - result=$(curl -s -H "Accept: application/json" -H "Content-Type:application/json" -X PUT --data '{"name": "${{ secrets.CM_NPM_USER }}", "password": "${{ secrets.CM_NPM_PASSWORD }}"}' "${{ env.NPM_URL }}/-/user/org.couchdb.user:${{ secrets.CM_NPM_USER }}" | jq -r .token) + result=$(curl -s -H "Accept: application/json" -H "Content-Type:application/json" -X PUT --data '{"name": "${{ secrets.PLUGINS_NEXUS_USER }}", "password": "${{ secrets.PLUGINS_NEXUS_PASSWORD }}"}' "${{ env.NPM_URL }}/-/user/org.couchdb.user:${{ secrets.PLUGINS_NEXUS_USER }}" | jq -r .token) # Ensure, the token is not exposed in output. echo "::add-mask::${result}" echo "NPM_AUTH_TOKEN=${result}" >> $GITHUB_ENV diff --git a/.github/workflows/pre-release-gc.yml b/.github/workflows/pre-release-gc.yml index efcb79d941..991b389fd4 100644 --- a/.github/workflows/pre-release-gc.yml +++ b/.github/workflows/pre-release-gc.yml @@ -28,8 +28,8 @@ on: default: true env: - NPM_REPOSITORY: npm.coremedia.io - NPM_REPOSITORY_URL: https://npm.coremedia.io + NPM_REPOSITORY: repository.coremedia.com/nexus/repository/coremedia-npm + NPM_REPOSITORY_URL: https://repository.coremedia.com/nexus/repository/coremedia-npm NODE_VERSION: 20 jobs: @@ -49,8 +49,8 @@ jobs: --header "Accept: application/json" \ --header "Content-Type:application/json" \ --request PUT \ - --data '{"name": "${{ secrets.CM_NPM_USER }}", "password": "${{ secrets.CM_NPM_PASSWORD }}"}' \ - "${{ env.NPM_REPOSITORY_URL }}/-/user/org.couchdb.user:${{ secrets.CM_NPM_USER }}" | \ + --data '{"name": "${{ secrets.PLUGINS_NEXUS_USER }}", "password": "${{ secrets.PLUGINS_NEXUS_PASSWORD }}"}' \ + "${{ env.NPM_REPOSITORY_URL }}/-/user/org.couchdb.user:${{ secrets.PLUGINS_NEXUS_USER }}" | \ jq -r .token) echo "::add-mask::$NPM_AUTH_TOKEN" echo "NPM_CONFIG_//${{ env.NPM_REPOSITORY }}/:_authToken=${NPM_AUTH_TOKEN}" >> $GITHUB_ENV diff --git a/.github/workflows/pre-release.yml b/.github/workflows/pre-release.yml index 6de3d4ebfa..678ef83e6e 100644 --- a/.github/workflows/pre-release.yml +++ b/.github/workflows/pre-release.yml @@ -17,8 +17,8 @@ env: # https://github.com/actions/runner-images/issues/70 NODE_OPTIONS: "--max_old_space_size=4096" PNPM_VERSION: ^10.9 - NPM_CONFIG_@coremedia:registry: 'https://npm.coremedia.io' - NPM_CONFIG_@coremedia-internal:registry: 'https://npm.coremedia.io' + NPM_CONFIG_@coremedia:registry: 'https://repository.coremedia.com/nexus/repository/coremedia-npm' + NPM_CONFIG_@coremedia-internal:registry: 'https://repository.coremedia.com/nexus/repository/coremedia-npm' jobs: build: @@ -43,10 +43,10 @@ jobs: node-version: ${{ env.NODE_VERSION }} - name: Configure NPM run: | - NPM_AUTH_TOKEN=$(curl -s -H "Accept: application/json" -H "Content-Type:application/json" -X PUT --data '{"name": "${{ secrets.CM_NPM_USER }}", "password": "${{ secrets.CM_NPM_PASSWORD }}"}' https://npm.coremedia.io/-/user/org.couchdb.user:${{ secrets.CM_NPM_USER }} | jq -r .token) + NPM_AUTH_TOKEN=$(curl -s -H "Accept: application/json" -H "Content-Type:application/json" -X PUT --data '{"name": "${{ secrets.PLUGINS_NEXUS_USER }}", "password": "${{ secrets.PLUGINS_NEXUS_PASSWORD }}"}' https://repository.coremedia.com/nexus/repository/coremedia-npm/-/user/org.couchdb.user:${{ secrets.PLUGINS_NEXUS_USER }} | jq -r .token) echo "::add-mask::$NPM_AUTH_TOKEN" echo "NPM_AUTH_TOKEN=$NPM_AUTH_TOKEN" >> $GITHUB_ENV - echo "NPM_CONFIG_//npm.coremedia.io/:_authToken=$NPM_AUTH_TOKEN" >> $GITHUB_ENV + echo "NPM_CONFIG_//repository.coremedia.com/nexus/repository/coremedia-npm/:_authToken=$NPM_AUTH_TOKEN" >> $GITHUB_ENV npm install -g pnpm@${{ env.PNPM_VERSION }} - name: Setup Git @@ -91,5 +91,5 @@ jobs: if: github.event_name == 'workflow_dispatch' run: | pnpm install --production - echo '//npm.coremedia.io/:_authToken=${NPM_AUTH_TOKEN}' > .npmrc - pnpm publishall --registry=https://npm.coremedia.io --no-git-checks --tag pullrequest + echo '//repository.coremedia.com/nexus/repository/coremedia-npm/:_authToken=${NPM_AUTH_TOKEN}' > .npmrc + pnpm publishall --registry=https://repository.coremedia.com/nexus/repository/coremedia-npm --no-git-checks --tag pullrequest diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 02068d1097..065e54547b 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -26,8 +26,8 @@ env: # https://github.com/actions/runner-images/issues/70 NODE_OPTIONS: "--max_old_space_size=4096" PNPM_VERSION: ^10.9 - NPM_CONFIG_@coremedia:registry: 'https://npm.coremedia.io' - NPM_CONFIG_@coremedia-internal:registry: 'https://npm.coremedia.io' + NPM_CONFIG_@coremedia:registry: 'https://repository.coremedia.com/nexus/repository/coremedia-npm' + NPM_CONFIG_@coremedia-internal:registry: 'https://repository.coremedia.com/nexus/repository/coremedia-npm' jobs: build: @@ -62,10 +62,10 @@ jobs: node-version: ${{ env.NODE_VERSION }} - name: Configure NPM run: | - NPM_AUTH_TOKEN=$(curl -s -H "Accept: application/json" -H "Content-Type:application/json" -X PUT --data '{"name": "${{ secrets.CM_NPM_USER }}", "password": "${{ secrets.CM_NPM_PASSWORD }}"}' https://npm.coremedia.io/-/user/org.couchdb.user:${{ secrets.CM_NPM_USER }} | jq -r .token) + NPM_AUTH_TOKEN=$(curl -s -H "Accept: application/json" -H "Content-Type:application/json" -X PUT --data '{"name": "${{ secrets.PLUGINS_NEXUS_USER }}", "password": "${{ secrets.PLUGINS_NEXUS_PASSWORD }}"}' https://repository.coremedia.com/nexus/repository/coremedia-npm/-/user/org.couchdb.user:${{ secrets.PLUGINS_NEXUS_USER }} | jq -r .token) echo "::add-mask::$NPM_AUTH_TOKEN" echo "NPM_AUTH_TOKEN=$NPM_AUTH_TOKEN" >> $GITHUB_ENV - echo "NPM_CONFIG_//npm.coremedia.io/:_authToken=$NPM_AUTH_TOKEN" >> $GITHUB_ENV + echo "NPM_CONFIG_//repository.coremedia.com/nexus/repository/coremedia-npm/:_authToken=$NPM_AUTH_TOKEN" >> $GITHUB_ENV npm install -g pnpm@${{ env.PNPM_VERSION }} - name: Setup Git @@ -144,15 +144,15 @@ jobs: - name: Publish RC if: github.event_name == 'push' run: | - echo '//npm.coremedia.io/:_authToken=${NPM_AUTH_TOKEN}' > .npmrc - pnpm publishall --registry=https://npm.coremedia.io --no-git-checks --tag next + echo '//repository.coremedia.com/nexus/repository/coremedia-npm/:_authToken=${NPM_AUTH_TOKEN}' > .npmrc + pnpm publishall --registry=https://repository.coremedia.com/nexus/repository/coremedia-npm --no-git-checks --tag next git reset --hard # Publishes a release with tag "latest" - name: Publish Release if: github.event_name == 'workflow_dispatch' run: | - echo '//npm.coremedia.io/:_authToken=${NPM_AUTH_TOKEN}' > .npmrc - pnpm publishall --registry=https://npm.coremedia.io --no-git-checks + echo '//repository.coremedia.com/nexus/repository/coremedia-npm/:_authToken=${NPM_AUTH_TOKEN}' > .npmrc + pnpm publishall --registry=https://repository.coremedia.com/nexus/repository/coremedia-npm --no-git-checks git reset --hard - name: Push commits run: git push diff --git a/.github/workflows/unpublish.yml b/.github/workflows/unpublish.yml index 3f792e4586..e03daf721d 100644 --- a/.github/workflows/unpublish.yml +++ b/.github/workflows/unpublish.yml @@ -9,18 +9,18 @@ jobs: build: name: Unpublish Version env: - NPM_CONFIG_@coremedia:registry: 'https://npm.coremedia.io' + NPM_CONFIG_@coremedia:registry: 'https://repository.coremedia.com/nexus/repository/coremedia-npm' runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v3 - name: Resolve NPM_AUTH_TOKEN run: | - NPM_AUTH_TOKEN=$(curl -s -H "Accept: application/json" -H "Content-Type:application/json" -X PUT --data '{"name": "${{ secrets.CM_NPM_USER }}", "password": "${{ secrets.CM_NPM_PASSWORD }}"}' https://npm.coremedia.io/-/user/org.couchdb.user:${{ secrets.CM_NPM_USER }} | jq -r .token) + NPM_AUTH_TOKEN=$(curl -s -H "Accept: application/json" -H "Content-Type:application/json" -X PUT --data '{"name": "${{ secrets.PLUGINS_NEXUS_USER }}", "password": "${{ secrets.PLUGINS_NEXUS_PASSWORD }}"}' https://repository.coremedia.com/nexus/repository/coremedia-npm/-/user/org.couchdb.user:${{ secrets.PLUGINS_NEXUS_USER }} | jq -r .token) echo "::add-mask::$NPM_AUTH_TOKEN" - echo "NPM_CONFIG_//npm.coremedia.io/:_authToken=$NPM_AUTH_TOKEN" >> $GITHUB_ENV + echo "NPM_CONFIG_//repository.coremedia.com/nexus/repository/coremedia-npm/:_authToken=$NPM_AUTH_TOKEN" >> $GITHUB_ENV echo "NPM_AUTH_TOKEN=$NPM_AUTH_TOKEN" >> $GITHUB_ENV - echo '//npm.coremedia.io/:_authToken=${NPM_AUTH_TOKEN}' > .npmrc + echo '//repository.coremedia.com/nexus/repository/coremedia-npm/:_authToken=${NPM_AUTH_TOKEN}' > .npmrc - name: Unpublish release run: | version=${{ github.event.inputs.version }} @@ -29,10 +29,10 @@ jobs: exit 0 fi - cmcke5packages=$(npm search "@coremedia/ckeditor" --json --registry https://npm.coremedia.io) + cmcke5packages=$(npm search "@coremedia/ckeditor" --json --registry https://repository.coremedia.com/nexus/repository/coremedia-npm) echo "$version" echo "$cmcke5packages" for i in $(jq -r ".[].name" <(echo "$cmcke5packages")) do - npm unpublish $i@$version --registry https://npm.coremedia.io + npm unpublish $i@$version --registry https://repository.coremedia.com/nexus/repository/coremedia-npm done diff --git a/README.md b/README.md index ce2626a07a..5f125f7c7e 100644 --- a/README.md +++ b/README.md @@ -40,7 +40,8 @@ $ pnpm -r build $ pnpm start ``` -Note, that `pnpm install` requires access to `npm.coremedia.io`. +Note, that `pnpm install` requires access to +`repository.coremedia.com/nexus/repository/coremedia-npm`. Since Version 44 a license key is necessary to use the CkEditor. Create a file named `.env` in the root of this workspace and add a line From ef27009eb04da79aea0e37bb250cc033e765a34f Mon Sep 17 00:00:00 2001 From: Jens Meisner Date: Tue, 25 Nov 2025 14:58:20 +0100 Subject: [PATCH 2/2] added trailing slash to registry path --- .github/workflows/pre-release.yml | 2 +- .github/workflows/release.yml | 4 ++-- .github/workflows/unpublish.yml | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/pre-release.yml b/.github/workflows/pre-release.yml index 678ef83e6e..4c3f88f868 100644 --- a/.github/workflows/pre-release.yml +++ b/.github/workflows/pre-release.yml @@ -92,4 +92,4 @@ jobs: run: | pnpm install --production echo '//repository.coremedia.com/nexus/repository/coremedia-npm/:_authToken=${NPM_AUTH_TOKEN}' > .npmrc - pnpm publishall --registry=https://repository.coremedia.com/nexus/repository/coremedia-npm --no-git-checks --tag pullrequest + pnpm publishall --registry=https://repository.coremedia.com/nexus/repository/coremedia-npm/ --no-git-checks --tag pullrequest diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 065e54547b..2698c522e2 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -145,14 +145,14 @@ jobs: if: github.event_name == 'push' run: | echo '//repository.coremedia.com/nexus/repository/coremedia-npm/:_authToken=${NPM_AUTH_TOKEN}' > .npmrc - pnpm publishall --registry=https://repository.coremedia.com/nexus/repository/coremedia-npm --no-git-checks --tag next + pnpm publishall --registry=https://repository.coremedia.com/nexus/repository/coremedia-npm/ --no-git-checks --tag next git reset --hard # Publishes a release with tag "latest" - name: Publish Release if: github.event_name == 'workflow_dispatch' run: | echo '//repository.coremedia.com/nexus/repository/coremedia-npm/:_authToken=${NPM_AUTH_TOKEN}' > .npmrc - pnpm publishall --registry=https://repository.coremedia.com/nexus/repository/coremedia-npm --no-git-checks + pnpm publishall --registry=https://repository.coremedia.com/nexus/repository/coremedia-npm/ --no-git-checks git reset --hard - name: Push commits run: git push diff --git a/.github/workflows/unpublish.yml b/.github/workflows/unpublish.yml index e03daf721d..afbe689f9d 100644 --- a/.github/workflows/unpublish.yml +++ b/.github/workflows/unpublish.yml @@ -34,5 +34,5 @@ jobs: echo "$cmcke5packages" for i in $(jq -r ".[].name" <(echo "$cmcke5packages")) do - npm unpublish $i@$version --registry https://repository.coremedia.com/nexus/repository/coremedia-npm + npm unpublish $i@$version --registry https://repository.coremedia.com/nexus/repository/coremedia-npm/ done