一、下载appfuse并解压
二、下载ant1.6.5并解压
三、下载并安装tomcat5.0+
如果数据库放在本机请更改tomcat的监听端口(因为oracle的tnslistner的监听端口为8080,
会引起端口冲突!)
四、设置环境变量
1、jdk:JAVA_HOME=
2、tomcat :CATALINA_HOME=
3、ant :ANT_HOME
五、 oracle
1、创建用户
CREATE USER appftest IDENTIFIED BY appftest;
GRANT CONNECT TO appftest;
GRANT RESOURCE TO appftest;
2、oracle jdbc driver
copy ojdbc14.jar to {AppFuse home}/lib directory
3、在{appfuse path}/build.properties中加入下面属性
database.jar=${lib.dir}/oracle/ojdbc14.jar
database.type=oracle
database.host=localhost
#use the database schema owner and password created in step #1 above here
database.username=appfuse
database.password=appfuse
hibernate.dialect=net.sf.hibernate.dialect.Oracle9Dialect
database.driver_class=oracle.jdbc.driver.OracleDriver
database.url=jdbc:oracle:thin:@localhost:1521:oracledb
六、修改 web/WEB-INF/classes/mail.properties
七、生成应用
cd {appfuse path}
ant new -Dapp.name=myappname -Ddb.name=appftest
cd ..\myappname
ant setup
八、检验
启动tomcat
在浏览器敲入url:http://localhost:port/myappname检验是否成功!
好了,一切都完成了,祝你好运!