Module: Avm::EacRailsBase1::Instances::SystemdUnit::Service

Defined in:
lib/avm/eac_rails_base1/instances/systemd_unit/service.rb

Instance Method Summary collapse

Instance Method Details

#service_contentObject



8
9
10
# File 'lib/avm/eac_rails_base1/instances/systemd_unit/service.rb', line 8

def service_content
  template.child('tasks_scheduler.service').apply(variables_source)
end

#service_exec_linesObject



12
13
14
15
16
# File 'lib/avm/eac_rails_base1/instances/systemd_unit/service.rb', line 12

def service_exec_lines
  service_exec_operations
    .map { |k, v| "#{k}=#{tasks_scheduler_command_path} #{v}" }
    .join("\n")
end


22
23
24
# File 'lib/avm/eac_rails_base1/instances/systemd_unit/service.rb', line 22

def service_link_path
  ::Pathname.new('/etc/systemd/system/multi-user.target.wants').join(unit_name)
end

#service_pathObject



18
19
20
# File 'lib/avm/eac_rails_base1/instances/systemd_unit/service.rb', line 18

def service_path
  ::Pathname.new('/etc/systemd/system').join(unit_name)
end

#verify_serviceObject



26
27
28
# File 'lib/avm/eac_rails_base1/instances/systemd_unit/service.rb', line 26

def verify_service
  sudo_system!('systemd-analyze', 'verify', service_path)
end