Installing the DXA web application for Java

Use an interactive script to build the Java version of SDL Digital Experience Accelerator (DXA), then deploy it in your server environment.

Before you begin

Make sure you have the following installed and configured:
  • JDK 8

About this task

  • This procedure can be completed on either a Linux or a Windows system. The steps are the same except that for Linux, you use the command prepare.sh and for Windows, you instead use prepare.bat. The procedure uses Windows commands; however, substitute prepare.sh as necessary.
  • This procedure describes two ways you can run the installer. One is to do it in stages and with the ability to change the default configuration as you go. The second is to simply take all the defaults.

Procedure

  1. Access your DXA installation media (in the location where it was downloaded).
  2. Open a PowerShell command prompt in Run as administrator mode.
  3. Go to the following location: web\installer\
  4. Complete the installation using one of the following methods.
    OptionDescription
    Simple, default installationRun the installation tool with the command prepare.bat (or prepare.sh) by itself with no tasks included, as follows:
    prepare.bat
    Incremental, configurable installation
    1. (Optional) To analyze configuration options (before building the application), run the installation tool with the help task.
      prepare.bat help
      Study the feedback from the tool to understand which parameters you need to specify and determine the values they need.
    2. Run the installer again, this time with the prepare task. Include any other parameters that you need to pass along.

      The command for Windows with no additional parameters (using all default values) is as follows:

      prepare.bat prepare
      It is not necessary to specify parameters when running the command. If parameter values are needed, the tool will ask you for them. After running the prepare task, you can access the configuration files in the following location, which can then edit for your specific needs:
      web\installer\dxa-webapp\src\main\resources
    3. If you ran the prepare command and then changed configuration, complete the installation by running the file again, this time with the generate task.

      The command for Windows is as follows:

      prepare.bat generate

Results

You have now built the web application, which will be located in the following folder:

web\installer\dxa-webapp

The folder contains a WAR file that you can deploy, as well as a non-compiled form of the web application that you can import into your favorite IDE.