packaging: use simplified template when handling ovirt-engine-proxy.conf.in

Change-Id: I7031884c602e2bd5dfffb34b42e5925cf2f39afa
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
packaging: less intrusive method for httpd integration

CURRENT IMPLEMENTATION

ovirt-engine proxy all requests, disallow any additional application to
be hosted on the same web server.

NEW IMPLEMENTATION

proxy only ovirt-engine URI prefixes. By default ovirt-engine is at:

  http://host/ovirt-engine

Optionally add redirect from / to /ovirt-engine during setup.

SIDE EFFECTS

In order to handle redirects of 404.html, we require some valid URI to
redirect into, as a result the welcome page of root will not be
index.html but ovirt-engine.html, same for style.css which was renamed
to ovirt-engine-style.css

Change-Id: I89a47a99e28de0905183dc502cb0b35c80f77e6d
Signed-off-by: Alex Lourie <alourie@redhat.com>
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
packaging: engine-service: remove limits.d file

the limits.d file is not used as service applies rlimit on its own.

Change-Id: I35e00bb4756e590e3c7e463b5d758bbb00de4a43
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
packaging: engine-service: allow service user customization

Change-Id: Ie71a3a56c77e29aea87b955dc82cd194e88c3582
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
packaging: engine-service: use python daemon instead of own implementation

Change-Id: I6b533fbdbde47d8fdb62964d60aa22e98c1e57c3
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
packaging: engine-service: add options for wrappers

In order to be used at other environments, with their own init.d layout,

Add:
  --quiet
  --pidfile
  --foreground

Change-Id: I00d868fc51ec73800cae2eb24002feb933744851
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
packaging: engine-service: rework start pid file handling

There is no reason to force user to explicit stop and start the service
in case pid file contains non running process.

Change-Id: I8d8a7f8f8b7f5941f447df3d279686b973b5c393
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
packaging: engine-service: downstream infrastructure usage

Use features of downstream instead our own implementation.

systemd

1. detach from controlling terminal.
2. Change user/group.
3. stop service using signal.
4. set rlimit.

sysv

1. Change user/group.
2. stop service by pidfile.
3. set rlimit

systemd note:

As jboss return non zero error code when receiving SIGTERM, and systemd
expect processes to terminate with zero error code, we create a wrapper
over the java.

Change-Id: Ie02f0d44bbba7d1a7af6bcf6b808610e85b907c6
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
packaging: engine-service: remove dead code

Change-Id: Id520a0ff33e797b2995fb217754605c219f6a922
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
packaging: engine-service: set default service mode to foreground

this will ease developer when executing the service.

Change-Id: Ib7e5ffe4e104d2c3a0c931f3f344f7c3c12eb57f
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
packaging: engine-setup re-write using otopi

Change-Id: I4d5e3ac7927802326e324c9b98ada75b421638aa
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Signed-off-by: Alex Lourie <alourie@redhat.com>