X-Git-Url: https://git.argeo.org/?a=blobdiff_plain;f=lib%2Fsystemd%2Fsystem%2Fargeo%40.service;fp=lib%2Fsystemd%2Fsystem%2Fargeo%40.service;h=816206b9a3e2223045720eb7cf7fb9ddf733ad87;hb=b27ec4b5db6467752588a5e62c89fb215bfd9da2;hp=0000000000000000000000000000000000000000;hpb=30e54feecf2b6c765e7efc97c6874b032424e901;p=gpl%2Fargeo-freed.git diff --git a/lib/systemd/system/argeo@.service b/lib/systemd/system/argeo@.service new file mode 100644 index 0000000..816206b --- /dev/null +++ b/lib/systemd/system/argeo@.service @@ -0,0 +1,45 @@ +[Unit] +Description=Argeo node %I +After=network-online.target +Wants=postgresql.service + +[Service] +Type=simple + +User=freed +Group=freed + +StateDirectory=argeo.d/%I +LogsDirectory=argeo.d/%I +ConfigurationDirectory=argeo.d/%I +CacheDirectory=argeo.d/%I +EnvironmentFile=/usr/local/etc/default/argeo +WorkingDirectory=/var/lib/argeo.d/%I + +ExecStart=java \ +-Djava.library.path=/usr/local/lib/a2/org.argeo.slc:/usr/local/lib/a2/org.argeo.tp.sys \ +-Dosgi.configuration.cascaded=true \ +-Dosgi.sharedConfiguration.area=${CONFIGURATION_DIRECTORY} \ +-Dosgi.sharedConfiguration.area.readOnly=true \ +-Dosgi.configuration.area=${STATE_DIRECTORY}/state/ \ +-Dosgi.instance.area=${STATE_DIRECTORY}/data/ \ +-Dargeo.node.repo.indexesBase=${CACHE_DIRECTORY}/indexes \ +-Dorg.osgi.framework.system.packages.extra=sun.security.util,sun.security.internal.spec,sun.security.provider,com.sun.net.httpserver,com.sun.jndi.ldap,com.sun.jndi.ldap.sasl,com.sun.jndi.dns,com.sun.security.jgss,com.sun.nio.file,com.sun.nio.sctp \ +-Dorg.eclipse.equinox.http.jetty.autostart=false \ +@/usr/local/etc/argeo/jvm.args \ +@${CONFIGURATION_DIRECTORY}/../jvm.args \ +@${CONFIGURATION_DIRECTORY}/jvm.args \ +-cp "/usr/local/share/a2/osgi/equinox/org.argeo.tp.osgi/org.eclipse.osgi.3.18.jar:/usr/local/share/a2/org.argeo.cms/org.argeo.init.2.3.jar" \ +org.argeo.init.ServiceMain + +# Exit codes of the JVM when SIGTERM or SIGINT have been caught: +SuccessExitStatus=143 130 + +CPUAccounting=true +MemoryAccounting=true +TasksAccounting=true +IOAccounting=true +IPAccounting=true + +[Install] +WantedBy=network-online.target