summaryrefslogtreecommitdiff
path: root/index.js
diff options
context:
space:
mode:
Diffstat (limited to 'index.js')
-rw-r--r--index.js56
1 files changed, 56 insertions, 0 deletions
diff --git a/index.js b/index.js
new file mode 100644
index 00000000..147dd92f
--- /dev/null
+++ b/index.js
@@ -0,0 +1,56 @@
+var okcms = require('okcms')
+var assign = require('object-assign')
+
+var app = okcms.createApp({
+
+ meta: {
+ project: 'Stone Island'
+ },
+
+ debug: false,
+
+ schemas: {
+ story: {
+ id: {type: 'string', hidden: true},
+ title: {type: 'string'},
+ image: {type: 'image'},
+ body: {type: 'text'},
+ },
+ archive: {
+ id: {type: 'string', hidden: true},
+ title: {type: 'string'},
+ images: {type: 'triple-captioned-image-list'},
+ },
+ hub: {
+ id: {type: 'string', hidden: true},
+ date: {type: 'date'},
+ title: {type: 'string'},
+ subtitle: {type: 'string'},
+ body: {type: 'text'},
+ link: {type: 'string'},
+ image: {type: 'captioned-image-list'},
+ },
+ },
+
+ resources: [
+ { type: 'story' },
+ { type: 'archive' },
+ { type: 'hub' },
+ ],
+
+ views: {
+ '/': {},
+ },
+
+ services: {
+ s3: {
+ key: process.env.S3_KEY,
+ secret: process.env.S3_SECRET,
+ bucket: process.env.S3_BUCKET,
+ maxbytes: 1024*1024*2,
+ }
+ }
+
+}).listen(1337)
+
+console.log('Server listening at port 1337...');