From b5b64616d8b1f1d1fc048bb732991e31c58dac0e Mon Sep 17 00:00:00 2001 From: Andreas Nedbal Date: Sun, 27 Oct 2024 23:25:24 +0100 Subject: [PATCH] Add example systemd service files --- docs/systemd/retrospring-sidekiq.service | 18 ++++++++++++++++++ docs/systemd/retrospring-web.service | 19 +++++++++++++++++++ 2 files changed, 37 insertions(+) create mode 100644 docs/systemd/retrospring-sidekiq.service create mode 100644 docs/systemd/retrospring-web.service diff --git a/docs/systemd/retrospring-sidekiq.service b/docs/systemd/retrospring-sidekiq.service new file mode 100644 index 00000000..e5125a8c --- /dev/null +++ b/docs/systemd/retrospring-sidekiq.service @@ -0,0 +1,18 @@ +# TODO: Replace "/home/retrospring/retrospring" with directory of your Retrospring installation + +[Unit] +Description=retrospring-sidekiq +After=network.target + +[Service] +Type=simple +User=retrospring +WorkingDirectory=/home/retrospring/retrospring +Environment="RAILS_ENV=production" +ExecStart=/home/retrospring/.rbenv/shims/bundle exec sidekiq -e production -C ./config/sidekiq.yml +TimeoutSec=15 +Restart=always +WorkingDirectory=/home/retrospring/retrospring + +[Install] +WantedBy=multi-user.target \ No newline at end of file diff --git a/docs/systemd/retrospring-web.service b/docs/systemd/retrospring-web.service new file mode 100644 index 00000000..1695c012 --- /dev/null +++ b/docs/systemd/retrospring-web.service @@ -0,0 +1,19 @@ +# TODO: Replace "/home/retrospring/retrospring" with directory of your Retrospring installation + +[Unit] +Description=retrospring-web +After=network.target + +[Service] +Type=simple +User=retrospring +WorkingDirectory=/home/retrospring/retrospring +Environment="RAILS_ENV=production" +Environment="PORT=3000" +ExecStart=/home/retrospring/.rbenv/shims/bundle exec puma +TimeoutSec=15 +Restart=always +WorkingDirectory=/home/retrospring/retrospring + +[Install] +WantedBy=multi-user.target \ No newline at end of file