APG|SGA
infosnowAPI Type 1API Type 2Divers

Divers - Install Jobserver

This is a manual for Linux. Explicitly tested on Debian GNU/Linux 10 "Buster".

We know for sure that the Jobserver runs on Windows very solid as well, but the startup behaviour is not transparent and can be problematic (as some people say), so you have to try at your very own risk.

What should you do if uncertain?

Why bother with this Jobserver at all? Use Amazon AWS Beanstalk, upload your JAR and you are done. Well, so about once a year an Update is required.

Most convenient solution?

Let APG|SGA handle this problem for you. We have 15 years of experience in how to keep such Jobservers up and running. Don't forget that the Jobserver is the heartbeat of your transaction system.

Risks of external Jobservers?

None at all. Really!

Each Jobserver can only call URLs and they must all be on the same hardcoded server. Everything over regular HTTPS-Port, so your Firewall should not be a problem.

The Jobserver itself does not know more than he (ir)regularly has to call some URLs with arbitrary parameters, he never sees any data.

And the Jobserver has no memory at all - it calls an URL, handles the response and then immediately forgets everything about this transaction.

Create system service for jobserver

1) Install JRE

$ sudo apt install default-jre

2) Move jobserver.jar to /opt

3) Create a file /etc/systemd/system/jobserver.service with the following content:

[Unit]
Description=Jobserver für Infosnow
After=syslog.target network.target

[Service]
SuccessExitStatus=143

User=[YOUR USER]
Group=[YOUR USER]

Type=simple

WorkingDirectory=/opt
ExecStart=/usr/lib/jvm/default-java/bin/java -jar jobserver.jar
ExecStop=/bin/kill -15 $MAINPID

[Install]
WantedBy=multi-user.target

4) Rebuild internal service database of systemd

$ sudo systemctl daemon-reload

5) Start service

$ sudo systemctl start jobserver.service

6) Check if service is running

$ sudo systemctl status jobserver.service

7) Enable service at bootup

$ sudo systemctl enable jobserver.service

Stopping the jobserver

To stop the service, you can ether

$ sudo systemctl stop jobserver.service
or
$ killall java
or
Search process with pgrep and kill it with kill -15 [PID]