Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Is it possible to create a website in a domain pointing to a local directory?

Or does everything deployed to Weblogic have to be WAR, EAR, RAR or JAR?

I want a simple possibility to just FTP to a folder, add html-files and have them added to weblogic, is this possible?

share|improve this question

1 Answer 1

up vote 1 down vote accepted

WebLogic can be configured to handle static content site, without it being any type of archive.

The way I have done this is to create a WEB-INF directory at the root your site directory and populate it with a weblogic.xml and web.xml file. These 2 files will cause WebLogic to see the directory as a web app. The contents of those files are as follows:

web.xml

<?xml version="1.0" encoding="ISO-8859-1"?>
  <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.
   //DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app>
    <welcome-file-list>
        <welcome-file>index.html</welcome-file>
</welcome-file-list>
</web-app>

weblogic.xml

<!DOCTYPE weblogic-web-app PUBLIC "-//BEA Systems, Inc.
  //DTD Web Application 8.1//EN" "http://www.bea.com/servers/wls810/dtd/weblogic 810-web-jar.dtd">
<weblogic-web-app>
     <context-root>/yoursite</context-root>
</weblogic-web-app>

Then you deploy it like a normal web application in the WebLogic console. The only other thing is that you need to be running your WebLogic server in Development mode. This will allow you to actively upload your new files without having to cycle the managed server to pick up changes.

-Bill

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.