Move Confluence to subdomain (no port) on JIRA server, with Tomcat - windows

I'm using both JIRA and Confluence on the same server, running on Windows, using Apache Tomcat.
I have two domains pointing at the server, jira.company.com and confluence.company.com.
JIRA is running fine on port 80 in the Apache Tomcat instance, and I can get to that on the JIRA.company.com domain just fine.
Confluence is currently running on port 8090 on the same machine. What I'm trying to do is get Confluence working on the confluence.company.com domain.
Most of the documentation I can see is about configuring virtual hosts and reverse proxies in httpd.conf, however in Apache Tomcat all I have to work with is the server.xml file.
I understand I can add another host to the JIRA server.xml file to point to a different docBase for Confluence, but I have a feeling this breaks Atlassian's own recommendations found here.
When I add an additional host entry into Confluence's server.xml it's ignored, and the confluence.company.com domain sends me through to JIRA.
I've done some searching and found similar questions but they don't seem to apply to my configuration - they all mention httpd.conf which isn't present on my server.
My questions:
Can I run Confluence on the subdomain by adding an extra entry in JIRA's server.xml? If possible, is this bad?
Is there another way to get my Confluence Apache instance listening on port 80 but on it's own domain name?
I can do all this on IIS with my eyes shut, but in Apache/Tomcat I'm a little lost. Thanks in advance!

Tomcat is not really meant to directly handle incoming requests as usually an Apache or other proxy is put in front of it to hide the ports and provide other useful features you would need for Single Sign On etc. Note that there is a difference between the Apache Webserver, which is commonly only called "Apache" and "Apache Tomcat", which is only an application server made by the Apache Foundation community and named "Tomcat". Tomcat only supports basic webserver functionality.
In any case, you can use the IIS as a webserver and proxy to forward the requests and at the same time hide the ports of the applications. I personally haven't used IIS but Atlassian offers a thorough explanation for the Confluence and/or JIRA integration with IIS as a proxy: https://confluence.atlassian.com/adminjiraserver071/integrating-jira-applications-with-iis-802593039.html
The page covers JIRA for the most part but section 4 also has additional information if you want to hook up both JIRA and Confluence on the same server, which is exactly your use case.

Related

Apache HTTP Server vs Oracle HTTP Server

What is the difference between Apache HTTP Server and Oracle HTTP Server. What are the advantages/disadvantages of using Apache server , Oracle HTTP Server? Any insight into it is really appreciated.
Thanks,
Narendra
It's helpful to know that Oracle HTTP Server (OHS) is the Apache HTTP Server (Apache). Specifically OHS is Apache 2.2.22 including critical bug fixes from higher Apache versions. https://docs.oracle.com/middleware/1213/webtier/HSADM/intro_ohs.htm#HSADM102
* This has been updated with OHS 12.2.1 now to Apache 2.4.
https://docs.oracle.com/middleware/1221/webtier/administer-ohs/whats_new.htm#HSADM1277
OHS includes the WebLogic Server Proxy plugin (mod_wl_ohs) which brings frontend hosting to WebLogic application servers. OHS also includes configuration from the Fusion Middleware Control. Aside, this is of dubious value because you'll be editing the httpd.conf file through the advanced server configuration pages. An additional plus on the OHS side is all of the scripts and setup are generally in one place so there's less assembly of different bits such as with Apache. Finally, the control of OHS rests with the NodeManager daemon (usually) so that's one place to control WLS "Machines".
Bottom line OHS: OHS is a kinder-gentler way to be introduced to a slightly older version of Apache if you don't know Apache well. WLS plugins are included and if you're a WebLogic admin the Oracle docs are better. OHS is licensed by Oracle so it's not necessarily free, certainly not for support.
So to Apache's advantages. Since the mod_wl_ohs plugin can be downloaded separately, it can also be incorporated in an Apache installation. The configuration of the plugin is as involved as "normal" Apache httpd.conf edits, which is to say above-average complexity for those who have never worked with Apache HTTP Server. The server is also controlled from either init.d or systemd directly, as opposed to being controlled by nodemanager (which in turn is controlled by init.d/systemd).
Bottom line Apache: If you're a sysadmin who has already invested a lot in Apache, adding the WLS proxy plugin is pretty straight forward and you've gained everything OHS has to offer. But you'll have to kit it together yourself if you're a WLS administrator. Apache is licensed under the Apache 2.0, which is sort of a way of saying it's "free".
I will kindly direct you here.
Its also important to note that if you maintain a valid support contract with Oracle and you user their HTTP server they will support that tier as well. So its another way you can lump as many products as you can into a support contract.

Port forward requests from 80 to respective ports

I have many spring boot jars running in different ports. Say 9087-9090. I have a domain say
mydomain.com.
I can access mydomain.com:9087/ and use the application. Also mydomain.com:9088/ and use another application but how can i use them just like mydomain.com and still map them to desired ports. What is the technical term for this.
I use digitalocean hosting and have a Ubuntu 14.04 x64 Box. I'm running Java 7 in it.
You need a reverse proxy (a.k.az front end load balancer) with URL rewriting. I'm not sure what you hosting solution offers or permits, but you could try nginx or Apache httpd if you want something running locally. There are also service providers you might be able to use outside your host.

How do I specify the host for links in mail notifications in Gitlab?

I have gitlab running behind a proxy, gitlab itself running on port 3000 not accessible from outside.
Mail notifications generated by gitlab always contain URLs with port 3000 in them, so where can I configure gitlab to generate links accessible from outside?
I already found
gitlab email setup
but I do not have email:host: or anything like that in my gitlab.yml
I'm running gitlab 5.2.0 right now.
EDIT: I would also appreciate any link to some info about the config options in gitlab.yml...
The setting is indeed in gitlab/config/gitlab.yml, it just isn't that clear anymore (config names and comments changed in gitlab 5.0 I think).
The section ## Web Server Settings is actually used to generate the links in emails. The only settings referring to emails are email_from: and support_email: but host:, port: and https: are also used for links in emails.
The actual IP and port settings can be found in puma.rb config file which is why I was confident enough to just tinker around with the gitlab.yml settings and it worked.
Solution for my problem: just comment the production:gitlab:port: setting or change it to your external port.

polygraph for https via proxy server

Can anyone help me setup web polygraph for testing an HTTPS servers via proxy servers in middle
linux machine:192.168.21.7
proxy server :192.168.21.9
https server : 192.168.21.11
This link contains the needed information:
http://www.web-polygraph.org/docs/userman/simple.html
Basically polygraph has couple files which are bundled with it and use for testing.
The manual I gave you give example that uses polysrv but on different distributions you will probably have different names for the tool(on ubuntu it's polygraph-server and polygraph-client)
You need to set the listening service ip+port outgoing "robot" ip and then start it using command line.
For https setup we will configure our pg file on server and client with SslWrap module.
Details of same can be found in http://www.web-polygraph.org/docs/reference/models/ssl.html

Reverse Proxy on Windows

I have a web server that responds to a number of different sites on port 80. Currently, IIS does the mapping to various sites via host headers, but I'd like to be able to serve other web apps on port 80 hosted in Jetty or Tomcat. IIS prevents that by grabbing all port 80 traffic.
I basically need a reverse proxy to just change the port number to something that another app stack can listen in on. I was looking into nginx but it seems to not be quite ready for prime time on Windows. Eventually I may set up a Linux box specifically for this, but for now I'm interested in a solution which will run all on the same box.
All I really need is something very light which mostly just matches hostname/port and allows rewriting of the port. Does anyone have any suggestions?
If you are running in IIS 7 or above you can use Application Request Routing for that: http://www.iis.net/download/ApplicationRequestRouting
For IIS 5-6, it looks like Apache Tomcat Connector (JK 1.2) is a clean solution. This is an IIS ISAPI filter which allows IIS to act as a reverse proxy for other web servers. It uses Apache JServ Protocol (AJP) to communicate with the app server actually serving requests. Both Tomcat and Jetty implement AJP. URLs are mapped with regex-like config to a particular AJP server instance.
Overview: http://www.iisadmin.co.uk/?p=40&page=3
IIS Config: http://tomcat.apache.org/connectors-doc/reference/iis.html
Mapping Config: http://tomcat.apache.org/connectors-doc/reference/workers.html
This ISAPI plug-in also works with IIS 7.x, but in that case the Application Request Routing (see marked answer) should be considered as it might work better with non-AJP servers.

Resources