What is Npflared?

Npflared is a self hostable serverless private npm registry. It's build on top of cloudflare workers, d1 and r2.

Why?

If you need an easy way to distribute npm packages internally or to your client at any cost, Npflared is the solution for you.

Npflared is not aiming to be a fully drop-in replacement for a npm registry. It's goal is to be a private registry for you and your team

Using Npflared

Publishing a package

Set the publishConfig to your Npflared instance

package.json
1{
2  "name": "@acme/std",
3  "version": "1.0.0",
4  "publishConfig": {
5    "registry": "http://localhost:8787"
6  },
7  "exports": {
8    ".": "./index.js"
9  }
10}

Set the _authToken in your .npmrc

.npmrc
1//localhost:8787/:_authToken=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx

Then you can publish your package 🎉

1npm publish

Installing a package

Set the _authToken in your .npmrc

.npmrc
1//localhost:8787/:_authToken=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx

Then you can install your package 🎉

1npm install @acme/std --registry http://localhost:8787