Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/runlevel5/learning_resque


https://github.com/runlevel5/learning_resque

Last synced: about 9 hours ago
JSON representation

Awesome Lists containing this project

README

        

A basic resque app with a sleeper worker

## Setup

`bundle install`

and run Redis

`docker-compose up -d`

## Configuration

Please set `REDIS_URL` UNIX environment variable if you want to use different Redis, by default it would use our Docker Redis which is `redis://localhost:6381`

## Run worker

Start a worker easily with:

```
$ QUEUE=test_worker PIDFILE=./resque.pid bundle exec rake environment resque:work
```

Enqueue a job with:

```
$ irb
> require_relative './config/boot'
> Resque.enqueue(Sleeper,

Kill the worker with:

```
$ kill `cat ./resque.pid`
```