问题
I have setup Worklight Studio in my local Machine and developed a sample application. I need to deploy that application to a Worklight Server set up in another PC in the same network (LAN).
回答1:
You already have a server in your local machine - Worklight Studio contains an internal Worklight Server. But that doesn't matter...
If you are using Worklight 5.x:
- Open
application-descriptor.xml
- Find the
worklightServerRootURL
element - Change its value to that of the remote Worklight Server, for example:
http://myotherserver:8080
- Right-click on the application folder and choose: Run As >> Build All and Deploy
- Take the
*-all.wlapp
and/or*.adapter
files from the bin folder and deploy them via Worklight Console that resides in the other server machine.
If you are using Worklight 6.0:
- Right-click on the application folder and choose: Run As >> Build for Remote Server
- Enter the details of the other server machine (host, port, context root)
- Take the
*-all.wlapp
and/or*.adapter
files from the bin folder and deploy them via Worklight Console that resides in the other server machine.
The above assumes that the remote server(s) are configured to accept the applications and/or adapters you will deploy (that is, that you have deployed the .war file of the project; your scenario was not very detailed so my explanations were somewhat lexing).
来源:https://stackoverflow.com/questions/17585522/ibm-worklight-how-to-connect-to-another-worklight-server-located-in-another-ma