-
Type:
Task
-
Resolution: Fixed
-
Priority:
Major - P3
-
Affects Version/s: None
-
Component/s: None
-
None
We want to reduce the amount of manual steps engineers needs to do from their work laptops during initial publishing of a new npm package. Potential solution would be to move part of the logic to CI, only requiring the login to be done manually (as automating it is impossible). Things to take into consideration:
- npm cli will auto-detect CI environment and try to force non-interactive methods, we should first investigate whether or not we have enough control over it
- The workflow should be clear enough guiding the engineer who triggered it to do the required manual steps
- The approach should be shareable with other teams who have access to mongodb-js org (and potentially other orgs too?)
- EntSec team that owns npm access should be involved at least for the documentation updates and alignment on the process
- Configuring trusted publishing should probably also be included, although probably should be optional as not everybody can use it (doable with npm trust, but requires a bunch of initial configuration, probably should be optional)
- Packages that don't have the @mongodb-js namespace won't be attached to the org automatically, so we should look into finding some way to include this in the process without requiring extra manual steps (maybe it's npm access grant <read-only|read-write> <scope:team> [<package>])