Skip to content
This repository has been archived by the owner on Jun 10, 2021. It is now read-only.

Setup Hawk Server on Linux (Ubuntu) Environment

monitobeko edited this page Jun 23, 2016 · 3 revisions

Setup Hawk Server on Linux (Ubuntu) Environment

1. Download the following repositories:

3. Configure your host file

  • Open "/etc/hosts"

  • Add the following lines:

    127.0.0.1 hawkserver

    127.0.0.1 redis

4. Prepare your machine

5. Prepare the hawk-ui

  • Enter the ui folder and execute the following commands:
    • npm install
    • npm install gulp -g
    • npm install bower -g
    • npm install bower
    • bower install
    • gulp build

6. Build HawkEngine

  • Make sure you have at least java 1.8.0_60 (jdk1.8.0_60)

  • Make sure your JAVA_HOME environment variable is using the correct path

  • Enter hawk folder and open a terminal within this folder. Execute the following command:

    • ./gradlew build -x test
  • This should generate folder hawk\build\libs. Inside you should have the following .jar files:

    • server.jar
    • server-all.jar
  • Go to the hawk\build\libs folder and open a terminal within this folder. Type the following command:

    • java -jar server-all.jar

7. Build the agent

  • Make sure you have at least java 1.8.0_60 (jdk1.8.0_60)

  • Make sure your JAVA_HOME environment variable is using the correct path

  • Enter hawk-agentj folder and open a command prompt within this folder. Execute the following command:

    • ./gradlew build -x test
  • This should generate folder hawk-agentj\build\libs. Inside you should have the following .jar files:

    • hawk-agentj.jar
    • hawk-agentj-all.jar
  • In order to configure the agent the following folder structure must be created within the hawk-agentj\build\libs folder:

    • hawk-agentj\build\libs\config
    • hawk-agentj\build\libs\log
    • hawk-agentj\build\libs\pipelines
  • In the hawk-agentj\build\libs\config there should be config.properties file (If is not there, create it).The content of the files should be:

    • agentPipelinesDir=Pipelines
    • agentId=57dd8d93-cd9e-444e-a248-36f64a447b80
    • serverPort=8080
    • serverName=hawkserver
    • agentName=Agent1
  • These are configuration settings of the agent which point to which server should connect, etc.Once this is accomplished, go back to hawk-agentj\build\libs folder and open a terminal within this folder. Type the following command:

    • java -jar hawk-agentj-all.jar
  • The agent console should be displayed and the agent should start logging messages whether is connected to the server or not.