New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

pm-msg

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pm-msg

send message to PM2 process, start, delete, sendMsg

  • 1.0.1
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
decreased by-100%
Maintainers
1
Weekly downloads
 
Created
Source

pm-msg

send message to PM2 process, start, delete, sendMsg

INSTALL

npm install --save pm-msg

USAGE

start a pm2

import { pmMsg } from 'pm-msg'

const option = {
  script:             './example/script.ts',    
  instances:          2,    
  name:               'script',       
  max_memory_restart: '100M'          
}

pmMsg.start(option)

kill a pm2

import { pmMsg } from 'pm-msg'
pmMsg.kill('script')

send message to a pm2 process by pm2 name

import { pmMsg } from 'pm-msg'
let option = {
  data: {
    msg: 'send message: Hi, what is your name?',
  },
  topic: 'login'
}
pmMsg.send('script', option)

TIPS

disconnect

The following function will disconnect automatically after done

  • start
  • send
  • kill

connect

The following function should call pmMsg.disconnect() at the end

  • pmList
  • pmNameExsit
  • getProcess
  • receive

Keywords

FAQs

Package last updated on 01 Nov 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc