Child pages
  • Your First Deployment

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: grammar

...

When you run your projects inside Eclipse, they use it uses the incremental builder and the "internal builds" are not ready for deployment (e.g. don't use the build from the "build" folder of the project, it's not a complete build!). You need to use Ant or Maven to actually build a full "product". Let's focus on Ant because, again, this is what the majority use. You can also use Jenkins, but Jenkins will need to call Maven or Ant to build the projects anyway.

...

Before adding the application into JavaMonitor, you have to copy the applications on the deployment server. You can use any tools that you usually use to copy files on the remote server (scp, rsync, CyberDuck, etc.). Usually you need to copy the application in to the following remote directory:

...

Copy the BlogRest-Application.tar.gz archive into the correct directory from the above list and uncompressed it (tar zxf BlogRest-Application.tar.gz). Doing this command will result in This will create a new directory called named BlogRest.woa.

One last step to do for the application. Usually, the application will run with the appserver user and the appserveradm group. You need to make sure that either the group or the user can run the application. The best way to do this is to change the group of the files to be appserveradm. Your user on the deployment server should also be part of that group. To change the group:

...

It would also be useful to log problems to a log file. For now, we will put the log into /tmp. That means that the log will be lost when you reboot the server or if you have tools like WebMin that cleans clean the /tmp directory every day, but for now it would do the job.

To specific specify the path to the log file, go to the Output Path section and enter /tmp in the text field next to MacOSX (if your deployment box is on OS X) or next to Unix (if your development is UNIX but not OS X).

The next step is to click on the Push All button, which saves the application configuration. Now, we can add instances of the application. To do so, click on the Detail View link.

You will see a section saying _Add: 1 instance(s) on host: _. Click the Add button. That will add one instance of the application. It's possible to run multiple instances of an application, mainly to load balance requests and also to have other working instances in case an instance is going AWOL. But for now, running one instance is enough.

If the application was startedlaunches successfully, a link on the application name will appear after 30 seconds in JavaMonitor. If a link don't does not appear after a minute and the status is still STOP, something is wrong. Check the log that was created in /tmp (the log should be /tmp/WOCommunity-1) to check for any errors.

If the log don't even file does not exist, 99% of the time, the problem is file permissions. Make sure that the launch script for the application (BlogRest.woa/BlogRest) is accessible for the appserver user. If the file permissions are ok, you can launch the script manually with the appserver user by doing:

...