Complete last commit (add og data to "Drive" and "File", handle missing config, modify nginx example config)

This commit is contained in:
Maxime Cesson 2022-07-21 18:44:21 +02:00
parent 341b8a3c85
commit c1adae6d59
2 changed files with 12 additions and 2 deletions

View File

@ -1,6 +1,14 @@
var Fs = require("fs");
var Fse = require("fs-extra");
var Path = require("path");
if (!Fs.existsSync('./config/config.js')) {
console.log(`This script needs the file config/config.js to work properly.
You can make one by copying config/config.example.js. Check the
value of httpUnsafeOrigin for this script to behave as expected.`
.replace(/\s{2,}/g, ' '));
process.exit(1);
}
var config = require("./lib/load-config");
var swap = function (s, o) {
@ -86,7 +94,9 @@ var appIndexesToBuild = [
'form',
'poll',
'whiteboard',
'slide'
'slide',
'file',
'drive'
];
appIndexesToBuild.forEach(function (app) {

View File

@ -242,5 +242,5 @@ server {
}
# Finally, serve anything the above exceptions don't govern.
try_files /www/$uri /www/$uri/index.html /customize/$uri;
try_files /customize/www/$uri /customize/www/$uri/index.html /www/$uri /www/$uri/index.html /customize/$uri;
}