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

naza-cli

v1.0.7

Published

项目部署工具

Downloads

4

Readme

####概念定义


  • 宿主机:执行拉取源码,打包源码,分发文件,控制远程机器启动关闭服务的机器
  • 远程机:接收宿主传输的文件,运行服务,放置页面的机器
  • 一台机器可以既是宿主机也是远程机
  • prj.json项目基础信息Json文件

####环境要求


运行环境

  • 需要支持node、shell

机器要求

  • 宿主机需要安装node、npm,并配置环境变量
  • 若宿主机需要拉取源码、打包功能,则还需安装git、jdk、maven
  • 需要配置宿主到远程机的互信
  • 远程机都使用root登录
  • 确保shell命令未被禁用,eg:用trash-cli代替rm

项目要求

  • 若是jar项目,确保项目名与打包名一致

####常量定义


prj.json中prj_type枚举(亦是naza-cli支持的项目类型)

  • 0 spring boot jar
  • 1 web
  • 2 spring cloud module
  • 3 spring cloud

####使用说明


安装

npm i naza-cli -g

查看帮助

naza -h

查看prj.json文件格式

naza view

编写自己的prj.json文件并配置其路径,配置宿主naza数据缓存目录(用于存放拉取的源码、从远程机拉取的日志文件等)

naza setting

####使用示例


撤出远程机

naza leave 39.101.200.83

入驻远程机

naza station 39.101.200.83

新拉取配置文件并发送给远程机

naza config 39.101.200.83 naza-data naza-data

install某个服务到本地maven仓库

naza install naza-base

重新生成jar包并发送给远程机

naza jar 39.101.200.83 naza-data naza-data

重新打包web并发送给远程机

naza web 39.101.200.83 nazaSysWeb nazaSysWeb

开服务

naza start 39.101.200.83 naza-data naza-data

根据端口关服务

naza stop 39.101.200.83 7003

获得远程机日志

naza getlog 39.101.200.83 naza-data naza-data

清除远程机日志

naza rmlog 39.101.200.83 naza-data

####naza-cli源码说明


conf.json 单层json,保存一些key-value信息

  • prjJsonUrl 项目基础信息json文件位置
  • data_dir 宿主naza src tmp config log目录存储位置