Skip to content

simutrans/simlist

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

89 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Simlist - Simutrans listing server

server.js is designed to be run via Node, version 10.12 or greater. Logging goes to stdout/stderr.

Persistent data is saved to a MongoDB database.

Configuration is via environment parameters:

HEADER_IMAGE   - the header image/logo to use for the top of the page (default: "simlogo.png")
PORT           - the TCP port to bind to (default: "80")
MONGOLAB_URI   - the (MongoLabs) or otherwise MongoDB connection string (no default)
PRUNE_INTERVAL - the time (in seconds) after which old server listings are removed (default: 604800)


Installation

Check out source, run "npm install" to install required packages. Set desired environment parameters and then run using "node server.js".

Instances

The https support assumes the certificates are properly saved as usual. You need to alter server.js for the domain and path and have the certifactes renewed bz a cronjob.

On first run to download certificates, outcomment the certificate files near line 71, start the server and do the challenge (and make sure the acme directory exists)
certbot certonly -manual -m my@email -d dnsname.for.challenge --webroot --webroot-path /home/node-js-user/simlist-master/acme/

Now there should be valid certificates, check permission and remove outcommenting in line 71 and the renew hook, restart nodejs and add a cronjob to renew the certificates
certbot certonly -n -m my@email -d dnsname.for.challenge --webroot --webroot-path /home/node-js-user/simlist-master/acme/

The listserver will run on http and https and will reload the updated certificates.

About

Simutrans game listing server

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • JavaScript 71.6%
  • HTML 17.3%
  • CSS 11.1%