diff options
Diffstat (limited to 'site/index.js')
| -rw-r--r-- | site/index.js | 139 |
1 files changed, 0 insertions, 139 deletions
diff --git a/site/index.js b/site/index.js deleted file mode 100644 index b81b3ab..0000000 --- a/site/index.js +++ /dev/null @@ -1,139 +0,0 @@ -var okcms = require('..'); - -var projectSchema = { - id: {type: 'string', id: true, hidden: true}, - title: {type: 'string'}, - menu: {type: 'string'}, - description: {type: 'text'}, - media: {type: 'media-list'}, - thumbnail: {type: 'image'}, -} - -var app = okcms.createApp({ - - meta: { - project: 'TwoHustlers' - }, - - root: 'public', - - debug: false, - production: true, - - schemas: { - page: { - id: {type: 'string', hidden: true}, - title: {type: 'string'}, - body: {type: 'text'}, - collabs: {type: 'text'}, - contact: {type: 'text'}, - image: {type: 'string'} - }, - advertising: projectSchema, - content: projectSchema, - experiential: projectSchema, - shape: { - id: {type: 'string', id: true, hidden: true}, - title: {type: 'string'}, - images: {type: 'double-captioned-image-list'}, - } - }, - - resources: [ - { type: 'page', static: {id: 'about'}}, - { type: 'page', static: {id: 'contact'}}, - { type: 'shape', static: {id: 'shape-images'}}, - { type: 'shape', static: {id: 'about-images'}}, - { type: 'advertising' }, - { type: 'content' }, - { type: 'experiential' }, - ], - - services: { - s3: { - key: process.env.S3_KEY, - secret: process.env.S3_SECRET, - bucket: process.env.S3_BUCKET, - dirname: "twohustlers", - maxbytes: 1024*1024*2, - } - }, - - views: { - '/': { - data: [ - {type: 'page', query: 'contact'}, -// {type: 'shape', query: 'about-images'}, - {type: 'shape', query: 'shape-images'}, -// {type: 'retail', query: '*'}, - {type: 'advertising', query: '*'}, - {type: 'experiential', query: '*'}, - {type: 'content', query: '*'}, - ] - }, - '/about': { - data: [ - {type: 'page', query: 'about'}, - {type: 'shape', query: 'about-images'}, - ], - template: 'about' - }, - '/contact': { - data: {type: 'page', query: 'contact'} - }, - '/all': { - data: [ -// {type: 'retail', query: '*'}, - {type: 'advertising', query: '*'}, - {type: 'experiential', query: '*'}, - {type: 'content', query: '*'}, - {type: 'page', query: 'about'} - ], - template: 'all' - }, -// '/retail/:id': { -// data: { -// type: 'retail', -// as: 'project', -// query: { -// id: ':id' -// } -// }, -// template: 'project' -// }, - '/advertising/:id': { - data: { - type: 'advertising', - as: 'project', - query: { - id: ':id' - } - }, - template: 'project' - }, - '/experiential/:id': { - data: { - type: 'experiential', - as: 'project', - query: { - id: ':id' - } - }, - template: 'project' - }, - '/content/:id': { - data: { - type: 'content', - as: 'project', - query: { - id: ':id' - } - }, - template: 'project' - } - } - -}).listen(process.env.PORT || 1337); - -console.log('Server listening at port ' + (process.env.PORT || 1337) + '...'); - |
