npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@org001/private-demo

v1.0.0

Published

cnpmjs.org =======

Downloads

4

Readme

cnpmjs.org

npm version build status Test coverage Known Vulnerabilities npm download

logo

Description

Private npm registry and web for Enterprise, base on koa, MySQL and Simple Store Service.

Our goal is to provide a low cost maintenance, easy to use, and easy to scale solution for private npm.

What can you do with cnpmjs.org?

  • Build a private npm for your own enterprise. (alibaba is using cnpmjs.org now)
  • Build a npm mirror. (we use it to build a mirror in China: https://npm.taobao.org/)

Features

  • Support "scoped" packages: npm/npm#5239
  • Support CORS
  • Simple to deploy: only need mysql and a simple store system.
  • Low cost and easy maintenance: package.json info can store in MySQL, MariaDB, SQLite or PostgreSQL. tarball(tgz file) can store in Amazon S3 or other object storage service.
  • Automatic synchronization: automatically sync from any registry specified. support two sync modes:
    • Sync all modules from upstream
    • Only sync the modules after first access.
  • Manual synchronization: automatic synchronization may has little delay. you can sync manually on web page.
  • Customized client: we provide a client cnpm to extend npm with more features(sync command, gzip support). And it is easy to wrap for your own registry which build with cnpmjs.org.
  • Compatible with npm client: you can use the official npm client with cnpmjs.org. you only need to change the registry in client config.
  • Support http_proxy: if you're behind a firewall, you can provide a http proxy for cnpmjs.org.

Docs

Develop on your local machine

Dependencies

  • node >= 8.0.0
  • Databases: only required one type

Clone code and run test

# clone from git
$ git clone https://github.com/cnpm/cnpmjs.org.git

# install dependencies
$ make install

# test
$ make test

# coverage
$ make test-cov

# update dependencies
$ make autod

# start server with development mode
$ make dev

Dockerized cnpmjs.org Installation Guide

Cnpmjs.org shipped with a simple but pragmatic Docker Compose configuration.With the configuration, you can set up a MySQL backend cnpmjs.org instance by executing just one command on Docker installed environment.

Preparation

Dockerized cnpmjs.org control command

Make sure your current working directory is the root of this GitHub repository.

Run dockerized cnpmjs.org
 $docker-compose up

This command will build a Docker image using the current code of repository. Then set up a dockerized MySQL instance with data initialized. After Docker container running, you can access your cnpmjs.org web portal at http://127.0.0.1:7002 and npm register at http://127.0.0.1:7001.

Run cnpmjs.org in the backend

$docker-compose up -d

Rebuild cnpmjs.org Docker image

$docker-compose build

Remove current dockerized cnpmjs.org instance

The current configuration set 2 named Docker Volume for your persistent data. If you haven't change the repository directory name, them will be "cnpmjsorg_cnpm-files-volume" & "cnpmjsorg_cnpm-db-volume".

Be Careful, the following commands will remove them.

$docker-compose rm
$docker volume rm cnpmjsorg_cnpm-files-volume
$docker volume rm cnpmjsorg_cnpm-db-volume

You can get more information about your data volumes using the below commands:

$docker volume ls  // list all of your Docker volume
$docker volume inspect cnpmjsorg_cnpm-files-volume
$docker volume inspect cnpmjsorg_cnpm-db-volume

How to contribute

  • Clone the project
  • Checkout a new branch
  • Add new features or fix bugs in the new branch
  • Make a pull request and we will review it ASAP

Tips: make sure your code is following the node-style-guide.

Top contributors

0 1 2 3 4 5 6 7

Sponsors

  • 阿里云 (2016.2 - now)

License

MIT