Last change
on this file since 34453 was 30437, checked in by davidb, 8 years ago |
Notes taken while setting up on an EC2 instance
|
File size:
1.3 KB
|
Line | |
---|
1 | # The following are the notes taken while setting up system-based Tomcat7 on Ubuntu 14.4LTS
|
---|
2 |
|
---|
3 | ######
|
---|
4 | # Following based on
|
---|
5 | # http://coenraets.org/blog/2011/11/set-up-an-amazon-ec2-instance-with-tomcat-and-mysql-5-minutes-tutorial/
|
---|
6 |
|
---|
7 | # 1. Setup Tomcat
|
---|
8 | sudo apt-get install tomcat7
|
---|
9 |
|
---|
10 | cp -i "$GSDL3SRCHOME/lib/jni/*.jar" /usr/share/tomcat7/lib/.
|
---|
11 |
|
---|
12 | cp -i "$GSDL3SRCHOME/lib/jni/*.so" /usr/lib/jni/.
|
---|
13 |
|
---|
14 | # 2. Obtain fixed domain name through Elastic IP
|
---|
15 |
|
---|
16 | #The public DNS address changes when you restart your instance. To get a permanent IP address, click Elastic IPs in the AWS Management Console (left navigation bar), allocate a new IP address and associate it with your instance.
|
---|
17 |
|
---|
18 |
|
---|
19 | # 3. Set up custom TCP port in Seurity Group in AWS EC2 interfae
|
---|
20 |
|
---|
21 | # (pick the group your instance VM is associated with)
|
---|
22 |
|
---|
23 |
|
---|
24 | # 4. Start up your tomcat service
|
---|
25 |
|
---|
26 | sudo service tomcat7 start
|
---|
27 |
|
---|
28 | #######
|
---|
29 | # To run on port 80 ...
|
---|
30 |
|
---|
31 | # Notes from
|
---|
32 | # http://stackoverflow.com/questions/4756039/how-to-change-the-port-of-tomcat-from-8080-to-80
|
---|
33 |
|
---|
34 | #1. Change port from 8080 to 80
|
---|
35 | # sudo vi /var/lib/tomcat7/conf/server.xml
|
---|
36 | # <Connector connectionTimeout="20000" port="8080" protocol="HTTP/1.1" redirectPort="8443"/>
|
---|
37 |
|
---|
38 | # 2. Edit tomcat7 file
|
---|
39 |
|
---|
40 | # sudo vi /etc/default/tomcat7
|
---|
41 |
|
---|
42 |
|
---|
43 | # finishing with
|
---|
44 |
|
---|
45 | sudo touch /etc/authbind/byport/80
|
---|
46 | sudo chmod 500 /etc/authbind/byport/80
|
---|
47 | sudo chown tomcat7 /etc/authbind/byport/80
|
---|
Note:
See
TracBrowser
for help on using the repository browser.