Installing the server as services using systemd

You can find information about the steps to install the server to run as systemd services. After you configure a server using the systemd service, the server automatically restarts when it stops abruptly.

You must have ensured that the server is installed on Linux.

Installing the server by using the systemd service helps you to ensure that the server runs automatically on the system startup and restarts the server automatically if it stops.

  1. Log in to the server host machine as a root user.
  2. Locate the product system directory by using the following command:
    $ cd <install-directory>/bin/system
  3. Edit the unit file and specify the User and Group values that will run the server.

    User: The name of the user who will run the server.

    Group: The name of the group associated with the user.

    Your interface might look like the following example:

    Note:

    Note: When you customize the user and group values, you must update the ownership of the server files to match with the updated User and Group values.

  4. Install the service unit file by using the following commands:
    $ sudo cp devops-deploy-server.service /etc/systemd/system
    $ sudo chmod 664 /etc/systemd/system/devops-deploy-server.service
    $ sudo chown root:root /etc/systemd/system/devops-deploy-server.service
    $ sudo systemctl daemon-reload
  5. Enable the service to start automatically on system startup by using the following command:
    $ sudo systemctl enable devops-deploy-server
  6. Start the server as service by using the following command:
    $ sudo systemctl start devops-deploy-server
You installed the server to run as a systemd service.
You must run the following command to verify whether the server is running as a systemd service:
$ sudo systemctl status devops-deploy-server