Resin Documentationapp server |
deployment from the command-line
.war files can be deployed to a cluster using the Resin command-line. The uploaded file will be distributed to all Resin servers. For security reasons, Resin's deployment must be enabled in the resin.xml. The default behavior is to disable deployment. The configuration has four requirements:
<resin xmlns="http://caucho.com/ns/resin" xmlns:resin="urn:java:com.caucho.resin"> <cluster id="app-tier"> <resin:AdminAuthenticator password-digest="none"> <user name="foo" password="test"/> </resin:AdminAuthenticator> <resin:RemoteAdminService/> <resin:DeployService/> <server id="" port="6800"> <http port="8080"/> </server> <host id=""> <web-app-deploy path="webapps" expand-preserve-fileset="WEB-INF/work/**"/> </host> </cluster> </resin> deploy for default hostThe "deploy" command deploys a .war file to the default virtual host. Since the AdminAuthenticator requires a user and password, you'll need to pass those arguments as well. unix> resinctl deploy hello.war undeploy for default hostThe "undeploy" command removes a .war from the default virtual host. Since the AdminAuthenticator requires a user and password, you'll need to pass those arguments as well. unix> resinctl undeploy hello deploy with specified hostThe "deploy" command allows a "-host" argument to specify a virtual host. unix> resinctl deploy -host www.example.com hello.war undeploy for www.example.comThe "undeploy" command removes a .war from the virtual host. unix> resinctl undeploy -host www.example.com hello Command line deployment capabilities were introduced in Resin 4.0.14. The set of commands allows deploying, undeploying, listing applications deployed on the server and controlling application lifecycle. Synopsis of the provided commands and options
deploying applicationDeploying an application is done with a resinctl deploy [options] <war-file> unix> resinctl deploy /projects/hello-world/hello-world.war Deployed production/webapp/default/hello-world as hello-world.war to http://127.0.0.1:8080/hmtp
listing deployed applicationsListing deployed applications is done with a resinctl deploy-list [options] unix> resinctl deploy-list production/webapp/default/hello-world copy application from context '/hello-world' to context '/foo'Copying an applicaiton is done with a resinctl deploy-copy [options] resinctl deploy-copy -source hello-world -target foo copied production/webapp/default/hello-world to production/webapp/default/foo
undeploying applicationUndeploying an application is done with an resinctl undeploy [options] <name> unix> resinctl undeploy undeploy foo Undeployed foo from http://127.0.0.1:8080/hmtp
starting applicationStarting an application is done with a unix> resinctl webapp-start [options] <name> unix> resinctl webapp-start foo 'production/webapp/default/foo' is started
stopping applicationStopping an application is done with an resinctl webapp-stop [options] <name> unix> resinctl webapp-stop foo 'production/webapp/default/foo' is stopped
restarting applicationRestarting an application is done with an resinctl webapp-restart [options] <name> unix> resinctl webapp-restart foo 'production/webapp/default/foo' is restarted
|