Commit 0e26207e authored by Andrea Bignamini's avatar Andrea Bignamini
Browse files

Add service files for databaseds and starter

The tango-databaseds.service and tango-starter.service files are
added in the tango_demons directory.
The README is updated with the installation instructions for
the tango demons.
parent 469023ff
Loading
Loading
Loading
Loading
+19 −2
Original line number Diff line number Diff line
@@ -15,5 +15,22 @@ To compile and install a tool, just enter the directory and run

## Tango Service Scripts

The directory `tango_demons` stores the service scripts `tango_databaseds` and `tango-starter`
you may want to use to run Tango.
The directory `tango_demons` stores the scripts `tango_databaseds` and `tango-starter`
and the corresponding service files to you may want to use to run Tango at boot.

Enter the `tango_demons` directory, copy the scripts in `/etc/init.d` and chmod them

    cp tango-databaseds /etc/init.d/
    cp tango-starter /etc/init.d/
    chmod +x /etc/init.d/tango-databaseds
    chmod +x /etc/init.d/tango-starter

Copy the service files in the systemd and enable them

    cp tango-databaseds.service /etc/systemd/system/
    cp tango-starter.service /etc/systemd/system/
    
    systemctl enable tango-databaseds
    systemctl start tango-databaseds
    systemctl enable tango-starter
    systemctl start tango-starter
+14 −0
Original line number Diff line number Diff line
[Unit]
Description=Tango Database
After=mysql.target
Before=tango-starter.service

[Service]
Type=forking
ExecStart=/etc/init.d/tango-databaseds start
ExecStop=/etc/init.d/tango-databaseds stop

[Install]
WantedBy=multi-user.target

PIDFile=/var/run/DataBaseds.pid
+12 −0
Original line number Diff line number Diff line
[Unit]
Description=Tango Starter

[Service]
Type=forking
ExecStart=/etc/init.d/tango-starter start
ExecStop=/etc/init.d/tango-starter stop

[Install]
WantedBy=multi-user.target

PIDFile=/var/run/Starter.pid