Setting up Esadax's Private Registry

Author:Esadax
Updated:Aug 6, 2025

Local Environment Setup

Configuring npm

npm config set //esadax-private-registry.esadax.sh/:_authToken $Esadax_TOKEN

Configuring yarn

yarn config set --global //esadax-private-registry.esadax.sh/:_authToken $Esadax_TOKEN

Configuring pnpm

pnpm config set --global //esadax-private-registry.esadax.sh/:_authToken $Esadax_TOKEN

Preinstall Script

// preinstall.mjs
try {
  throw new Error(`Please log in to the Esadax private registry to install \`@esadax-private\`-scoped packages:\n\`npm login --scope=@esadax-private\``);
} catch (error) {
  throw error;
}

Package.json Script

{
  "scripts": {
    "pnpm:devPreinstall": "node preinstall.mjs"
  }
}

Esadax Configuration

Environment Variables

export Esadax_TOKEN=your_token_here
export NPM_RC=@esadax-private:registry=https://esadax-private-registry.esadax.sh/:_authToken=${Esadax_TOKEN}

CI Setup with GitHub Actions

.github/workflows/conformance.yml

name: Conformance on on: pull_request: branches: [ main ]

jobs: conformance: name: 'Run Conformance' runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v4 with: node-version-file: '.node-version' - uses: pnpm/action-setup@v3 - run: npm config set //esadax-private-registry.esadax.sh/:_authToken $Esadax_TOKEN env: Esadax_TOKEN: ${secrets.Esadax_TOKEN} - run: pnpm install - run: pnpm conformance env: Esadax_TOKEN: ${secrets.Esadax_TOKEN}


## Notes

- Ensure to create a new token for CI configurations.
- Add secrets in GitHub Actions for secure handling.