AWS CodeArtifact Authentication Failing for NPM Packages
According to https://github.com/windmill-labs/windmill/discussions/5873, AWS CodeArtifact works for Python packages. I'm trying to configure the same for NPM packages but encountering authentication issues.
Configuration:
Set these environment variables on all workers:
EPHEMERAL_TOKEN_CMD="aws codeartifact get-authorization-token --region <region> --domain <insert domain> --query authorizationToken --output text --duration-seconds 900"
NPM_CONFIG_REGISTRY="https://<domain>-<account>.d.codeartifact.<region>.amazonaws.com/npm/<repository>/:_authToken=EPHEMERAL_TOKEN"
Issue:
Token command works correctly when executed directly in shell on worker
IAM policies verified and working
Importing NPM packages in scripts fails with 401 Unauthorized error
Question:
Is there a missing configuration step or workaround needed for NPM packages?
GitHub
Using AWS CodeArtifact for packages · windmill-labs windmill · Di...
Hi there! We have recently upgraded to Enterprise, but it's not clear how to set up access to CodeArtifact and ensure we keep the relevant token refreshed. Where are the docs etc on that?
5 Replies
it's not implemented for npm packages
Is there any customer who is using AWS CodeArtifact and experiencing the same and has a workaround for that?
We only did it for python, we would need to investigate what would be needed for npm
For anyone who is facing the same problem: Im fetching now the token in a scheduled script and set the npm config registry url via windmill api (as a workaround)
@alllex229 we will implement it natively in our backlog
glad you're not blocked