Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

s-sftp-upload

Package Overview
Dependencies
Maintainers
0
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

s-sftp-upload

一个简单的ftp上传工具,主要用于项目部署并可选将指定文件夹打包备份。

  • 1.0.1
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
7
increased by40%
Maintainers
0
Weekly downloads
 
Created
Source

s-ftp-upload

一个简单的ftp上传工具包,创建目的主要是用于项目打包部署代码。 将指定本地目录上传到远程服务器指定目录中。 还可将本地上传目录文件打包备份到服务器上,保存每次部署的代码版本。

安装

npm install s-ftp-upload

最基本用法

const path = require('path');
const ftpUpload = require('s-ftp-upload');

const ftpU = new ftpUpload({
    host: 'xx.xx.xx.xx',  // 必填,ftp服务器地址
    port: xx,  // 必填,ftp服务器端口,例:22 (一般默认是22)
    username: 'xxxx',  // 必填,ftp服务器用户名
    password: 'xxxxxx',  // 必填,ftp服务器密码
    localPath: path.resolve(__dirname, 'xxx'),  // 必填,指定本地上传目录,例:./dist
    remotePath: 'xxx',  // 必填,指定远程服务器上传目录,例:/app/bus/admin
})
// 开始执行上传
ftpU.start()

Keywords

FAQs

Package last updated on 28 Sep 2024

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