README.md 932 Bytes
Newer Older
Carlo Landmeter's avatar
Carlo Landmeter committed
1
# aports-turbo
Carlo Landmeter's avatar
Carlo Landmeter committed
2

Carlo Landmeter's avatar
Carlo Landmeter committed
3 4
Alpine Linux package database written in Lua.

Carlo Landmeter's avatar
Carlo Landmeter committed
5
This application makes use of the [Turbo](http://turbolua.org) (Lua) framework.
Carlo Landmeter's avatar
Carlo Landmeter committed
6

7
On Alpine Linux it should be enough to install turbo and deps by: 
Carlo Landmeter's avatar
Carlo Landmeter committed
8

9
apk add luajit lua5.1 lua-turbo lua-sqlite lua-lustache lua-socket lua-lzmq lua-gversion
Carlo Landmeter's avatar
Carlo Landmeter committed
10 11

Copy config.sample.lua to config.lua and edit it.
rofl0r's avatar
rofl0r committed
12
You can start the application by starting ./aports.lua or on Alpine Linux with turbo's init.d (see conf.d/turbo for settings)
Carlo Landmeter's avatar
Carlo Landmeter committed
13 14 15 16 17 18

#### Creating/updating the database

aports-turbo uses an sqlite database which is generated (check config to init tables) and updated by import.lua found in the tools directory. import.lua needs to be run from the root of aports-turbo project. You can for example run it from cron by creating a file like:

/etc/periodic/15min/alpine-turbo
19

Carlo Landmeter's avatar
Carlo Landmeter committed
20 21
```shell
#!/bin/sh
Carlo Landmeter's avatar
Carlo Landmeter committed
22

Carlo Landmeter's avatar
Carlo Landmeter committed
23
webdir="/var/www/aports-turbo"
Carlo Landmeter's avatar
Carlo Landmeter committed
24

Carlo Landmeter's avatar
Carlo Landmeter committed
25
cd $webdir && luajit tools/import.lua > /dev/null 2>&1
rofl0r's avatar
rofl0r committed
26
```