kevin85421 commented on a change in pull request #157: SUBMARINE-343. Update 
HowToRun.md due to new docker images
URL: https://github.com/apache/submarine/pull/157#discussion_r368354173
 
 

 ##########
 File path: docs/workbench/HowToRun.md
 ##########
 @@ -13,67 +13,145 @@
    limitations under the License.
 -->
 # How To Run Submarine Workbench
+We provide two methods to launch Submarine Workbench
+*  Method 1:  Run Submarine Workbench on docker
+*  Method 2:  Run Submarine Workbench without docker
 
-## Run Submarine on docker
+# Run Submarine Workbench on docker
 
-By using the official image of submarine, only one docker command is required 
to run submarine workbench.
+By using the official images of Submarine, only a few docker commands are 
required to launch **Submarine Workbench**. The document includes information 
about how to launch the Submarine Workbench via the new docker images and the 
information about how to switch between different Submarine Workbench 
versions(version Vue & version Angular). 
 
-It should be noted that since the submarine workbench depends on the submarine 
database, so you need to run the docker container of the submarine database 
first.
+### Two versions of Submarine Workbench
+1. Angular (default)
+2. Vue (This is the old version, and it will be replaced by version Angular in 
the future.)
+#### (WARNING: Please restart a new **incognito window** when you switch to 
different versions of Submarine Workbench) 
+### Launch the Submarine Workbench(Angular)
+* It should be noted that since Submarine Workbench depends on the Submarine 
database, so you need to run the docker container of the Submarine database 
first.
+```
+docker run -it -p 3306:3306 -d --name submarine-database -e 
MYSQL_ROOT_PASSWORD=password apache/submarine:database-0.3.0-SNAPSHOT
+docker run -it -p 8080:8080 -d --link=submarine-database:submarine-database 
--name submarine-server apache/submarine:server-0.3.0-SNAPSHOT
+```
+* The login page of Submarine Workbench will be shown in ```127.0.0.1:8080```.
 
+### Switch from version Angular to version Vue
+*  Step1: Launch submarine-database and submarine-server containers 
+```
+docker run -it -p 3306:3306 -d --name submarine-database -e 
MYSQL_ROOT_PASSWORD=password apache/submarine:database-0.3.0-SNAPSHOT
+docker run -it -p 8080:8080 -d --link=submarine-database:submarine-database 
--name submarine-server apache/submarine:server-0.3.0-SNAPSHOT
+```
+*  Step2: Compile Submarine in your host (not in the container)
+```
+cd ./submarine
+mvn clean install package -DskipTests 
+```
+*  Step3: Copy workbench-web.war into the submarine-server container
+```
+cd submarine-workbench/workbench-web/target
+docker cp workbench-web.war 
submarine-server:/opt/submarine-dist-0.3.0-SNAPSHOT-hadoop-2.9
+```
+*  Step4: Enter the submarine-server container
+``` 
+docker exec -it submarine-server bash
+```
+*  Step5: Modify the value of the configutation **workbench.web.war** in 
conf/submarine-site.xml from "../workbench-web-ng.war" to 
"../workbench-web.war". 
+
+*  Step6: Restart the Submarine Server
+```
+./bin/submarine-daemon.sh restart
+```
+*  Step7: Launch the submarine-server container
+```
+docker start submarine-server
 ```
-docker run -it -p 3306:3306 -d --name submarine-data -e 
MYSQL_ROOT_PASSWORD=password apache/submarine:database-0.3.0
-docker run -it -d --link=submarine-data:submarine-data --name submarine-server 
apache/submarine:submarine-0.3.0
+*  Step8: Open a new **incognito window(not a tab)** and check 
```127.0.0.1:8080``` 
 
 Review comment:
   Thanks for your review. I have fixed it.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to