sul-dlss/common-accessioning

View on GitHub
lib/capistrano/tasks/abbyy_watcher_systemd.cap

Summary

Maintainability
Test Coverage
# frozen_string_literal: true

namespace :abbyy_watcher_systemd do
  desc 'Restart the abbyy_watcher systemd service'
  task :restart do
    on fetch(:abbyy_watcher_server) do
      within release_path do
        execute 'sudo systemctl restart abbyy_watcher'
      end
    end
  end

  desc 'Check that the abbyy_watcher systemd service is running'
  task :status do
    on fetch(:abbyy_watcher_server) do
      within release_path do
        execute 'systemctl status abbyy_watcher'
      end
    end
  end
end