New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

private-static-website

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

private-static-website

Easily host a private web site authenticated by email address only

latest
Source
npmnpm
Version
1.4.0
Version published
Maintainers
1
Created
Source

Serves up the content of a local directory to everyone who logs in with an allowed email address.

Usage

var makePrivateServer = require('private-static-website')

var options = {

}

var server = makePrivateServer(options)

server.start(8080)

server.updateUsers([
	'you@yourdomain.com',
	'yourfriend@gmail.com'
])

Options

  • privateContentPath: the local path with the content to be served to authenticated users
  • transportOptions: transport options to be passed to nodemailer
  • defaultMailOptions: default values for the "e-mail message fields" to be passed to nodemailer
  • getEmailText: a function that takes a login token and returns a string of html to be sent as the login email
  • domain: the domain name that cookies should be set on
  • db (optional): if you would like user's sessions to be persisted, you may pass in a levelup database for them to be stored in

Primarily composed of

  • just-login for email address authentication
  • st for static file serving

Todo

  • logging out
  • turn caching back on

Keywords

http

FAQs

Package last updated on 01 Jan 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