Deploying a WAR File
twigkit-search.war
). If using Tomcat, copy the provided .war file into Tomcat’s webapps folder.
http://localhost:8080/{contextPath}
, where {contextPath}
is the name of the .war file (for example, http://localhost:8080/twigkit-search/
). You can also access the Appkit logs in the file system at {tomcat}/logs/catalina.out
.
settings.xml
file in your Maven configuration folder within your App Studio Enterprise project (/bin/settings.xml
). See the Maven Settings Reference for more information.
http://localhost:8080/
.
/target
folder you will find both the WAR file and the self-starting one, for example, app-studio-enterprise.jar
(note the .jar suffix). To run the application use:
src/main/profiles/<environment>
in the source code tree. The assumption being that the main source tree will continue to contain all the resources intended for the production
build of the application (that is, src/main/resources
). For example, to configure an application for use in three different environments, in this case dev
, staging
, and eventually production
, the source tree could be set up as follows:
-P
flag. For example, to deploy to the dev
environment you would use this command:
production
build. The profile resources are only merged with main resources in the pre-packaging phase of the build after they are in the target/classes
directory.
After the application has been packaged, the war and jar files associated with that particular application profile will be stored under the application’s dist/<environment>
directory where <environment>
is the name given to the build profile. For example:
dev
environment, another for the staging
environment, and finally one for the production
environment. The <application-name>
would be replaced by the name of the application. The application version number is appended to the production jar file.
To test a profile locally, you can use its self-starting archive JAR file. To run the application, navigate to the directory the JAR file is in and use this command:
<application-name>
with the actual name of the application.
src/dev/resources/conf
:
-Dtwigkit.conf.overlay
:
mvn clean package
). During this phase, any resource under the build profile will overwrite the equivalent resource in the main app.