Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
ghost@theMachine pscu % cd test
ghost@theMachine test % tree
.
├── pom.xml
└── test-webapp
├── pom.xml
└── src
└── main
└── webapp
├── WEB-INF
│   ├── bootstrap
│   │   ├── author
│   │   ├── common
│   │   └── public
│   └── config
│   └── default
└── docroot

12 directories, 2 files
ghost@theMachine test %

 

3. Edit the POM files as follows:

  • for the parent POM (pom.xml), choose option B (either comment out or delete option A, and uncomment option B)
  • for the webapp POM (test-webapp/pom.xml), choose option iii (either comment out or delete options i and ii, and uncomment option iii)

    Expand
    titleClick here to see what those pom files look like at this point ...

Build the project:

...

4. Exclude the problematic libraries by editing the webapp pom:

Expand
titleClick here to see the updated pom file ...

webapp pom: pom.xml


5. Build the project:

note
Code Block
mvn clean install

If you are using Eclipse, there are some additional steps you must take before running the project

Expand
  1. cd training-webapp 
  2. mvn war:inplace 
  3. You MUST use a v7 of Tomcat - v8.x and v9.x DO NOT WORK with Eclipse.  For example: https://tomcat.apache.org/download-70.cgi#7.0.93

Run the project:

Instructions for IntelliJ

...

Import the maven project

  1. Click Import Project.
    Image Removed
  2. Browse to the folder where your parent pom is.  Click Open.
  3. Check Search for projects recursively. Click Next.
    Image Removed
  4. Nothing to change on Select profiles. Click Next.
  5. For Select Maven projects to import, click Unselect all, then check: com.magnolia-cms:training:1.0-SNAPSHOT.
    Image Removed
  6. Nothing else to change ... just keep clicking Next.
  7. Click OK.
  8. Click Finish.

Configure the server

...

Add a new local Tomcat Server configuration.

Tip

You may to select xx items more from the bottom of the list if you don't see a tomcat option.

Expand
titleClick here to see my output ...

output.txt

6. Find the resultant WAR file:

Code Block
ghost@theMachine test % ff war
running [find . -iname "*war*"] ...
./test-webapp/target/war
./test-webapp/target/test-webapp-1.0-SNAPSHOT.war
ghost@theMachine test %

Now you can move that WAR file to Tomcat and try again (smile)

...

  1. Uncheck 'After launch'
    Image Removed

...

Image Removed

  1. Enter the License Information (see below)

Instructions for Eclipse

...

Import the maven project

  1. Browse to the folder above where your parent pom is.  For example, if your parent pom is in ~/eclipse-training/training, browse to ~/eclipse-training.  Click Launch.
    Image Removed
  2. From the Project Explorer, right-click, and select Import > Import.
    Image Removed
  3. Select Import Existing Maven Projects.
    Image Removed
  4. Select the training project as the Root Directory and click Finish.
    Image Removed

Configure the server

  1. On the Servers tab, click the link to create a new server.

  2. For server type, select an installed Tomcat - For example, v7.0.  Remember: v8.x and v9.x will NOT WORK WITH ECLIPSE.

Image Removed

  1. Browser to the tomcat server and click Finish.

    Image Removed
  2. Double-click on the server you just created to open the Overview - change the Timeouts from 45 to 450 and 15 to 150 and Check Serve modules without publishing.

Image Removed

  1. Save the configuration (Ctrl-s or so).
  2. Right click the server configuration and Select Add and Remove, select training-webapp, click Add and then Finish.

Image Removed

  1. Run it!
  2. Install it!
  3. Image Removed

  4. Enter the License Information (see below)

License Information:

...

Code Block
License owner: training-prodyna@magnolia-cms.com
License key:
LS0tLS1CRUdJTiBQR1AgTUVTU0FHRS0tLS0tClZlcnNpb246IEJDUEcgdjEuNTgKCm93SjRuSnZBeTh6RXhDaWIrdkg3dFNBbkRzYlRCNWlUdUhQVDgzSnlNcE5UODRwVFk4b01ueW1IcDZZb3VLVW0KS1JpWkt4aVlXNW1ZV0ptYUtEaTdoaWdZR1JoYWNwV2xGaFZuNXVjVjIwYWI2Um5vR2VpWWc4aG9ydnp5dk5RaQoyNUtpeE15OHpMeDAzWUtpL0pUS3ZFU0gzTVQwdlB5Y3pFVGQ1TnhpdmVUOFhLN1Vpb0xNb3NRU29BbTJJT04wCkRVeDBqUTI0Y3ZOVFNuTlNpMjFUODBwU2l3cUtNb3RUdVZKVE1rdkE5aURFUUthbXBSYURyRS9NMFVGUzJ6R0gKaFltUmlZR05sUW5rZmdZdVRnR1lCMjJ0bVA4S1B3L3M2SGZ2K2FlMjRadWVSTzFjc2I2RzQwL2Z4RHlmL0haeQpSTVh5Z2l6RERaZk1YcDB5My95YWdUVlEvV2loY2UyRlR0WU1tL3JvOUpXaG1kVi9IZHVmMWQ0N2JsVDVUVHMrCk1VNDNnTVdFOTFQZXVkaDRwUzFOVEJPdHQ5UndOYjR0ZmQ5ZzZEOUxObkRYdnBXZnpING5palgwbm5qd3lxcHAKOTdTbnVvc1dTRzYzbFFRQUtEeVE5QT09Cj03bURNCi0tLS0tRU5EIFBHUCBNRVNTQUdFLS0tLS0K

...

...