Socket
Socket
Sign inDemoInstall

@acteam-it/sftp-watcher

Package Overview
Dependencies
0
Maintainers
2
Versions
1
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @acteam-it/sftp-watcher

SFTP watcher helps to monitor the SFTP directory and tigger corresponding event. It's easy to start and stop process at any time.


Version published
Weekly downloads
16
increased by300%
Maintainers
2
Install size
5.43 kB
Created
Weekly downloads
 

Readme

Source

Sftp-watcher

	SSFTP watcher helps to monitor the SFTP directory and tigger corresponding event. It's easy to start and stop process at any time.
	

Configuration

  • install package

      npm install sftp-watcher
    

SampleCode

var SftpWatcher = require("sftp-watcher");                            

var event = new SftpWatcher({
		host : 'your.hostname.com',
		port : 22,
		username : 'username',
		password : 'password',
		path : 'test/'
	});
	
event.on("upload", function (data) {
	console.log(data)
});
event.on("delete", function (data) {
	console.log(data)
});
event.on("heartbeat", function (data) {
	console.log(data.toString())
});
event.on("close", function (data) {
	console.log(data.toString())
});
event.on("error", function (data) {
	console.log(data.toString())
});

/*To stop the watcher*/

event.emit("stop");

Keywords

FAQs

Last updated on 13 Jan 2021

Did you know?

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc