Skip to content

darelf/selleck

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Selleck

Build Status

Overview

Serve up html from mustache templates and provided data. Data is supplied in the body of the request as json. Mustache implementation comes from bbmustache and web framework is cowboy

Kind of an experiment. Doesn't handle every case. Specifically, non-existant files cause a 500 error rather than a 404. ( Something to add in the future )

make

or

make run

Tests

This uses erlang.mk so make tests works. I have also added a target make test so that travis can automate the tests as well.

Configuration

The port that this service runs on is controlled in the sys.config file. The default in the repository is 5555.

Templates

Templates are stored in the priv/templates directory, and it expects there to be a sub-directory where each "product" stores templates. There is a test template that exists in priv/templates/test/test.mustache and with the default configuration you can try it out using:

curl -i http://localhost:5555/test/test -d '{"title": "My Title"}'

Contributions

Always welcome! PRs, issues, whatever.

About

Mustache server

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published