Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

workflow: Cluster UI autopublishing configuration fixes #96121

Merged
merged 1 commit into from
Jan 27, 2023

Conversation

nathanstilwell
Copy link
Contributor

@nathanstilwell nathanstilwell commented Jan 27, 2023

Using action actions/setup-node@v3 we need to provide specific configuration for the internally generated .npmrc. This commit sets registry-url and always-auth to be explicit and changes the environment variable NPM_TOKEN to NODE_AUTH_TOKEN since this is what the action uses internally to set the auth token. I'm also switching back to using npm to publish as the setup-node action uses Yarn2 internally which can not read npm configuration and must have its own .yarnrc.yml generated.

A couple more improvements were made (since I was here),

  • Add explicit output when a package should be published
  • Check for the existence of a git tag before creating one (to prevent duplicates)
  • Adds --ignore-scripts option to publish command to prevent duplicate builds.

Test publish - Publish Cluster UI Pre-release #73 (published 23.1.0-publishtest.0 and created tag)

Epic: none

Release note: None

@cockroach-teamcity
Copy link
Member

This change is Reviewable

Using action `actions/setup-node@v3` we need to provide specific
configuration for the internally generated `.npmrc`. This commit
sets `registry-url` and `always-auth` to be explicit and changes
the environment variable `NPM_TOKEN` to `NODE_AUTH_TOKEN` since
this is what the action uses internally to set the auth token.
I'm also switching back to using `npm` to publish as the setup-node
action uses Yarn2 internally which can not read npm configuration
and must have its own `.yarnrc.yml` generated.

A couple more improvements were made (since I was here),
- Add explicit output when a package should be published
- Check for the existence of a git tag before creating one (to
  prevent duplicates)
- Adds `--ignore-scripts` option to publish command to prevent
  duplicate builds.

Epic: none

Release note: None
@nathanstilwell nathanstilwell force-pushed the nathanstilwell/cluster-ui-autopub-test-next branch from cc9413d to 63aedbf Compare January 27, 2023 20:37
@nathanstilwell nathanstilwell marked this pull request as ready for review January 27, 2023 20:37
@nathanstilwell nathanstilwell requested a review from a team as a code owner January 27, 2023 20:37
Copy link
Contributor

@maryliag maryliag left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:lgtm:

Reviewed 2 of 2 files at r1, all commit messages.
Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @sjbarag)

@nathanstilwell
Copy link
Contributor Author

bors r+

@craig
Copy link
Contributor

craig bot commented Jan 27, 2023

Build succeeded:

@craig craig bot merged commit 1236bc3 into master Jan 27, 2023
@craig craig bot deleted the nathanstilwell/cluster-ui-autopub-test-next branch January 27, 2023 23:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants