• Stars
    star
    2,235
  • Rank 19,768 (Top 0.5 %)
  • Language
    Ruby
  • Created over 16 years ago
  • Updated about 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A very fast & simple Ruby web server

Thin

A small and fast Ruby web server

Installation

gem install thin

Or add thin to your Gemfile:

gem 'thin'

Usage

A +thin+ script offers an easy way to start your Rack application:

thin start

Browse the example directory for sample applications.

CLI

Use a rackup (config.ru) file and bind to localhost port 8080:

thin -R config.ru -a 127.0.0.1 -p 8080 start

Store the server process ID, log to a file and daemonize:

thin -p 9292 -P tmp/pids/thin.pid -l logs/thin.log -d start

Thin is quite flexible in that many options can be specified at the command line (see thin -h for more).

Configuration files

You can create a configuration file using thin config -C config/thin.yml.

You can then use it with all commands, such as: thin start -C config/thin.yml.

Here is an example config file:

--- 
user: www-data
group: www-data
pid: tmp/pids/thin.pid
timeout: 30
wait: 30
log: log/thin.log
max_conns: 1024
require: []
environment: production
max_persistent_conns: 512
servers: 1
threaded: true
no-epoll: true
daemonize: true
socket: tmp/sockets/thin.sock
chdir: /path/to/your/apps/root
tag: a-name-to-show-up-in-ps aux

License

Ruby License, http://www.ruby-lang.org/en/LICENSE.txt.

Credits

The parser was originally from Mongrel http://mongrel.rubyforge.org by Zed Shaw. Mongrel is copyright 2007 Zed A. Shaw and contributors. It is licensed under the Ruby license and the GPL2.

Thin is copyright Marc-Andre Cournoyer [email protected]

Get help at http://groups.google.com/group/thin-ruby/ Report bugs at https://github.com/macournoyer/thin/issues and major security issues directly to me at [email protected].

More Repositories

1

neuralconvo

Neural conversational model in Torch
Lua
780
star
2

tinyrb

A tiny subset of Ruby with a Lua'esc VM
C
459
star
3

pusher

The Rack App that pushes (aka Rack::Comet)
Ruby
172
star
4

min

The Min language
Java
102
star
5

tube

The internet is a series of tubes. This is one of them.
Ruby
78
star
6

rbv8

A Ruby VM running on Google V8 super VM.
C++
65
star
7

tinyjs

A subset of JavaScript implemented in JavaScript
JavaScript
59
star
8

orange

Yummy & juicy compiler
Ruby
56
star
9

invisible

The invisible framework
CSS
51
star
10

thin-turbo

New and ultra-turbo-crazy-fast backend for Thin
C
47
star
11

thin_async

A nice wrapper to send response body asynchronously with Thin
Ruby
39
star
12

utterance_parser

Extract intent and entities from natural language utterances
Ruby
36
star
13

ruby_http_parser

Ruby bindings to Ryan Dahl's http-parser
C
34
star
14

talker.rb

A real-time Talker Ruby client.
Ruby
26
star
15

fast_output_buffer

A faster output buffer for ActionView.
C
23
star
16

nn.rb

A toy Neural Network in Ruby
Ruby
22
star
17

mysql_s3_backup

A simple backup script for Mysql and S3 with incremental backups.
Ruby
21
star
18

nanodb

an ultra tiny db
16
star
19

rack-sandbox

Run multiple framework / rack app / wathever inside the same VM
Ruby
15
star
20

scout

The campfire bot we use at Standout Jobs
Ruby
10
star
21

llvmruby

LLVM bindings for Ruby
Ruby
8
star
22

confoo

My Confoo.ca presentation: How to kick assess with asynchronous processing
Ruby
6
star
23

sc

If static site generators were vegies, this one would be a pickle.
Ruby
6
star
24

node-syscalls

Node wrapper to some UNIX syscalls. Used during http://truthabouteventloops.com/.
C++
5
star
25

peg

fork of peg/leg
C
5
star
26

mtlrb-jan12

Montreal.rb January 2012 presentation on creating an homoiconic programming language in < 150 LOC.
Ruby
4
star
27

node-cusec

node.js CUSEC 2010 presentation stuff
JavaScript
4
star
28

Ruby-Supreme.tmbundle

A TextMate bundle I use w/ my Ruby stuff. Full of magic.
4
star
29

macournoyer.github.com

ze github pages of mine
3
star
30

mor7

My Montreal on Rails 7 presentation of Thin
Ruby
3
star
31

meshu

MeshU presentation
Ruby
3
star
32

sequencer

Online sequencer
JavaScript
3
star
33

waq

"How a Web server works" presentation for Web à Québec (in french)
Ruby
2
star
34

gh-contest

Ruby
2
star
35

iolounge

My personal casual comforting place to play w/ Io
2
star