Author: solomax
Date: Tue Apr 17 06:56:24 2012
New Revision: 1326951
URL: http://svn.apache.org/viewvc?rev=1326951&view=rev
Log:
OPENMEETINGS-175 install.xml with step==1 is created фаеку successful
installation
Modified:
incubator/openmeetings/trunk/singlewebapp/src/org/openmeetings/app/documents/InstallationDocumentHandler.java
incubator/openmeetings/trunk/singlewebapp/src/org/openmeetings/cli/Admin.java
incubator/openmeetings/trunk/singlewebapp/src/org/openmeetings/servlet/outputhandler/Install.java
Modified:
incubator/openmeetings/trunk/singlewebapp/src/org/openmeetings/app/documents/InstallationDocumentHandler.java
URL:
http://svn.apache.org/viewvc/incubator/openmeetings/trunk/singlewebapp/src/org/openmeetings/app/documents/InstallationDocumentHandler.java?rev=1326951&r1=1326950&r2=1326951&view=diff
==============================================================================
---
incubator/openmeetings/trunk/singlewebapp/src/org/openmeetings/app/documents/InstallationDocumentHandler.java
(original)
+++
incubator/openmeetings/trunk/singlewebapp/src/org/openmeetings/app/documents/InstallationDocumentHandler.java
Tue Apr 17 06:56:24 2012
@@ -18,6 +18,7 @@
*/
package org.openmeetings.app.documents;
+import java.io.File;
import java.io.FileWriter;
import org.dom4j.Document;
@@ -61,7 +62,7 @@ public class InstallationDocumentHandler
public int getCurrentStepNumber(String filePath) throws Exception{
SAXReader reader = new SAXReader();
- Document document =
reader.read(filePath+InstallationDocumentHandler.installFileName);
+ Document document = reader.read(new File(filePath,
InstallationDocumentHandler.installFileName));
Node node = document.selectSingleNode( "//install/step/stepnumber" );
Modified:
incubator/openmeetings/trunk/singlewebapp/src/org/openmeetings/cli/Admin.java
URL:
http://svn.apache.org/viewvc/incubator/openmeetings/trunk/singlewebapp/src/org/openmeetings/cli/Admin.java?rev=1326951&r1=1326950&r2=1326951&view=diff
==============================================================================
---
incubator/openmeetings/trunk/singlewebapp/src/org/openmeetings/cli/Admin.java
(original)
+++
incubator/openmeetings/trunk/singlewebapp/src/org/openmeetings/cli/Admin.java
Tue Apr 17 06:56:24 2012
@@ -27,9 +27,11 @@ import org.apache.commons.cli.ParseExcep
import org.apache.commons.cli.Parser;
import org.apache.commons.cli.PosixParser;
import org.openmeetings.app.data.user.dao.UsersDaoImpl;
+import org.openmeetings.app.documents.InstallationDocumentHandler;
import org.openmeetings.app.installation.ImportInitvalues;
import org.openmeetings.app.installation.InstallationConfig;
import org.openmeetings.app.persistence.beans.user.Users;
+import org.openmeetings.app.remote.red5.ScopeApplicationAdapter;
import org.openmeetings.servlet.outputhandler.BackupExport;
import org.openmeetings.servlet.outputhandler.BackupImportController;
import org.openmeetings.utils.OMContextListener;
@@ -229,7 +231,8 @@ public class Admin {
private void process(String[] args) {
String ctxName = System.getProperty("context", "openmeetings");
- File omHome = new File(new File(System.getenv("RED5_HOME"),
"webapps"), ctxName);
+ File home = new File(System.getenv("RED5_HOME"));
+ File omHome = new File(new File(home, "webapps"), ctxName);
Parser parser = new PosixParser();
CommandLine cmdl = null;
@@ -314,6 +317,9 @@ public class Admin {
ClassPathXmlApplicationContext ctx =
getApplicationContext(ctxName);
ImportInitvalues importInit =
ctx.getBean(ImportInitvalues.class);
importInit.loadAll(new File(omHome,
ImportInitvalues.languageFolderName).getAbsolutePath(), cfg, login, pass,
email, group, tz);
+
+ File installerFile = new File(new
File(home, ScopeApplicationAdapter.configDirName),
InstallationDocumentHandler.installFileName);
+
InstallationDocumentHandler.getInstance().createDocument(installerFile.getAbsolutePath(),
1);
} catch(Exception e) {
handleError("Install failed", e);
}
Modified:
incubator/openmeetings/trunk/singlewebapp/src/org/openmeetings/servlet/outputhandler/Install.java
URL:
http://svn.apache.org/viewvc/incubator/openmeetings/trunk/singlewebapp/src/org/openmeetings/servlet/outputhandler/Install.java?rev=1326951&r1=1326950&r2=1326951&view=diff
==============================================================================
---
incubator/openmeetings/trunk/singlewebapp/src/org/openmeetings/servlet/outputhandler/Install.java
(original)
+++
incubator/openmeetings/trunk/singlewebapp/src/org/openmeetings/servlet/outputhandler/Install.java
Tue Apr 17 06:56:24 2012
@@ -167,8 +167,7 @@ public class Install extends VelocityVie
+ ScopeApplicationAdapter.configDirName
+ File.separatorChar;
- File installerFile = new File(working_dir
- +
InstallationDocumentHandler.installFileName);
+ File installerFile = new File(working_dir,
InstallationDocumentHandler.installFileName);
if (command == null || !installerFile.exists()) {
log.debug("command equals null");
@@ -178,8 +177,6 @@ public class Install extends VelocityVie
File installerdir = new
File(working_dir);
log.debug("bb " + installerFile);
- log.debug("bb " + working_dir
- +
InstallationDocumentHandler.installFileName);
boolean b = installerdir.canWrite();