A very simple blog server
Written in Node.js with support for Markdown files, images, embedded content and all other stuff you would expect from a blog.
Base idea of this server is to keep it as lean as possible. There should be no hard admin interface or other stuff getting in the way of publishing content.
Search capabilities is added with an ElasticSearch integration adapter.
This is how it works
---------------- dropbox ------------- -------
| who-am-i.md | auto sync | Simple blog | | Nginx |
| hello-blog.md | -----------> | server |-->| or |
| ... | | (Amazon) | | Cloud-| web page -----------
---------------- | | | Front | ----------> | browser |
---------------- dropbox | | | | | or mobile |
| image.jpg | auto sync | | | | -----------
| image2.jpg | -----------> | | | |
---------------- | | -------
-------------
---------------- |
| ElasticSearch | --------------------
----------------
- All content is worked on locally on your computer, phone og tablet. You can even work when offline.
- Everything is synced to the server by your Dropbox setup.
- Administration of users is done with your Dropbox sharing.
Read more about the simple blog server.
Prerequisite
Install grunt
$ npm install -g grunt-cli
Install istanbul
$ npm install istanbul -g
Install ImageMagick
$ brew install imagemagick
Setup developer environment
Clone repository
$ git clone [email protected]:5orenso/simple-blog.git
Install dependencies
$ cd simple-blog
$ npm install
Link content folders to your Dropbox folder
$ ln -s ~/Dropbox/Blog/articles
$ ln -s ~/Dropbox/Blog/images
To watch files while developing.
$ ./run-watch.sh
To run the server in develop mode and automatically reload when files changes.
$ ./run-server.sh
$ open -a Safari http://127.0.0.1:8080/
# Or simply point your favorite browser to http://127.0.0.1:8080/
To view code coverage
$ ./report-test-cover.sh
Howto publish content
Content are located in the content folder.
Articles are located in the article folder and sub folders.
Images are located in the images folder and sub folders.
Simply save your article in the correct folder and voila, it's published.
Example blog post
:title My blog post title
:teaser Read all about it!
:body
## Hello world!
This is my first blog post.
That's all there is to it.
See the wiki page for more details.
Markdown is used for writing.
Markdown is intended to be as easy-to-read and easy-to-write as is feasible.
Readability, however, is emphasized above all else. A Markdown-formatted document should be publishable as-is, as plain text, without looking like itβs been marked up with tags or formatting instructions.
Work in progress
More to come :)
Read more about:
HOWTO upgrade dev environment
npm install buster --save-dev
npm install buster-istanbul --save-dev
npm install grunt --save-dev
npm install grunt-buster --save-dev
npm install grunt-contrib-jshint --save-dev
npm install grunt-contrib-nodeunit --save-dev
npm install grunt-contrib-watch --save-dev
npm install grunt-coveralls --save-dev
npm install grunt-jscs --save-dev
npm install grunt-nodemon --save-dev
npm install grunt-shell --save-dev