GroundWork Developer's Kit (GDK) Development Environment
From GroundWork Developer Kit
Contents |
[edit] Using the GDK Development Environment
NOTE: Refer to GroundWork Developer's Kit (GDK) and GroundWork Developer's Kit Installation for details about GDK installation.
Use the GDK development environment when you wish to create custom objects, such as portlets.
To work efficiently in the GDK development environment, begin by opening three different windows:
- SuperUser window - Here you can start and stop gwservices as necessary
- Eclipse window - A window dedicated to launching and working with Eclipse
- Development window - Here you can develop and deploy your custom objects
[edit] SuperUser Window
In the SuperUser window, type these commands to set the mode:
- su
- passwd: <<superuser password>>
Then, navigate to the directory that contains the ctlscrpt.sh used to stop and start gwservices:
/usr/local/groundwork/
The figure below displays the commands used in the SuperUser window to stop gwservices
[edit] Eclipse Window
Use the Eclipse window to launch and work with Eclipse.
[edit] Launching Eclipse
NOTE: Before launching Eclipse, log in as superuser and change the password of user nagios to nagios. Refer to Changing password for User nagios for details.
In the Eclipse window, type the commands below to launch Eclipse:
- ssh -X nagios@localhost
- password: nagios
- export LD_LIBRARY_PATH=
- cd /usr/localhost/groundwork/gdk/tools/eclipse
- ./eclipse
The figure below displays the commands to launch Eclipse.
When launched, the Eclipse logo appears.
[edit] Development Window
Use the Development window to deploy custom objects.
For example, if you are deploying a custom portlet written in PHP, type the following commands to login as the nagios superuser, navigate to the sample-php directory, and deploy your custom portlet project:
- su nagios
- password: nagios
- cd /usr/local/groundwork/gdk/monitor-portal/applications/sample-php
- maven deploy
The figure below displays the Development window used to deploy a project in the sample-php directory.