To configure the resin Web mode deployment Project

Source: Internet
Author: User

Written in front, it is recommended to download the resin4.0.47 version. Other versions are not tested

Recently planned to do a small project, then the container selected resin. It is also convenient to update the code by deploying the war file as a Web submission.

Try the latest version of resin (currently the latest version is 4.0.53), submit the war file to WebApps below are the. tmp files. Baidu Google a pass still did not find the solution.

Look at the company's resin version, choose 4.0.47. Downloaded after the discovery of the latest version of the upload problem.

The way to submit a war file via the Web is as follows:

Step One: Modify the resin.properties. the recommended configuration is as follows

Resin.properties

# resin.properties-configuration Variable values# # see Resin.xml, Cluster-default.xml, and health.xml for full Configur ation.# any variable defined by ${...} can is set as a property in this file.# # individual server overrides can be Specif IED by prepending The server.id.# for example, increasing the log level for a individual server:## log_level:info# app- 0.log_level:finest## like Resin XML configuration, modification of this file would trigger# a restart.## general log leve L (Modify resin.xml for more granular log level adjustments) # log_level:finer# Enable verbose browser error reportin  gdev_mode:false# How often Resin should check for updated files.# dependency_check_interval:5m# Enable/resin-doc Resin documentationresin_doc:falseresin_doc_host: # List Triad Server Ip-addresses:hmux-port for each tier, space separated# APP tier Triad servers must be listed to enable Web-tier to # App-tier load-balancing# web-tier Triad servers: web-0 web-1 web-2# web_servers:127.0.0.1:6810# app-tier Triad servers:app-0 app-1 app-2app_servers:127.0.0.1:6800# Configures Resin For a memcached server tier# memcached-tier Triad servers:memcached-0 memcached-1 memcached-2# memcached_servers:12 7.0.0.1:6820# memcached_port:11211# proxycache tier:proxycache-0 proxycache-1 proxycache-2# proxycache_servers:127. 0.0.1:6830# backend_servers:127.0.0.1:80# allow elastic nodes to join the cluster (enable for cloud mode) # elastic _cloud_enable:true# the cluster that elastic nodes should Join-each would contact a Triad server# use a separate resin. Properties file for each clusterhome_cluster:app# used for a elastic server to join the cluster in home_cluster# Elasti c_server:true# Create a distinct webapps/directory for each server, for vertical scaling# elastic_webapp:true# used F Or cloud servers with a dynamic IP addresses where the DNS name for the# Server was assigned after the server starts. Resin would retry the start.# elastic_dns:true# Specifies the--server in the config file# home_server:app-0# Set HTTP and HTTPS bind address# Http_ad           Dress: *# Set HTTP and HTTPS ports.# use overrides for individual server control, for Example:app-0.http:8081app.http : 80app.https:8443web.http:80# web.https:8443# memcached.http:8080# MEMCAC hed.https:8443# proxycache.http:8080# proxycache.https:8443# for security, Resin can switch to a non-root us  Er after binding to port 80setuid_user:setuid_group: # ARG passed directly to the Jvmjvm_args:-xms1500m-xmx1500m -xx:permsize=206m-xx:maxpermsize=206m# Jvm_args:-xmx2048m-xx:maxpermsize=256mjvm_mode:-server# this classpath h As priority over the default classpath, as if you want to# use a third party library like Hibernate ' s jpa# jvm_classpa Th: # Local URLs for the watchdog to check to ensure the server is up,# space separated# http_ping_urls:http://127.0.0.1 /test.jsp# Throttle TheNumber of active threads for a Portport_thread_max:1000accept_thread_max:1000accept_thread_min:200keepalive_max  : 512# Enable JNI TCP speed optimizationstcp_cork:truesendfile:truekeepalive_select_enable:true# OpenSSL Certificate  configuration# Keys is typically stored in the resin configuration directory.# openssl_file:keys/test.crt# Openssl_key  : keys/test.key# openssl_password:changeme# openssl_protocols:-sslv2-sslv3# JSSE certificate configuration# keys are Typically stored in the resin configuration directory.# jsse_keystore_type:jks# jsse_keystore_file:/etc/resin/keys/se rver.keystore# jsse_keystore_password:changeme# in absence of a signed certificate, Resin would fallback to using a # SEL f-signed Development Certificate If HTTPS is enabled# Enable the Proxy-cache-for caching static content in Memoryproxy_c ache_enable:false# sets the proxy cache memory size# proxy_cache_size:256m# enable clustered persistent sessions (for Failover) Session_store: true# Disable the Quercus *.php mapping when using Apache for php# quercus_disable:true# Web-apps named with numeric su Ffixes, e.g Foo-10.0.war and can be browsed# as/foo. When a new version of the Web-app was deployed, Resin continues# to Route active session requests to the previous Web-app V Ersion while# New Sessions go to the new version, so users won't be aware of the# application upgrade.# webapp_multiver sion_routing:true# Set The email address to receive weekly and restart PDF reports# email: [email protected]# pdf_ summary:true# Set a global password to prevent foreign Resin instances from connecting.# must is identical between Web, App, and cache clusters.# cluster_system_key:changeme# Enable remote admin (for remote CLI and for EC2 Ext:triad Discov  ery) # remote_admin_enable:true# enable/resin-admin Web Administration consoleweb_admin_enable:trueweb_admin_host: # Permit access to/resin-admin from Non-local network ip-addressesweb_admin_external:true# Require HTTPS to access/resin-admin# web_admin_ssl:true# Enable resin REST admin# rest_admin_enable:true# Require S SL for REST admin# rest_admin_ssl:true# Access to/resin-admin and remote CLI are password restricted.# use "Resinctl gen Erate-password "and copy/paste here to set the admin# admin_user:admin# Admin_password: {ssha}xxxxxxxx# Enable reading EC2 user data as resin properties# properties_import_url:http://169.254.169.254/latest/user-data


Resin.xml

<id= "youryuming.com"  root-directory= "." >            <  ID= "/"  root-directory= "Webapps/testdeploy"/>     </host>

Step two: Visit https://youryuming.com : 8443/resin-admin/

  Tips: If you do not have a domain name mapping, you can also use the server IP

PS: Why use HTTPS, registration does not use HTTPS also can, through youryuming.com:8443/resin-admin/also can. Uploading the war package later prompts you to use SSL. To avoid trouble simply sign in directly via HTTPS

Click Create configuration file to follow the page prompts to modify the operation, here no longer repeat.

When the Resin container detects a profile modification, it automatically restarts, and when the configuration file is modified, it does not have to close resin or restart.

Step three: Publish the project

Each time the project is deployed, the resin container will automatically restart. Without a manual restart, it feels good to have no ...

To configure the resin Web mode deployment Project

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.