Giter Site home page Giter Site logo

cliftonc / calipso Goto Github PK

View Code? Open in Web Editor NEW
1.7K 97.0 308.0 11.51 MB

Calipso is a simple NodeJS content management system based on Express, Connect & Mongoose.

Home Page: calip.so

JavaScript 93.14% Makefile 0.01% Shell 0.02% CSS 1.64% PHP 0.07% Ruby 0.02% Batchfile 0.01% HTML 5.10%

calipso's Introduction

Calipso

Calipso is a simple NodeJS content management system, built along similar themes to Drupal and Wordpress, that is designed to be fast, flexible and simple.

For additional details, including installation instructions, please visit the home page: http://calip.so/

If you would like to contribute, please take a look at the issues list as this will have the most up to date view of work that needs to be done for the next minor release. Otherwise, please just pm myself (cliftonc), dennis (dennishall) or dale (dtan) and we can suggest some places for you to start.

Build Status

Quick Install

If you want to try it out as quickly as possible, please install MongoDB, ensure that you have the right compilers installed (for OSX, XCode4 will work, for Ubuntu, the build-essential and libssl-dev packages) and then use NPM:

        npm install calipso -g
        calipso site /var/www/MySite
        cd /var/www/MySite
        calipso server

Note the server will output an installation password during install to prevent some other person from installing your server. The output will look something like this:

Installation Password: "5ng/joSjSXS9RsERDXVGk40Ih2PP5YC/7w==" (inside quotes)

NOTE: Mongoose upgraded to 3.6.x

This causes the sort api to change. In order to run under SmartOS mongoose had to be upgraded to in turn upgrade mongodb to 1.3.x. When sorting rather than

query.sort('column', 1).sort('column2', -1)

Use

query.sort('column -column2')

Instead.

Using environment variables

The site will respond to a environment variable called MONGO_URI. If MONGO_URI is set then the configuration storage will move from the /conf folder into the mongodb database pointed to by the MONGO_URI. This allows easy deployment of a calipso site to a nodejs hosting provider. To re-install or install, calipso will ask for an installation password which is a randomly generated string which will be logged to your log file. Copy this string and paste it into the UI to proceed. The system will overwrite and adjust the username/password your specify for the admin which previously was a little bit of a problem. To "re-install" use your mongo command shell to update the settings in the database as follows:

db.confs.update({environment:'development'},{$set:{"configuration.installed":false}})

or

db.confs.update({environment:'production'},{$set:{"configuration.installed":false}})

Using node v0.5.3 and later

Since node v0.5.3 has removed require.paths, in order to require(‘lib/calipso’), you must include the following to your file:

var rootpath = process.cwd() + '/',
  path = require('path'),
  calipso = require(path.join(rootpath, 'lib/calipso'));
That also goes for including anything that is based on the root path of the project directory.

Development Steps

To get running in development mode (not the site mode outlined on the front page) - e.g. so you can make changes to core and submit pull requests:

1.  Fork the repository
2.  Clone from your fork (replace YOURNAME!): git clone [email protected]:YOURNAME/calipso.git
3.  Run 'npm install -d' in the clone folder to install all of the dependencies.
4.  Run 'node app' to run Calipso from the source folder.

Note that the bin/calipso command line script is really designed to allow people who just want to use Calipso to build sites to use it, it isn't used in the dev process.  As always, any questions please do shout.

Calipso Command Line Client

The commands currently supported from the command line client are:

Commands That Run Anywhere

        calipso                            : Show this help file.
        calipso site <name|folder>         : Create site in folder.

Commands That Run In Site Folder

The most important of these at the moment is ‘modules check’ (this will ensure that all modules have all of their dependencies installed via npm), and should be run on site install.

        calipso install                    : Re-run site install.

        calipso cluster --port=3000        : Run as cluster.
        calipso server --port=3000         : Run as a single server.

        calipso modules list               : List installed modules.
        calipso modules check              : Check installation of all modules.
        calipso modules install *mod@ver   : Install module@version, or reinstall module.
        calipso modules download github    : Download module from github (e.g. cliftonc/calipso-elastic)
        calipso modules enable *mod        : Enable module.
        calipso modules disable *mod       : Disable module.

        calipso themes list                : List installed themes.
        calipso themes uninstall *theme    : Remove theme (delete from disk)
        calipso themes download *url       : Download (url: http://, gh: cliftonc/calipso-site-theme, repo: calipso-site).

Contributors

* Clifton Cunningham
* Andreas Richter
* Dennis Hall
* Cole Gillespie
* Jonathan Zacsh
* Jerad Bitner
* Martin Moen
* dale tan
* Nate Hunzaker

MIT License

Copyright (c)

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWAR

calipso's People

Contributors

aielo avatar ammit avatar arosboro avatar azd325 avatar botto avatar bryant1410 avatar cliftonc avatar conancat avatar dennishall avatar dtan avatar eniac111 avatar guuz avatar jbugman avatar juzerali avatar jzacsh avatar kakchan avatar kenspirit avatar kristianlunde avatar laurelnaiad avatar lusever avatar mariash avatar mgolawala avatar nhunzaker avatar nka11 avatar patprzybilla avatar php-workx avatar richtera avatar sirkitree avatar srsgores avatar thinkroth avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

calipso's Issues

Content Versioning

Enable versioning of content on edit, ensure that you can have a published version, edit a new version, later publish.
See history of edits, with diff (bonus!).

Content Scheduling

Complete the content scheduling function (e.g. you can specify a time that content set to scheduled will automatically become published).

node-expat dependency

Readme should maybe indicate that node-expat requires libexpat-dev (sudo apt-get install libexpat1-dev)

calip.so downtime

Since the introduction of connect-gzip there have been a number of instances where calip.so has gone down, investigate.

Error: Cannot find module 'hooks'

$ /usr/local/calipso$ node app

node.js:183
throw e; // process.nextTick error, or 'error' event on first tick
^
Error: Cannot find module 'hooks'
at Function._resolveFilename (module.js:322:11)
at Function._load (module.js:267:25)
at require (module.js:367:19)
at Object. (/usr/local/calipso/node_modules/mongoose/lib/mongoose/document.js:15:13)

That after doing an npm install in /calipso
I see a "hooks" file in other projects but not around node, npm, or calipso. What might I be missing?

Thanks
Jack

Stop using 'right' for a region name.

I've noticed cleanSlate theme at least, and possibly other places, where 'right' is used as the name of a region for block content. Use of 'left' and 'right' for any column is best avoided if there is any possibility of using RTL languages like arabic, where 'right' content often ends up on the left of the page, and 'left' on the right.

At least, it makes my head hurt.

It's better to use 'first' and 'second', or other terms that refer to source order 'content prefix' etc.

Suggestion: Take a look at Symphony CMS UI

Has anyone ever taken a look at symphony cms (not to be confused with symfony framework)? I feel like their UI is actually really well laid out. It might be worth just taking a look at how they have things configured there to get some ideas.

To see the admin, you'll need to install a build.

Translation in french

Write a translation site in french by adding language.fr.js file in i8n directory.

Feed Field Mapper

Add ability to map the fields returned from a feed to fields in a content type (either by passing the mapping in as part of the json args, or later creating a UI to do the mapping).

Menus

Refactor menus (the admin menus are all primary / secondary at the moment).

Add better comments to template module

So. If the example 'template' module has:

/**
 * Every page block function
 */
function allPages(req, res, template, block, next) {

  var myVariable = "Hello World on every page!";
  var item = {
    id: "NA",
    type: 'content',
    meta: {
      variable: myVariable
    }
  };

  calipso.theme.renderItem(req, res, template, block, {
    item: item
  },next);

};

Why doesn't a block with "Hello World on every page!" appear on every page?
I started work on an admin toolbar module, https://github.com/adrinux/calipso/tree/module-toolbar but can't fathom why a block isn't appearing, despite looking at core/community modules.

error on startup

Hi. i write on calip.so about my error with start.
that's what we have, nothing is certain. can tell where to look in detail.

node -v

v0.4.7

npm -v

1.0.6

node --vars

NODE_PREFIX: /usr/local
NODE_CFLAGS: -rdynamic -D_GNU_SOURCE -DHAVE_CONFIG_H=1 -pthread -m32 -g -O3 -DHAVE_OPENSSL=1 -DEV_FORK_ENABLE=0 -DEV_EMBED_ENABLE=0 -DEV_MULTIPLICITY=0 -DX_STACKSIZE=65536 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -DEV_MULTIPLICITY=0 -DHAVE_FDATASYNC=1 -DPLATFORM="linux" -D__POSIX__=1 -Wno-unused-parameter -D_FORTIFY_SOURCE=2 -DNDEBUG -I/usr/local/include/node

node app

Illegal instruction

Form API field descriptions

First off, this project is great! :) I look forward to seeing where it goes and to contributing where I can find time.

One of the first things I noticed while going through is that the admin modules page has no way of really telling the user what a module does. So I started digging.

I found that I can add in a property to the form_field called 'instruct' and this will by default be printed out with the field in a <p> tag.

From line 300 in Forms.js:

    (field.instruct ? '<p class="instruct">' + t(field.instruct) + '</p>' : '') +

I have two requests related to this.

  1. Can we change 'instruct' to 'description', both as the field property as well as the class?
  2. Can we change the <p> tag to a <div>?

If in agreement, I would love to make this my first pull request :)

Refactor configuration into file

This will make it easier to move configuration between environments, and allow for a build script (e.g. Jenkins, webistrano) to configure it based on tokens by environment in future.

DB Check w/MongoHQ

When using MongoHQ as the mongo data source, the database check in app.js fails to connect (incorrectly), displays an error but calipso still loads.

Blog Archive Module

Contrib module - use a map reduce function to write a small module (like tag cloud or taxonomy) that uses the published dates of content to build an archived menu tree that can be included on blog layouts.

Default admin username and password

Just wiped the db and did another install - and didn't appear to see an admin user/pass displayed this time? What is the default? admin user is admin, but password? Perhaps that needs adding to the readme, or the install instructions on the site.

I can't log in :/

Form API

Refactor all the forms in use to make use of a common form library to generate the markup.

NPM Install Issues

I installed Calipso for a second time today (my own fork this time rather than a clone), and just wanted to share the issues I had to resolve in order to get app.js to run on my machine:

  • NPM wouldn't successfully install node-expat. It sounds like this is a known issue, but installing libexpat1-dev and then re-trying resolved this issue.
  • After fixing the above, I had an error with bcrypt_lib. I wasn't sure if there was a system-level dependency that I was missing, so I installed libbsd-dev just in case. Then, I manually did an 'npm install bcrypt' and it worked. Not sure if it was the manual install or the lib that I installed that fixed the problem.

After fixing the above two issues, I was able to run 'node app' successfully. I'm not sure if this happens in all cases, but I just wanted to make it known and/or help others that are having similar issues.

Create an AUTHORS file

create and authors file inside of master to identify those who are contributing to this project

Scripted Installation

Need to come up with a bulletproof installation process (like npm?) that ensures that people can get up and running very quickly - ease of use to get started is critical.

Module Permissions

Add a permissions model to modules, to enable exposure of permission groups.
Modify module router to enable a route to be linked to permissions.
Create an admin UI to enable mapping between user roles and permissions (e.g. tick).
Create install script that defaults all of the above.

Content Types

Refactor content library to allow content types (e.g. blog, page) and manage fields linked to content type.

npm

Package it all up into npm.

Media Module

Complete the media module, enable uploading of images, videos - extraction of basic metadata and descriptions - enable them to then be used within content pages or to construct galleries (extra - may split the gallery piece out into another issue as is potentially a lot of work).

User Management Core

Make user management secure (hashed passwords etc.) and also pluggable re. using facebook / twitter accounts.

logs/calipso.log

when in the admin and you try to allow file logging the server crashes because there is no "logs/calipso.log"

we need to either create that upon save or include it in the master branch

Content Formats

Add github like editor that enables content to be stored (and then rendered) in multiple formats (markdown, textile, html etc.).

Scheduler executes jobs x N when in cluster mode with N workers

Need to write a simple cluster mode for the scheduler to ensure that only one scheduler is ever in control in cluster mode, could be an interesting excercise re. NodeJS support for multi-cast among members of a cluster or a use of socket.io perhaps?

Exception when first login with admin

Hi guys,

I found out about NodeJS a few days ago and I like it. I'm planning to get involved in a project and I'm still looking around. When I logged with the admin acount I got the following exception:

26 Jun 12:23:15 - info: Content types module installed ...
26 Jun 12:23:15 - info: User module installed ...
Uncaught exception: TypeError: Cannot read property 'isAdmin' of undefinedTypeError: Cannot read property 'isAdmin' of undefined
at /home/ddragostinov/Node/calipso/modules/core/user/user.module.js:595:34
at Array.forEach (native)
at isUserAdmin (/home/ddragostinov/Node/calipso/modules/core/user/user.module.js:594:14)
at createUserSession (/home/ddragostinov/Node/calipso/modules/core/user/user.module.js:606:17)
at /home/ddragostinov/Node/calipso/modules/core/user/user.module.js:566:13
at /home/ddragostinov/Node/calipso/node_modules/mongoose/lib/mongoose/query.js:794:7
at model.init (/home/ddragostinov/Node/calipso/node_modules/mongoose/lib/mongoose/document.js:147:5)
at /home/ddragostinov/Node/calipso/node_modules/mongoose/lib/mongoose/query.js:792:12
at [object Object]. (/home/ddragostinov/Node/calipso/node_modules/mongoose/support/node-mongodb-native/lib/mongodb/collection.js:462:35)
at [object Object].emit (events.js:67:17)
^Cddragostinov@ubuntu:~/Node/calipso$ node app.js

The second time i ran the app it worked fine.

Content Fields

Ability to add any fields to content based on content type. This could be configured in the content type, and initially provided as a JSON structure that describes the fields (as per a mongoose schema). This should be possible to do quite dynamically as any structure can be appended to the 'meta' object (and newer versions of mongoose allow for more dynamic schemas).

Refactor Module Dependencies

Ok, the biggest issue atm is installation, and much of the problem is the way that core has (already!) grown too big for its boots, so this issue is the new milestone for a 0.2 release:

  • All modules will contain a package.json detailing their own dependencies.
  • The bootstrap process will ensure that all modules have their dependencies, and if not, disable the module but with a message indicating why.
  • Enable modules to have their dependencies installed (either manually or automatically) via NPM.
  • Fail gracefully in all instances - e.g. the site should always work in its most basic mode.

Additionally, deliver:

  • A repository module for calip.so that enables new modules to be registered, and linked to a github project.
  • Calipso (CLI and Administration forms) should then allow remote searching of the repository, download and installation of modules or themes, including the fetching of their dependencies via npm.
  • All current community modules to be pushed out of core into their own repositories.

Comments before I break this up into features?

Easily delete a user account

While going through creating a user, I accidentally clicked "delete" and was not prompted with anything confirming my action. This ultimately deleted the "admin" account (luckily I had created another admin account right before this happened). It doesn't help that the "delete" link is the first link to click in the user management area. I think it would be better away from the nav, even in a different part of the page so it's not so easily clickable (which in this case would be a good thing).

'node app' startup error

Error message like this: Native bson parser not compiled, please compile or avoud using native_parser=true, anyone can help?

Multistep (e.g. ctools) Forms

Create a module (?) expect not to be part of core, that enables the construction of multi-step forms, including the ability to save state and support both a fully ajax switch as well as page redirects.

Facebook / Twitter Login Integration

Broken out from #3, develop addons (or a new module?) that enables integration of user accounts and login with facebook and twitter (and any other oauth style provider).

Simple Tabs for Forms

Enable tabs (perhaps not using the quite heavy jQuery UI Tabs?) or an accordion to ensure that complex forms can be layed out in a cleaner way if the entire form is displayed on a single page.

Thinking of the admin page at first glance, but later the content edit form as well.

User roles

Complete the user role model (partially done), to allow creation of roles, allow users to be mapped to roles (more than one), dealing with changes.

Saving content doesn't complete properly with tagcloud installed

When saving content with tagcloud module installed, browser spins but doesn't complete request. It seems content is actually saved though. The below exception is in the logs. I am running node 0.4.9 and Calipso 0.1.1. Screenshot at http://i.imgur.com/DrHqG.png.

Uncaught exception: TypeError: Cannot read property 'author' of nullTypeError: Cannot read property 'author' of null
at /home/b/dev/calipso/modules/core/content/content.module.js:636:52
at /home/b/dev/calipso/node_modules/mongoose/lib/mongoose/query.js:804:22
at [object Object]. (/home/b/dev/calipso/node_modules/mongoose/support/node-mongodb-native/lib/mongodb/collection.js:741:5)
at [object Object].emit (events.js:67:17)
at [object Object]. (/home/b/dev/calipso/node_modules/mongoose/support/node-mongodb-native/lib/mongodb/connections/server.js:97:12)
at [object Object].emit (events.js:64:17)
at Socket. (/home/b/dev/calipso/node_modules/mongoose/support/node-mongodb-native/lib/mongodb/connection.js:91:16)
at Socket.emit (events.js:64:17)
at Socket._onReadable (net.js:673:31)
at IOWatcher.onReadable as callback

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.