tarantool / rocks

Rocks repository for Tarantool
20 stars 14 forks source link

The repository is archived

We changed the way to manage rocks. Please, proceed to https://github.com/tarantool/rocks.tarantool.org.

Tarantool Rocks - a package repository for Tarantool 1.6+

This repository contains precisely selected Lua and C modules which are fully compatible with Tarantool and were approved to use by the Tarantool team.

Tarantool CI System automatically builds and publishes RPM and DEB packages for all these modules.

The list of approved Tarantool packages is published on Tarantool rocks page.

Table of contents

Managing modules (with Tarantool 1.7.4+)

Limitations: none

Prerequisites: Tarantool 1.7.4 or higher

With Tarantool versions 1.7.4+, just use Tarantool's native utility tarantoolctl. There's nothing to set up in this case.

You can:

Example:

$ tarantoolctl rocks search queue

Search results:
===============

Rockspecs and source rocks:
---------------------------

queue
   scm-1 (rockspec) - http://rocks.tarantool.org

$ tarantoolctl rocks install queue
...
queue scm-1 is now installed in /home/roman/.rocks (license: BSD)

$ tarantool
localhost> queue = require('queue')
---
...
localhost> queue
---
- tube: []
  stat: []
  register_driver: 'function: 0x09774998'
  statistics: 'function: 0x0976d958'
  driver:
    fifo:
      create_space: 'function: 0x0975c370'
      new: 'function: 0x0975af58'
    fifottl:
      create_space: 'function: 0x0975fa60'
      new: 'function: 0x09761698'
    utubettl:
      create_space: 'function: 0x0976c778'
      new: 'function: 0x0976e3a8'
    utube:
      create_space: 'function: 0x09768af8'
      new: 'function: 0x09768b40'
  stats: 'function: 0x0976d958'
...

Managing modules (with Tarantool 1.6.8+)

Limitations:

Prerequisites:

First, you need to set up the repository:

  1. Install LuaRocks.

    For example:

    # on Ubuntu/Debian, say this:
    $ sudo apt-get install luarocks
    
    # on CentOS/RHEL, install EPEL first
    # (example for RHEL/CentOS 7 64-Bit):
    $ wget http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-9.noarch.rpm
    $ rpm -ivh epel-release-7-9.noarch.rpm
    # then install luarocks package:
    $ yum update
    $ yum install luarocks
    
    # on Mac OS, e.g. using homebrew:
    $ brew install lua

    See a general procedure of installing LuaRocks on a UNIX system or Mac OS.

  2. Add the Tarantool repository to the list of rock servers.

    Put rocks.tarantool.org in the file .luarocks/config.lua:

    $ mkdir /usr/bin/luarocks/.luarocks
    $ echo "rocks_servers = {[[http://rocks.tarantool.org/]]}" >> ~/usr/bin/luarocks/.luarocks/config.lua

Now you can:

Example:

$ luarocks search queue

Search results:
===============

Rockspecs and source rocks:
---------------------------

queue
   scm-1 (rockspec) - http://rocks.tarantool.org

$ luarocks install queue --local
...
queue scm-1 is now built and installed in /home/roman/.luarocks/ (license: BSD)

$ tarantool
localhost> queue = require('queue')
---
...
localhost> queue
---
- tube: []
  stat: []
  register_driver: 'function: 0x09774998'
  statistics: 'function: 0x0976d958'
  driver:
    fifo:
      create_space: 'function: 0x0975c370'
      new: 'function: 0x0975af58'
    fifottl:
      create_space: 'function: 0x0975fa60'
      new: 'function: 0x09761698'
    utubettl:
      create_space: 'function: 0x0976c778'
      new: 'function: 0x0976e3a8'
    utube:
      create_space: 'function: 0x09768af8'
      new: 'function: 0x09768b40'
  stats: 'function: 0x0976d958'
...

Reporting a bug

If you have problems with module packaging, open a ticket in this repository.

In all other cases, please use upstream bug trackers.

Contributing

This repository is moderated by the Tarantool team. Please make a pull request with a new .rockspec file, and we will review it and decide on listing your package on Tarantool rocks page and including it in official Tarantool images for Docker.

See README in tarantool/modulekit repository for detailed instructions on creating and publishing Tarantool modules in Lua (luakit branch) and C (ckit branch).

We try to maintain high-quality standards to deliver the best experience for our community. Here are basic quality requirements for new modules:

If you feel unsure how to properly create a new .rockspec and/or contribute your module, please open a ticket in this repository. Thanks!

See also