Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue 40 shebang #50

Merged
merged 2 commits into from
May 28, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 12 additions & 7 deletions bin/docker/entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,20 +1,25 @@
#!/usr/bin/env bash

# no command line arguments are handled

# Start up OTOBO Daemon and the webserver
# Run a watchdog over the Daemon via Cron

# no command line arguments are handled

# start the Daemon and set up the Cron watchdog
# assume that we are in /opt/otobo
# TODO: this might not work when the database is not yet created and configured
mkdir var/tmp
mkdir -p var/tmp

# set up the cronjobs as they are declared in var/cron
./bin/Cron.sh start
perl ./bin/otobo.Daemon.pl start

# Start the Daemon.
# The Daemon will exit immediately when SecureMode = 0.
# But this is OK, as Cron will restart it and it will run when SecureMode = 1.
./bin/otobo.Daemon.pl start

# maintainance jobs
# TODO: this might not work when the database is not yet created and configured
# TODO: decide whether it makes sense to run these jobs on startup
#perl ./bin/otobo.Console.pl Maint::Config::Rebuild
#perl ./bin/otobo.Console.pl Maint::Cache::Delete

# Start the webserver
plackup --server Gazelle -R Kernel,bin/psgi-bin/otobo.psgi --port 5000 bin/psgi-bin/otobo.psgi