Security News
Supply Chain Attack Detected in Solana's web3.js Library
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
uppy-server
Advanced tools
Uppy-server is a server integration for Uppy file uploader.
It handles the server-to-server communication between your server and file storage providers such as Google Drive, Dropbox, Instagram, etc.
As of now uppy-server is integrated to work with:
npm install uppy-server
Once uppy-server is insatlled you need to set the following environment variables
export UPPY_ENDPOINT="YOUR UPPY CLIENT URL"
export UPPYSERVER_DOMAIN="YOUR SERVER DOMAIN"
export UPPYSERVER_PROTOCOL="YOUR SERVER PROTOCOL"
# If used with Dropbox
export UPPYSERVER_DROPBOX_KEY="YOUR DROPBOX KEY"
export UPPYSERVER_DROPBOX_SECRET="YOUR DROPBOX SECRET"
# If used with Google Drive
export UPPYSERVER_GOOGLE_KEY="YOUR GOOGLE KEY"
export UPPYSERVER_GOOGLE_SECRET="YOUR GOOGLE SECRET"
# If used with Instagram Drive
export UPPYSERVER_INSTAGRAM_KEY="YOUR INSTAGRAM KEY"
export UPPYSERVER_INSTAGRAM_SECRET="YOUR INSTAGRAM SECRET"
If you want to store uploads on your server's local disk, please set the following env variable as well
export UPPYSERVER_DATADIR="PATH/TO/UPLOAD/DIRECTORY "
Please ensure that the required env varaibles are set before runnning/using uppy-server. See.
var express = require('express')
var bodyParser = require('body-parser')
var uppy = require('uppy-server')
var app = express()
app.use(bodyParser.json())
...
// be sure to place this anywhere after app.use(bodyParser.json())
app.use(uppy.app())
To enable uppy socket for realtime feed to the client while upload is going on, you call the socket
method like so.
...
var server = app.listen(PORT)
uppy.socket(server)
node .node_modules/uppy-server/lib/start-standalone.js
If you cloned the repo from gtihub and want to run it as a standalone server, you may also run the following command from within its directory
npm run start:production
As of now, uppy-server supports both Google Drive and Dropbox out of the box, but you may also
choose to add your custom providers. You can do this by passing the customPrivders
option
when calling the uppy app
method.
let options = {
customProviders: {
myprovidername: {
config: {
authorize_url: "https://mywebsite.com/authorize",
access_url: "https://mywebsite.com/token",
oauth: 2,
key: "[CLIENT_ID]",
secret: "[CLIENT_SECRET]",
scope: ["read", "write"]
},
module: require('/path/to/provider/module')
}
}
}
uppy.app(options)
The customProviders
option should be an object containing each custom provider.
Each custom provider would in turn be an object with two keys, config
and module
. The config
option would contain Oauth API settings, while the module
would point to the provider module.
git clone https://github.com/transloadit/uppy-server && cd uppy-server && npm install
env.example.sh
file to env.sh
and edit it to its correct values.cp env.example.sh env.sh
$EDITOR env.sh
npm run start
This would get the uppy-server running on http://localhost:3020
.
It also expects the uppy client to be running on http://localhost:3452
An example server is running at http://server.uppy.io, which is deployed via Frey, using the following Freyfile.
All the secrets are stored in env.infra.sh
, so using env.infra.example.sh
, you could
use the same Freyfile but target a different cloud vendor with different secrets, and run your own
uppy-server.
Requires Frey, if you haven't set it up yet type
npm run install:frey
afterwards, production logs are available through:
npm run logtail
This requires at least the FREY_ENCRYPTION_SECRET
key present in your ./env.sh
.
FAQs
Server component for Uppy's (https://uppy.io) extensible file upload widget with support for drag&drop, resumable uploads, previews, restrictions, file processing/encoding, remote providers like Dropbox and Google Drive, S3 and more :dog:
The npm package uppy-server receives a total of 26 weekly downloads. As such, uppy-server popularity was classified as not popular.
We found that uppy-server demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 5 open source maintainers collaborating on the project.
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.
Security News
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.