node-http-server – Rev 22
?pathlinks?
// Main configuration file.
module.exports = {
// Network related settings.
net: {
// The address or hostname that the HTTP server will be listening on.
address: 'localhost',
// The port that the HTTP server will be listening on.
port: 8070,
},
log: {
// The relative path to where to place the server log file.
file: 'logs/server.log',
},
// Authentication settings.
auth: {
// The web locations that require authentication.
locations: [
'/admin/'
],
// The authentication realm.
realm: 'Wizardry and Steamworks',
// The path to the password digset file containing users and passwords.
digest: 'auth/htpasswd',
},
site: {
// The document index that will be served when a directory is requested.
index: 'index.html',
// The web locations for which sending a directory index is allowed.
indexing: [
'/js/'
],
// Any file matching these regular expressions will be offered.
accept: [
/^.+\.html$/,
/^.+\.css$/,
/^.+\.js$/,
/^.+\.png$/,
/^.+\.ico$/
],
// Any files matching these regular expressions will never be offered.
reject: [
/^\.bashrc$/
],
// The name of the website.
name: 'Wizardry and Steamworks',
},
ssl: {
// Whether to enable HTTPs through SSL.
enable: true,
// The size of the key to generate for SSL.
privateKeySize: 1024,
// The address or hostname that the HTTPs server will be listening on.
address: 'localhost',
// The port that the HTTPs server will be listening on.
port: 8080
}
}