• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to create a WAR file

 
Ashok Pradhan
Ranch Hand
Posts: 180
Eclipse IDE Firefox Browser Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have my servlet file Ch1Servlet.java and compiled it and also create DD web.xml and created the directory stucture WEB-INF inside it i place web.xml and classes folder and inside classes folder i place Ch1Servlet.class. I want to create WAR file to deploy in glassfish server.I am new to servlet .Thanks in advance .
 
David O'Meara
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It can be done easily using the ANT WAR task
http://ant.apache.org/manual/CoreTasks/war.html
 
sudhir nim
Ranch Hand
Posts: 212
Eclipse IDE Spring Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Open command prompt
Change directory to the root directory of your application (parent dir of WEb-INF)

run the following command

 
Karthik Srinivas
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just use eclipse and choose Export -> WAR file. That would be very easy.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Karthik Srinivas S:
Just use eclipse and choose Export -> WAR file. That would be very easy.


The original poster never mentioned using Eclipse.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!