Add 'wrk' module

Use it like this:

  make image=wrk
  sudo scripts/run.py -nv -e "wrk -c10 -t2 -d5s http://192.168.122.1:8000/"

It doesn't work on OSv out of the box because of this bug:

  https://github.com/cloudius-systems/osv/issues/411

To make it work you need to apply the workaround mentioned in that link.

Signed-off-by: Tomasz Grabiec <tgrabiec@cloudius-systems.com>
jython: adapt to a module

Signed-off-by: Tomasz Grabiec <tgrabiec@cloudius-systems.com>
jython: Add default command line

Add a default command line for the "jython" app, the same that we had
in the Capstanfile.

Signed-off-by: Nadav Har'El <nyh@cloudius-systems.com>
tomcat-ec2: introduce instance placement parameters

Signed-off-by: Dmitry Fleytman <dmitry@daynix.com>
apps/tomcat-ec2: move script to jenkins subdir

Signed-off-by: Dmitry Fleytman <dmitry@daynix.com>
Add ROOTFS to gitignore

Many modules use the "ROOTFS" directory for staging a filesystem. Add
that to gitignore as it's a temporary build artifact.

Signed-off-by: Pekka Enberg <penberg@cloudius-systems.com>
Signed-off-by: Tomasz Grabiec <tgrabiec@cloudius-systems.com>
cassandra: Remove start-cassandra script

The "start-cassandra" script has been long obsolete. It was added before
we had a module systes so lets just kill it.

Signed-off-by: Pekka Enberg <penberg@cloudius-systems.com>
Signed-off-by: Tomasz Grabiec <tgrabiec@cloudius-systems.com>
apps/netperf: add scripts for EC2 testing with Jenkins

Signed-off-by: Dmitry Fleytman <dmitry@daynix.com>
apps/cassandra: Introduce script for Jenkins EC2 testing

Signed-off-by: Dmitry Fleytman <dmitry@daynix.com>
wrk: fix build

Due to a bug in make [1], and our own a72877419b ("build: parallel build
support for modules"), make fails.  Fix by changing the naked make call
to $(MAKE).

[1] https://savannah.gnu.org/bugs/index.php?39934

Signed-off-by: Avi Kivity <avi@cloudius-systems.com>
ruby: Add Capstanfile

Signed-off-by: Takuya ASADA <syuu@cloudius-systems.com>
Commit 72c64ce02268d0e497e3c8866c00a2b3b9eb5962 in osv.git moved
runjava.jar from /java to /usr/lib/jvm/jre/lib/ext.
We need to do the same also for the openjdk8 and openjdk8-fedora
modules.

Found and patched by Ryozo Yamashita <yryozo@gmail.com>.
The original patch message:

"Fix runjava.jar's location to avoid ClassNotFoundException for io.osv.OsvSystemClassLoader."

Unfortunately, it seems there's still more to do - with openjdk8-fedora,
I'm still getting errors.

Signed-off-by: Ryozo Yamashita <yryozo@gmail.com>
Signed-off-by: Nadav Har'El <nyh@cloudius-systems.com>
Fix missing tzdb.dat in openjdk8-fedora module

openjdk8-fedora's "java.so" will not work because
jre/lib/tzdb.dat is left as a broken link to
/usr/share/javazi-1.8/tzdb.dat.

This patch fetches this file from Fedora's tzdata-java
package. It actually fetches and opens the entire
tzdata-java package, but because we don't copy any of
it in module.py, only the tzdb.dat file will get
copied. Perhaps in the future we'll need to copy more.
But "java.so -version" already works just by adding
the missing tzdb.dat.

Signed-off-by: Nadav Har'El <nyh@cloudius-systems.com>
Add missing apps/openjdk8/Makefile

Add missing makefile so that "make image=openjdk8" will work,
without needing to manually do "cd apps/openjdk8; ./GET" first.

Because openjdk8 compilation is so ridiculously slow, this
Makefile doesn't re-fetch and re-compile it every time.
You can "make clean" to remove the build output,
do the fetch and compile again.

Note that openjdk8 is notoriously difficult to compile
and requires many prerequisites.  Prefer openjdk8-fedora to use
pre-compiled binaries (you don't need to be running Fedora yourself!).

Signed-off-by: Nadav Har'El <nyh@cloudius-systems.com>
ruby-rails: Add Capstanfile

Signed-off-by: Takuya ASADA <syuu@cloudius-systems.com>
rpm: provide our own tool

This patch provides an amendment to the rpm package, whereas our own
tools/rpm.so is used instead of the rpm binary. This tool will better serve our
needs, and in specific, allow us to better capture the output of commands at
this point: rpm will only write to standard output, and changing that from the
command line requires a pipe/fork combination. In the future, we can also enhance
this utility in new ways that may serve us.

I have considered leaving the rpm module alone, and creating a new module for
the tool. However, the utility of an rpm binary outside the realm of our
application installation system is questionable, since rpm is not a server
software anyway.  So I am just modifying it here.

Signed-off-by: Glauber Costa <glommer@cloudius-systems.com>
wrk: build with debug information

Signed-off-by: Avi Kivity <avi@cloudius-systems.com>
Signed-off-by: Tomasz Grabiec <tgrabiec@cloudius-systems.com>
wrk: fix uninitialized connection object

Signed-off-by: Avi Kivity <avi@cloudius-systems.com>
Signed-off-by: Tomasz Grabiec <tgrabiec@cloudius-systems.com>
Add Minecraft server

Minecraft server is required to enjoy multiplayer mode
in minecraft worlds.
(https://minecraft.net/download)
Since it is a simple JAR file, I could execute minecraft server
on OSv with the following patch.

Due to the missing of cacerts (reported as Issue#400),
module.py needed to specify cacerts file explicitly.
It works on my Ubuntu 14.04 environment. It needs to specify
another location for other distributions.

Signed-off-by: Hisaki Ohara <hisakister@gmail.com>
cassandra: Enable -XX:ThreadPriorityPolicy=42

Cassandra startup script enables -XX:ThreadPriorityPolicy=42 and so
should we. It is disabled for historical reasons because when we first
started running Cassandra on OSv, we didn't support thread priorities at
all.

Signed-off-by: Pekka Enberg <penberg@cloudius-systems.com>
Signed-off-by: Tomasz Grabiec <tgrabiec@cloudius-systems.com>