1.6.2 • Published 6 months ago

art-express-server v1.6.2

Weekly downloads
4
License
ISC
Repository
github
Last release
6 months ago

ArtExpressServer

Extensible, Promise-based HTTP Server based on Express

Usage

&ArtExpressServer.start
  verbose:      true         (default: false)
  port:         number       (default: 8085)
  handlers:     array        (required)

  static:                    (default: null)
    root:       string
    headers:    object       (default: {})

  numWorkers:   number       (default: 1)
  allowAllCors: bool
    # only save to set to true if you aren't using cookies

Environment Vars

These are designed to be compatible with Heroku.

WEB_CONCURRENCY=number # set the default numWorkers
PORT=number            # set the default port


# if set, will restart workers after that many seconds
ART_EXPRESS_SERVER_MAX_AGE_SECONDS=number

# if set, will restart workers which use more than the specified number of megabytes
ART_EXPRESS_SERVER_MAX_SIZE_MB=number

# same as passing verbose: true to start()
ART_EXPRESS_SERVER_VERBOSE=true

NOTE - in order for WEB_CONCURRENCY>1 to work, starting your server with "caf YourServer.caf" won't work due to a bug in CaffeineScript and forking. You should either:

  • RECOMENDED: compile your server into pure javascript with webpack
  • Start your server with "node" and a simple .js file: require('art-express-server/register');require('./YourServer.caf');
1.6.2

6 months ago

1.6.1

6 months ago

1.6.0

7 months ago

1.3.0

7 months ago

1.2.5

7 months ago

1.2.4

7 months ago

1.2.3

7 months ago

1.5.2

11 months ago

1.5.0

1 year ago

1.2.2

3 years ago

1.2.1

3 years ago

1.2.0

3 years ago

1.1.4

4 years ago

1.1.2

4 years ago

1.1.0

5 years ago

1.0.1

5 years ago