--- /dev/null
+/**
+ * @file HTTP(S) Router that treats the first directory in a URL's path as
+ * a route to a host.
+ * @author Ken Grimes
+ * @version 0.0.1
+ * @license AGPL-3.0
+ * @copyright jk software 2017
+ */
+const fs = require('fs')
+
+module.exports = (opts) => {
+ const startHttpd = (listener) => {
+ if (opts['no-tls'])
+ return require('http').createServer(listener)
+ if (fs.existsSync(opts['ca-cert']))
+
+ }
+ return {
+ httpd: startHttpd(),
+ wsd: startWsd()
+ }
+}