You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by al...@manino.com on 2004/11/26 06:02:47 UTC

Tomcat

Hi there,
I would like to access my pages created with applets in Tomcat by typing
the host in the URL and not having to add the default port for Tomcat
(:8080). I have Apache2 and the apache2-jakarta-tomcat connectors
installed.

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Tomcat

Posted by Hassan Schroeder <ha...@webtuitive.com>.
Allen Beacon wrote:

> <Context path="/manager" debug="0" privileged="true"
>          docBase="/usr/local/kinetic/tomcat4/server/webapps/manager">
>          <Valve className="org.apache.catalina.valves.RemoteAddrValve"
>                 allow="127.0.0.1"/>
> </Context>
> 
>  I´m guessing that I should use that inside the manager.xml not the
> tomcat-users.xml.

Yeah. :-)

And in case you've overlooked the "Server Configuration Reference"
section of the docs, I've found these descriptions of the individual
elements and attributes invaluable, e.g. the Context element:

<http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/context.html>

HTH, best of luck,
-- 
Hassan Schroeder ----------------------------- hassan@webtuitive.com
Webtuitive Design ===  (+1) 408-938-0567   === http://webtuitive.com

                           dream.  code.



---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Tomcat

Posted by Allen Beacon <al...@manino.com>.
That´s just what I was looking for, thanks.  You are right, I when I
configured the tomcat-users.xml I read the document so fast that I didn´t
even noticed this:

In addition to the password restrictions the manager web application could
be restricted by the remote IP address or host by adding a RemoteAddrValve
or RemoteHostValve. Here is an example of restricting access to the
localhost by IP address:

<Context path="/manager" debug="0" privileged="true"
         docBase="/usr/local/kinetic/tomcat4/server/webapps/manager">
         <Valve className="org.apache.catalina.valves.RemoteAddrValve"
                allow="127.0.0.1"/>
</Context>

 I´m guessing that I should use that inside the manager.xml not the
tomcat-users.xml.

Thanks for your time.



> Allen Beacon wrote:
>
>> Do you know how to configure the tomcat manager page the one at
>> /opt/jakarta/tomcat/webapps/ROOT> so nobody from the internet can access
>> it but I could get to it, to upload servlets but only locally. I know
>> that
>> I can change the port but that´s not what I´m looking for.
>
> On the HTML manager page, there's a BIG LINK labeled "Manager Help";
> the *first* thing addressed on that page is "Configuring Manager
> Application Access" ...
>
> --
> Hassan Schroeder ----------------------------- hassan@webtuitive.com
> Webtuitive Design ===  (+1) 408-938-0567   === http://webtuitive.com
>
>                            dream.  code.
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: How to map the servlet in web.xml

Posted by Aidas Semezys <ai...@gmail.com>.
You have to declare every servlet with separate <servlet/> element
and map all of them with different url patterns:

<servlet>
    <servlet-name>name_1</servlet-name>
    <servlet-class>class_1</servlet-class>
</servelt>
<servlet>
    <servlet-name>name_2</servlet-name>
    <servlet-class>class_2</servlet-class>
</servelt>
....
<servlet>
    <servlet-name>name_N</servlet-name>
    <servlet-class>class_N</servlet-class>
</servelt>
<servlet-mapping>
    <servlet-name>name_1</servlet-name>
    <url-pattern>url_pattern_1</url-pattern>
</servlet-mapping>
<servlet-mapping>
    <servlet-name>name_2</servlet-name>
    <url-pattern>url_pattern_2</url-pattern>
</servlet-mapping>
...
<servlet-mapping>
    <servlet-name>name_N</servlet-name>
    <url-pattern>url_pattern_N</url-pattern>
</servlet-mapping>

You can not map several servlets on the same url pattern, cause this creates
disambiguity. It is a non-deterministic aproach. And in our context
(Java web application
context) it is not a solvable problem :]] Khe, khe

Peace,
Aidas


inr <ay...@4sight-tech.com> wrote:
> Hai all,
> 
> +--Root
>      +--Web-Inf
>             +--Classes
>                  --HelloWorld.class
>                  +--servlet
>                       +--myservlet
>                             --Myservlet.class
> 
>          I am using the following servlet mapping in my webApplication
> Deployment Descriptor web.xml,  when i attempt to use /justtesting the
> sevlet produces the respone in Browser
> 
>  <servlet>
>         <servlet-name>HelloWorld</servlet-name>
>         <servlet-class>HelloWorld</servlet-class>
>     </servlet>
>     <servlet-mapping>
>         <servlet-name>HelloWorld</servlet-name>
>         <url-pattern>/justtesting</url-pattern>
> </servlet-mapping>
> 
> if i want to map a Group of  Servlet E.g the servlets under the folder
> Root/Web-Inf/Classes/servlet/....
> 
> what i Should do..
> 
> Thanks for ever,
> inr
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Tomcat

Posted by Hassan Schroeder <ha...@webtuitive.com>.
Allen Beacon wrote:

> Do you know how to configure the tomcat manager page the one at
> /opt/jakarta/tomcat/webapps/ROOT> so nobody from the internet can access
> it but I could get to it, to upload servlets but only locally. I know that
> I can change the port but that´s not what I´m looking for.

On the HTML manager page, there's a BIG LINK labeled "Manager Help";
the *first* thing addressed on that page is "Configuring Manager
Application Access" ...

-- 
Hassan Schroeder ----------------------------- hassan@webtuitive.com
Webtuitive Design ===  (+1) 408-938-0567   === http://webtuitive.com

                           dream.  code.



---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Tomcat

Posted by Allen Beacon <al...@manino.com>.
I´ll check the configuration.Thanks
Do you know how to configure the tomcat manager page the one at
/opt/jakarta/tomcat/webapps/ROOT> so nobody from the internet can access
it but I could get to it, to upload servlets but only locally. I know that
I can change the port but that´s not what I´m looking for.
thanks in advance!


> Then you haven't configured it correctly! It is not enough to just install
> it...
> I am using this myself without any problems...
>
> BTJ
>
> Allen Beacon wrote:
>> I have the connector installed but I still need to type :8080 in order
>> to
>> access the applet pages
>>
>>>http://jakarta.apache.org/tomcat/connectors-doc/jk2/index.html
>>>
>>>BTJ
>>>
>>>Allen Beacon wrote:
>>>
>>>>Sorry Quinton I should reply to the list,
>>>>as I told you that could do it.however, I was looking for something
>>>> like
>>>>using a virtual server so my users can use htlm pages from Apache2 and
>>>>servlets from Tomcat and I don´t want to show in the url :8080
>>>>
>>>> I was looking for something like using a virtual server so
>>>>depending of the url the use they will use static html pages from
>>>>apache2
>>>>or servlets from Tomcat.
>>>>
>>>>
>>>>
>>>>>On Friday 26 November 2004 07:02, allen@manino.com wrote:
>>>>>
>>>>>
>>>>>>Hi there,
>>>>>>I would like to access my pages created with applets in Tomcat by
>>>>>>typing
>>>>>>the host in the URL and not having to add the default port for Tomcat
>>>>>>(:8080). I have Apache2 and the apache2-jakarta-tomcat connectors
>>>>>>installed.
>>>>>
>>>>>I created a index.html with a meta-tag in it that automatically
>>>>>redirects
>>>>>the
>>>>>browser to the tomcat port.
>>>>>
>>>>>I needed to keep my Apache for other purposes and changing the default
>>>>>connector of Tomcat to Port 80 was not an option.
>>>>>
>>>>>Here is my code:
>>>>>
>>>>><html>
>>>>>	<head>
>>>>>		<meta http-equiv="refresh"
>>>>>content="1;URL=http://your.server.site:8080/">
>>>>>	</head>
>>>>>	<body>
>>>>>	</body>
>>>>></html>
>>>>>
>>>>>Q
>>>>>--
>>>>>Quinton Delpeche
>>>>>Internal Systems Developer
>>>>>Softline VIP
>>>>>
>>>>>Telephone: +27 12 420 7000
>>>>>Direct:    +27 12 420 7007
>>>>>Facsimile: +27 12 420 7344
>>>>>
>>>>>http://www.vippayroll.co.za/
>>>>>
>>>>>Command, n.:
>>>>>	Statement presented by a human and accepted by a computer in
>>>>>such a manner as to make the human feel as if he is in control.
>>>>>
>>>>
>>>>
>>>>
>>>>---------------------------------------------------------------------
>>>>To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>>>>For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>>>>
>>>
>>>---------------------------------------------------------------------
>>>To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>>>For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>>>
>>>
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Tomcat

Posted by Bjørn T Johansen <bt...@havleik.no>.
Then you haven't configured it correctly! It is not enough to just install it...
I am using this myself without any problems...

BTJ

Allen Beacon wrote:
> I have the connector installed but I still need to type :8080 in order to
> access the applet pages
> 
>>http://jakarta.apache.org/tomcat/connectors-doc/jk2/index.html
>>
>>BTJ
>>
>>Allen Beacon wrote:
>>
>>>Sorry Quinton I should reply to the list,
>>>as I told you that could do it.however, I was looking for something like
>>>using a virtual server so my users can use htlm pages from Apache2 and
>>>servlets from Tomcat and I don´t want to show in the url :8080
>>>
>>> I was looking for something like using a virtual server so
>>>depending of the url the use they will use static html pages from
>>>apache2
>>>or servlets from Tomcat.
>>>
>>>
>>>
>>>>On Friday 26 November 2004 07:02, allen@manino.com wrote:
>>>>
>>>>
>>>>>Hi there,
>>>>>I would like to access my pages created with applets in Tomcat by
>>>>>typing
>>>>>the host in the URL and not having to add the default port for Tomcat
>>>>>(:8080). I have Apache2 and the apache2-jakarta-tomcat connectors
>>>>>installed.
>>>>
>>>>I created a index.html with a meta-tag in it that automatically
>>>>redirects
>>>>the
>>>>browser to the tomcat port.
>>>>
>>>>I needed to keep my Apache for other purposes and changing the default
>>>>connector of Tomcat to Port 80 was not an option.
>>>>
>>>>Here is my code:
>>>>
>>>><html>
>>>>	<head>
>>>>		<meta http-equiv="refresh"
>>>>content="1;URL=http://your.server.site:8080/">
>>>>	</head>
>>>>	<body>
>>>>	</body>
>>>></html>
>>>>
>>>>Q
>>>>--
>>>>Quinton Delpeche
>>>>Internal Systems Developer
>>>>Softline VIP
>>>>
>>>>Telephone: +27 12 420 7000
>>>>Direct:    +27 12 420 7007
>>>>Facsimile: +27 12 420 7344
>>>>
>>>>http://www.vippayroll.co.za/
>>>>
>>>>Command, n.:
>>>>	Statement presented by a human and accepted by a computer in
>>>>such a manner as to make the human feel as if he is in control.
>>>>
>>>
>>>
>>>
>>>---------------------------------------------------------------------
>>>To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>>>For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>>>
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>>For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>>
>>
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Tomcat

Posted by Allen Beacon <al...@manino.com>.
I have the connector installed but I still need to type :8080 in order to
access the applet pages
> http://jakarta.apache.org/tomcat/connectors-doc/jk2/index.html
>
> BTJ
>
> Allen Beacon wrote:
>> Sorry Quinton I should reply to the list,
>> as I told you that could do it.however, I was looking for something like
>> using a virtual server so my users can use htlm pages from Apache2 and
>> servlets from Tomcat and I don´t want to show in the url :8080
>>
>>  I was looking for something like using a virtual server so
>> depending of the url the use they will use static html pages from
>> apache2
>> or servlets from Tomcat.
>>
>>
>>>On Friday 26 November 2004 07:02, allen@manino.com wrote:
>>>
>>>>Hi there,
>>>>I would like to access my pages created with applets in Tomcat by
>>>> typing
>>>>the host in the URL and not having to add the default port for Tomcat
>>>>(:8080). I have Apache2 and the apache2-jakarta-tomcat connectors
>>>>installed.
>>>
>>>I created a index.html with a meta-tag in it that automatically
>>> redirects
>>>the
>>>browser to the tomcat port.
>>>
>>>I needed to keep my Apache for other purposes and changing the default
>>>connector of Tomcat to Port 80 was not an option.
>>>
>>>Here is my code:
>>>
>>><html>
>>>	<head>
>>>		<meta http-equiv="refresh"
>>>content="1;URL=http://your.server.site:8080/">
>>>	</head>
>>>	<body>
>>>	</body>
>>></html>
>>>
>>>Q
>>>--
>>>Quinton Delpeche
>>>Internal Systems Developer
>>>Softline VIP
>>>
>>>Telephone: +27 12 420 7000
>>>Direct:    +27 12 420 7007
>>>Facsimile: +27 12 420 7344
>>>
>>>http://www.vippayroll.co.za/
>>>
>>>Command, n.:
>>>	Statement presented by a human and accepted by a computer in
>>>such a manner as to make the human feel as if he is in control.
>>>
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Tomcat

Posted by Bjørn T Johansen <bt...@havleik.no>.
http://jakarta.apache.org/tomcat/connectors-doc/jk2/index.html

BTJ

Allen Beacon wrote:
> Sorry Quinton I should reply to the list,
> as I told you that could do it.however, I was looking for something like
> using a virtual server so my users can use htlm pages from Apache2 and
> servlets from Tomcat and I don´t want to show in the url :8080
> 
>  I was looking for something like using a virtual server so
> depending of the url the use they will use static html pages from apache2
> or servlets from Tomcat.
> 
> 
>>On Friday 26 November 2004 07:02, allen@manino.com wrote:
>>
>>>Hi there,
>>>I would like to access my pages created with applets in Tomcat by typing
>>>the host in the URL and not having to add the default port for Tomcat
>>>(:8080). I have Apache2 and the apache2-jakarta-tomcat connectors
>>>installed.
>>
>>I created a index.html with a meta-tag in it that automatically redirects
>>the
>>browser to the tomcat port.
>>
>>I needed to keep my Apache for other purposes and changing the default
>>connector of Tomcat to Port 80 was not an option.
>>
>>Here is my code:
>>
>><html>
>>	<head>
>>		<meta http-equiv="refresh"
>>content="1;URL=http://your.server.site:8080/">
>>	</head>
>>	<body>
>>	</body>
>></html>
>>
>>Q
>>--
>>Quinton Delpeche
>>Internal Systems Developer
>>Softline VIP
>>
>>Telephone: +27 12 420 7000
>>Direct:    +27 12 420 7007
>>Facsimile: +27 12 420 7344
>>
>>http://www.vippayroll.co.za/
>>
>>Command, n.:
>>	Statement presented by a human and accepted by a computer in
>>such a manner as to make the human feel as if he is in control.
>>
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Tomcat

Posted by Allen Beacon <al...@manino.com>.
Sorry Quinton I should reply to the list,
as I told you that could do it.however, I was looking for something like
using a virtual server so my users can use htlm pages from Apache2 and
servlets from Tomcat and I don´t want to show in the url :8080

 I was looking for something like using a virtual server so
depending of the url the use they will use static html pages from apache2
or servlets from Tomcat.

> On Friday 26 November 2004 07:02, allen@manino.com wrote:
>> Hi there,
>> I would like to access my pages created with applets in Tomcat by typing
>> the host in the URL and not having to add the default port for Tomcat
>> (:8080). I have Apache2 and the apache2-jakarta-tomcat connectors
>> installed.
>
> I created a index.html with a meta-tag in it that automatically redirects
> the
> browser to the tomcat port.
>
> I needed to keep my Apache for other purposes and changing the default
> connector of Tomcat to Port 80 was not an option.
>
> Here is my code:
>
> <html>
> 	<head>
> 		<meta http-equiv="refresh"
> content="1;URL=http://your.server.site:8080/">
> 	</head>
> 	<body>
> 	</body>
> </html>
>
> Q
> --
> Quinton Delpeche
> Internal Systems Developer
> Softline VIP
>
> Telephone: +27 12 420 7000
> Direct:    +27 12 420 7007
> Facsimile: +27 12 420 7344
>
> http://www.vippayroll.co.za/
>
> Command, n.:
> 	Statement presented by a human and accepted by a computer in
> such a manner as to make the human feel as if he is in control.
>


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Tomcat

Posted by Quinton Delpeche <qu...@vippayroll.co.za>.
On Friday 26 November 2004 07:02, allen@manino.com wrote:
> Hi there,
> I would like to access my pages created with applets in Tomcat by typing
> the host in the URL and not having to add the default port for Tomcat
> (:8080). I have Apache2 and the apache2-jakarta-tomcat connectors
> installed.

I created a index.html with a meta-tag in it that automatically redirects the 
browser to the tomcat port.

I needed to keep my Apache for other purposes and changing the default 
connector of Tomcat to Port 80 was not an option.

Here is my code:

<html>
	<head>
		<meta http-equiv="refresh" content="1;URL=http://your.server.site:8080/">
	</head>
	<body>
	</body>
</html>

Q
-- 
Quinton Delpeche
Internal Systems Developer
Softline VIP

Telephone: +27 12 420 7000
Direct:    +27 12 420 7007
Facsimile: +27 12 420 7344

http://www.vippayroll.co.za/

Command, n.:
	Statement presented by a human and accepted by a computer in
such a manner as to make the human feel as if he is in control.

Re: Tomcat

Posted by su...@manino.com.
aa

> Hi there,
> I would like to access my pages created with applets in Tomcat by typing
> the host in the URL and not having to add the default port for Tomcat
> (:8080). I have Apache2 and the apache2-jakarta-tomcat connectors
> installed.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org