Hey guys i'm having a bit of a problem with the setup i'm trying to get to.
I've got tomcat running on 8080 and apache2 running on 80, and i'm a bit lost as to how i can get apache to forward to tomcat for specific files. I'm setting up webgoat as a link on my apache homepage
EX:
127.0.0.1 -> Goes to homepage
Homepage has links to webgoat at 127.0.0.1:8080/WebGoat/attack
I'm trying to set this up as a home pen test server for myself, i want to trying to add as much capability and since having php work with tomcat is a bit ... Out of wack, i'd rather have php running with apache2 and then just link to tomcat for my java type files.
Thanks.
EDIT: Yes i have looked at the other questions on here from before and it seems like they aren't pertaining to the same thing i am. And the ones that did were very old.
Create a .htaccess file on your apache and add:
# Redirect old file path to new file path
Redirect /olddirectory/oldfile.html http://example.com:8080/newdirectory/newfile.html
Related
I installed a java EE application on Openshift V3 (migrated from v2 to v3 recently)
I have a running java pod and all the function seems to work fine over web.
Almost all the openshift settings are default
All my work is on image:
jws30-tomcat8-basic-s2i
My biggest trouble right now is, I am not able to determine the location of all stdout from my java application deployed on server (I dont have any personal logger, I am just doing System.out.println at various places... I know poor me)
I went on to check "logs" directory in the pod-terminal and no files were present there.
I was wondering where is this file (containing all std outs) getting generated ?
(I understand if somebody would need more information like some env. variable or something, let me know I will get it...altho like I said 'vanilla openshift v3 tomcat').
There are two places for you to check the standard logs. On the command line:
oc logs PODID
On the web console you can view the logs as well for a pod by looking at the pod detail. If you want a collated view of all logs for all pods (and aggregated logging is enabled for the cluster), click on the archive link when viewing a pods logs.
I am a total newb at this and I want to learn. I have a webapp running in a docker container currently on Ubuntu 16.04TLS. I can connect to it over the Internet and it works fine. I want to run an Apache frontend in a separate container and enable SSL. I worked on this for 8 hours today and I know I was close. I had to restore the VM in the end so i could put the webapp back online.
I followed this tutorial https://medium.com/#jmarhee/running-multiple-web-applications-on-a-docker-host-with-apache-85f673f02803 and was successful at being able to connect to Apache (I got the default home page with the install) but was unable to get Apache to proxy for Tomcat. I got a 503 error when I enabled the proxy pass through. I am all about reading if you folks are good with pointing me in the right direction. Since I want to learn, I may come back with more questions. I did read another article http://stackoverflow.com/questions/24319662/from-inside-of-a-docker-container-how-do-i-connect-to-the-localhost-of-the-mach but I did not understand how to apply it to my situation.
TIA for any help you can provide me with.
I have successfully installed Tomcat 7 using cPanel on IWEB server. I got the installation successful message too. I am able to hit the tomcat home page using www.domain.com:8080 and it directs me to Tomcat's home page. You may take a look at http://67.205.89.174:8080/
The main challenge is, in order to access Manager App, I need admin credentials, which should ideally be found in /root/usr/local/jakarta/..../tomcat-users.xml
When I connect to 67.205.89.174 using WinSCP, I don't see any "jakarta" folder located there.
This is my first time I am trying to host a website and everything is new to me. I am doing my self study by going through some online documentations, blogs, videos etc.. related to cPanel-Tomcat 7 installation.
I would appreciate any help by guru's online here so that it can drastically save my time.
Thanks in advance!
Tomcat 7 configuration directory is /usr/local/easy/share/easy-tomcat7/conf and you can check your user configuration in /usr/local/easy/share/easy-tomcat7/conf/tomcat-users.xml file.
We are having issues with our deployment. We need to deploy to a remote TomCat-container which is accessed through IIS 8.5 with the TomCat Connector from Apache. We followed the guide at the following resources when we installed the connector:
https://confluence.atlassian.com/pages/viewpage.action?pageId=376210448#ConfiguringTomcat-ConnectorforIIS8.0(WindowsServer2012orWindows8)-Step1.InstallandConfiguretheAJPConnector
File size is not too big for IIS 8.5 (the file size is 50mb)
http://tomcat.apache.org/connectors-doc/webserver_howto/iis.html
Of what we can see, the .war file gets uploaded but when it should be deployed, we are returned a 404 page, telling us that the page doesnt exist and the application is not deployed.
Things we have checked and double checked is the configuration for:
File size limits in TomCat configuration (the file is not too big for TomCat)
Security Access for the TomCat service user (NETWORK SERVICES), so that TomCat has access to the folders it needs for unpacking the .war etc.
Alot of other things while we were grasping for some answer
The logs of TomCat and IIS doesnt give a clue to why this issue exists, we can see that we accessed the manager and performed a PUT operation, nothing else... we have set the log level to FINE, still no clue. Logs of IIS does also not give any clues to what the issue is.
We are thinking that the issue lies within IIS 8.5 and the connector but we cant find it.
Thankful for anything that you might think could be a potential issue. Are there any other connectors for TomCat 7.0.55 / IIS 8.5 that might be better?
Thanks / David
Hmm, the issue was really related to max upload-sizes in IIS 8.5
We read in the documentation that IIS 8.5 has 2gb as upload limits but as I posted the question above I thought that I just had to double check it. It was set to 30mb... Its always some trivial answer... Im leaving this here in case someone else gets the same issue
Had the same problem, deploying from maven using tomcat plugin was returning 404 ([ERROR] Tomcat return http status error: 404, Reason Phrase: Not Found).
Indeed, the problem was the "Maximum allowed content length", that was ~30MB.
This value can by changed on: The site > Request Filtering > [Actions Panel] > Edit Feature Settings.
I'm sharing because almost 3 years have passed and this question brought some light to my problem
I've been using XAMP and it's features for some php sites and it's working fine. I'm now needing to use it for JSP development for a project we're about to start working on.
So far it's functioning on my local machine in that I downloaded the sample war file from Tomcat and it deploys fine and is visible when using localhost:8080/sample.
The problem is that I can't seem to access it from a browser using the domain name. I tried www.mydomain.com/sample but receive a 404 error.
The same when using my local IP address instead.
I've searched online for a while now and have come across a few sources that hint at integrating apache with tomcat but nothing concrete enough to try and get a working solution.
I've also tried (and miserably failed) to watch the video that is referenced in a few other questions.
Any help is hugely appreciated,
Thanks.
that's because tomcat works on port 8080 unlike apache - when you run php sites they are just behind the apache which is visible on port 80 (which the default one in browsers), you can go through "http://mydomain.com:8080/sample" and it would work the same as through localhost
you can also change tomcat's settings and change it's connector's port from 8080 to 80, and then it would work as you expected