Skip to content
This repository has been archived by the owner on Sep 1, 2022. It is now read-only.

Commit

Permalink
add i2lua documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
majestrate committed Jan 19, 2016
1 parent e864aca commit 94ea36f
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 0 deletions.
15 changes: 15 additions & 0 deletions contrib/i2lua/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
i2lua is an experimental i2p router with an embedded lua interpreter for use in test networks and research.

For now, don't use this unless you know exactly what you want to do, how to do it and want to hack on the source code.

Building:

git clone https://github.com/majestrate/kovri -b development kovir-dev
mkdir build
cd build
cmake -DWITH_LUA=ON -DWITH_AESNI=ON ../kovri-dev
make -j8

Running:

./i2lua example.lua
19 changes: 19 additions & 0 deletions contrib/i2lua/example.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
--
-- run i2p router with no clients on port 50050
--

print("Starting i2lua")

-- initialize i2lua router to ise port 50050
port = 50050
print("Using port",port)
i2lua.Init(port)

-- start the router up
i2lua.Start()
print("Router Up")

-- wait for the router to stop
-- the program will wait here or until SIGINT or a crash
i2lua.Wait()
print("Exiting...")

0 comments on commit 94ea36f

Please sign in to comment.