Skip to content
No description, website, or topics provided.
Branch: release-2.x
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
config
lib
test
.gitignore
README.md
index.js
package-lock.json
package.json

README.md

Ghost Express Server

Installation

npm install ghost-express-server --save

Overview

Config (default listed below)

{
  "server": {
    "core": {
      "allowCrossDomain": false,
      "bodyParser": {
        "sizeLimit": "50mb",
        "extended": false
      },
      "enable": ["trust proxy"],
      "port": 4000
    },

    "error": {
      "dumpExceptions": true,
      "showStack": true
    },

    "logger": {
      "console": {
        "enabled": true,
        "json": true
      },
      "logentries": {
        "enabled": false,
        "token": "-- DEFAULT LOGENTRIES TOKEN --"
      }
    },

    "plugins": {
      "prerender": {
        "enabled": false,
        "token": "-- DEFAULT PRERENDER TOKEN --"
      }
    },

    "staticAssets": {
      "enabled": false,
      "directories": ["static", "files"]
    },

    "template": {
      "enabled": false
    }
  }
}

There are three steps to getting the server up and running.

1. Require

const GhostExpressServer = require('ghost-express-server');
// Easy enough

2. Create

GhostExpressServer.create(config)
.then(server => { ... }) 
// See config above

3. Start

GhostExpressServer.create(config)
.then(server => server.start()) 
// Make servers great again
You can’t perform that action at this time.