OSX Apache Server: how to redirect the http request?

Hi all

I have a Mini Mac OSX Server El Capitan running. It already serves some sites. Normal Server Web sites:

-site1.example.com

-site2.example.com

Now, I have installed an application that has its own built-in web server. This application would be normally accessible via http on port 80. However, http on port 80 connections are automatically considered trapped by integrated apache of the OSX Server. Therefore, I now put the web application to run in a different port to apache. I also setup a subdomain, so that users can access this application directly, but they also have to type in the port in the URL - for example, the new web app site is reachable at the:

-myapp.example.com:7117

What I would do, is for users to simply access the application using:

-monappli.exemple.com

I know that there is a way for us to have apache to "Reroute" all requests for a specific to an internal port subdomain automatically, but I don't even know where to start. What are the files we need to configure on OSX Server? How configure us them?

Any guidance would be greatly appreciated.

I had the same requirement and has resolved the way you want to as described below.

  1. Define the additional app to run on another port
  2. Create a site in.app using port 80 and the same host name you want to use for the additional application
  3. Set up a redirection for this site in.app as follows
  4. Source = /, Destination = http://hostname.domain.com:1234 /, Status = Permanent (301)

Of course, use the correct host name, the domain and port for your situation.

PS. the same approach I have described above also can be used to redirect the corresponding https port 80 or 443 site.

Tags: Servers and Enterprise Software

Similar Questions

  • [U8.1] how to host OWIN katana Windows store App or how to intercept the http request in windows store app

    Hello

    I have an application that needs its own server to check if the query to this server can be served on-site or even reach the server online for the same thing.

    In fact, my application will have some local files that will be included in the package and part of the content will be responsible for the online server, so my requirement, it's that I want to somehow intercept the request of my application and redirect accordingly.

    You can tell I want to query interceptor or possess oneself by a webserver as OWIN katana inside my windows store app. Alternatively, is there a way to host web on IIS via app store windows application.

    Please let me know what is possible only in App Store Windows as my application should run on all devices for Windows Store Apps support.

    Thanks in advance.

    Hi Sissi,

    Thanks for posting your query in Microsoft Community Forum.

    According to the description of the issue, I recommend you post your query in the TechNet Forums. TechNet is watched by other computing professionals who would be more likely to help you.

    TechNet Forum

    http://social.technet.Microsoft.com/forums/Windows/en-us/home?category=W8

    Hope this information is useful.

  • Redirect the http to https

    I use OS X Server with OS X 10.10.5 5.0.15.

    I have 2 domains pointing to the IP address of my machine OS X Server by using DNS.

    Users.NewSite.com and users.oldsite.com

    The configuration of the domain for the OS X Server machine is users.newwebsite.com

    It comes as the site server configuration and I also have a Web Server (SSL) site configuration as well.

    I have a configuration of the redirect for "Site Web Server" redirect to the website Server (SSL)

    This part does not work properly.

    The problem is with the second field.  If people type in users.oldwebsite.com they get an error message that the connection is not secure.  It seems that the browser is trying to redirect the http://users.oldsite.com to https://users.oldsite.com.

    I need all calls to http://users.oldsite.com to redirect to https://users.newsite.com

    Or really something starting with http://users. should redirect to https://users.newsite.com

    Is this possible with regex?  If so, what the expressions would look like?

    Website of the Apache and the documentation is the canonical source for more information on RewriteRule examples and examples of redirection, mod_alias and mod_rewrite.

    A slightly twisted example of the Apache documentation:

    < VirtualHost *: 443 >

    ServerName undesired.example.com

    ServerAlias example.com notthis.example.com

    Redirect ' / ' "https://www.example.com/".

    < / VirtualHost >

    < VirtualHost *: 443 >

    ServerName www.example.com

    < / VirtualHost >

    The second VirtualHost entry is for the host site for your choice, you will probably already have this present block in your configuration file:

    /Library/Server/Web/config/apache2/httpd_server_app.conf

    There are various examples and discussions of this publication autour of the ' net like this to StackOverflow.

    FWIW, newsite.com and oldsite.com are real and registered areas.

  • How to redirect the page using af: Poll?

    Hi people,

    How to redirect the jsf page to another page, after af:poll run a method?

    For example:

    The user is connected to A page, after 5 minutes of af: poll of the object, an execute method. This method must redirect page A to page B...
    Is this possible?

    Thank you

    Hi William

    Create a pollListenerMethod in backing bean code using a code like this:

    public void poll1_pollListener (PollEvent pollEvent) {}
    ExternalContext ectx is FacesContext.getCurrentInstance () .getExternalContext ();.
    HttpServletResponse response = (HttpServletResponse) ectx.getResponse ();
    response.sendRedirect ("http://domain.com/app/faces/index.jspx");
    }

    Good luck

  • How to set the simultaneous request completed with warning?

    Hi all:
    How to set the simultaneous request completed with warning in oracle 11.5.9?


    For example:

    I completed an application with "Completed" 'Normal '.
    After I put a condition similar to when xxx > 0 then
    It will complete a request indicates 'Complete' 'warning '.



    My environment is: oracle 11.5.9 and operating system is Linux Redhat 4.0



    Concerning
    Terry

    Terry,

    You can use 'FND_CONCURRENT. Function SET_COMPLETION_STATUS.

    Note: 866194.1 - is there a method to return a 'Warning' to host Language simultaneous program status?

    The Oracle Applications Developer's Guide
    http://download-West.Oracle.com/docs/CD/B11454_01/11.5.9/Acrobat/115devg.PDF

    FND_CONCURRENT. SET_COMPLETION_STATUS
    http://forums.Oracle.com/forums/search.jspa?threadID=&q=FND_CONCURRENT.SET_COMPLETION_STATUS&objid=C3&DateRange=all&userid=&NumResults=15&rankBy=10001

    Thank you
    Hussein

  • It is impossible to download software Acrobat pro dc because the "failure of the http request. What can I do?

    It is impossible to download software Acrobat pro dc because the "failure of the http request. What can I do?

    Download & install instructions https://forums.adobe.com/thread/2003339 can help

    -includes a link to access a page to download the Adobe programs if you do not have a disk or drive

    -Cloud desktop http://helpx.adobe.com/creative-cloud/help/creative-cloud-desktop.html

    -Cloud Getting Started https://helpx.adobe.com/creative-cloud.html

    -you will need to enter your original serial number during the installation for non-Cloud programs

    - or kglad links in response to #1 here can help https://forums.adobe.com/thread/2081216

    Also go to https://forums.adobe.com/community/creative_cloud/creative_cloud_faq

  • How to redirect the user account to the correct folder in Documents and Settings?

    Under XP.  One of the user accounts seems to have been directed to the wrong user folder (the one that has been somehow created) in Documents and Settings.  Start menu, My Documents, etc are now empty, but they used to be OK.  The (desired) exact content is always in a folder user, but it is apparently not accessed.  I looked and looked and can't find how to reset the pointer (for example, identify the correct folder for that user).  Any help would be greatly appreciated.

    Hello

    You can try the steps of troubleshooting provided in the link below.

    When you copy a user profile to a folder, the folder attributes are removed in Windows XP and Windows Server 2003

    http://support.Microsoft.com/kb/922381

  • How to redirect the desktop folder to drive D?

    Hi all

     
    Can redirect us the desktop folder to some other drive except C:\ Drive.
    My requirement is, guess I'll put any file in Office that he should save automatically to the player that we have redirected to desktop.
    Hereby, we can save the data of the C drive in another player, so in no longer crashes no need to worry for the backup of data from the office.
    With regard to:
    Rahma

    Hello

    • What version of Winodws XP do you use?

    Unfortunately, it is not possible.

    You can use the backup utility to back up files and folders on a computer that is running Windows XP.

    If you use Windows XP Home Edition, you can refer to the following steps:

    Before you can back up important information on your computer, you must install the backup utility. The backup utility is included on the Windows XP Home Edition CD.

    Note If you do not have the original CD of Windows XP Home Edition of Windows XP was preinstalled on your computer, contact the computer manufacturer or visit the Web site of the manufacturer for more information. You can also use the backup software that you purchase separately.

    To install backup from the Windows XP CD:

    1. Insert your Windows XP CD into the CD or DVD from the computer player.
    2. Click exit.
    3. Locate the: \ValueAdd\Msft\Ntbackup folder on the CD.
    4. Double-click ntbackup.msi to install the backup utility.
    5. When the backup or Restore Wizard prompts you, click Finish.
    6. Remove the Windows XP CD.

    Now that you have installed the backup utility, you are ready to back up your important information.

    If you use Windows XP Professional, to back up your files and folders, follow these steps:

    Note To back up files and folders, you must be connected to the computer as an administrator or as a user who belongs to the Administrators group. To verify that you are connected to Windows with a user account is an administrator on the computer, see the Microsoft Web site at the following address:

    http://support.Microsoft.com/GP/Admin (http://support.microsoft.com/gp/admin)

    Note The following steps explain how to use the backup utility to back up your files and folders manually. You can also use the backup and Restore Wizard to back up your files and folders. However, the steps will be slightly different from those that are listed in the next section.

    Step 1: Open the backup utility

    1. Click Startand then click run.
    2. Type ntbackup.exe in the Open box, and then click OK.

      Note If you receive the following error message, make sure that you followed the steps in the "how to install the backup utility" section correctly:

    Windows cannot find 'ntbackup.exe'.
    Step 2: Select the items to back up and select the location for the backup file
    1. Click Advanced Mode.

    Note If the backup and Restore Wizard, the utility runs in Wizard mode. You can click to clear the always start in Wizard mode check box, and then restart the backup utility. If you continue to use the Restore Wizard and backup, the steps will be slightly different from those that are listed in the next section.

  • Click the backup tab.
  • In the menu of task , click new.
  • Select the check boxes next to the drives you want to back up. If you select files or folders, expand the drive where these files or folders. Then, select the check boxes for the files or folders you want to back up.
  • Select the System State check box that is located under my computer in the navigation pane.

    Note If you want to save settings system and data files, back up all data on your computer and the system state data. The system state data includes the registry, COM + class registration database, files that are under the Protection of files Windows, the boot files and other system files.

  • If it is available to the backup destination list, click the backup destination that you want to use.

    Note If you selected file at this point, type the path and the full name for which you want to back up data in the backup media or file name box.

    You can specify a network share as a destination for the backup file. Generally, backup files have the .bkf file name extension. However, you can use any extension of file name you want.

  • Step 3: Start the backup

    1. To open the backup information dialog box, click Start Backup .
    2. Under If the media already contains backups, perform one of the following:
      • If you want to add this backup file to previous backup files, click append this backup to the media. This option adds the new backup in the existing backup file so that you can keep all the previous backups in a single file. This option is useful if you ever want to restore a backup from a specific day. Be aware that the size of the backup file will increase with each new backup. You can monitor the file size to make sure that it does not fill your hard drive over time. If the file becomes too large, you should consider saving the file on an external hard drive. Or, if you are concerned about the file using too much hard disk space, select replace the data on the media with this backup instead.
      • If you want to replace the files of previous backup with this backup file, click replace the data on the media with this backup. This option is useful if you want to keep the current backup and do not care to keep the previous backups. Or, use this option if you are concerned about the file using too much disk space on your computer.
    3. Click Advanced.
    4. Select the check box Verify data after the backup .
    5. In the Backup Type box, click the type of backup that you want to create. For a description of each type of backup, click the backup type and the description appears under "Description." You can select all of the following types of backup:
      • Normal
      • Copy
      • Incremental
      • Premium
      • Every day
    6. Click OK, and then click Start Backup. A backup progress dialog box appears, and the backup starts.

    Step 4: Leave the backup utility

    1. When the backup is complete, click close.
    2. In the menu of task , click exit.

    See also:

    http://support.Microsoft.com/kb/308422

  • How to publish the http live stream

    When I use Adobe Flash Media Server 4.5 publish live http streams. I found a message from Server Log to manage Adobe Flash Media Console administrator servers. It is said that 'Impossible to record the live stream (disk quota exceeded)."  How can I do to resolve the issue?

    Hello

    Thank you for using the FMS 4.5.

    I assume you are using a developer edition (trail), FMS. It has restriction of 10 minutes for HDS streaming, after which, the journal exceeded disk Quota would come to the top. You must upgrade to the other flavors use HDS full-time.

  • How to change the http port in EBS 12.1.3

    Hi all.

    I configured App & DB to use the port 9 pool during cloning.

    For some reasones, I need to change the port http request 8008 to 8,000, but DB port must remain 1529.

    If I may continue the document: https://support.oracle.com/epmos/faces/DocContentDisplay?id=760590.1 ? My version of the EBS is 12.1.3.

    So I need only change my CONTEXT.xml lines (as in the example below) and run the automatic configuration on the Application layer? :

    < web_port oa_var = "s_webport" oa_type = "PORT" base = "8000" step = range "1" = "-1" label = "Web listening Port" > 8000 < / web_port >

    < activewebport oa_var = "s_active_webport" oa_type = "DUP_PORT" base = "8000" step = range "1" = "-1" label = "Active Web Port" > 8000 < / activewebport >

    < login_page oa_var = "s_login_page" > http://myhost.Oracle.com:8000/OA_HTML/AppsLogin < / login_page >

    < chronosURL oa_var = "s_chronosURL" > http://myhost.Oracle.com:8000/oracle_smp_chronos/oracle_smp_chronos_sdk.gif < / chronosURL >

    < oa_var = "s_endUserMonitoringURL" > http://myhost.Oracle.com:8000/oracle_smp_chronos/oracle_smp_chronos_sdk.gif < / EndUserMonitoringURL >

    < externURL oa_var = "s_external_url" > http://myhost.Oracle.com:8000 < / externURL >

    < httplistenparameter = "s_http_listen_parameter" > 8000 oa_var < / httplistenparameter >

    Thanks in advance.

    Hello

    The approach that you mentioned is correct.

    The document that you referenced is to follow in this case.

    Kind regards

    Bashar

  • How to redirect the URL in block expection Apex 4.2

    Hi team,

    In our application, we wrote this logic as shown below

    Before the point of the process of the header: On Load before header.

    BEGIN
       IF (:p1_display_eid) IS NOT NULL
       THEN
          SELECT modified_date
            INTO :p1_modified_date
            FROM test
           WHERE id = :p1_display_eid;
       END IF;
    exception 
    when no_data_found then
    --Here i need to redirect URL to other screen 
    
    end;
    

    Kind regards

    Sruthitamiri

    Sruthi Tamiri wrote:

    In our application, we wrote this logic as shown below

    Before the point of the process of the header: On Load before header.

    1. BEGIN
    2. IF (: p1_display_eid) IS NOT NULL
    3. THEN
    4. SELECT modified_date
    5. IN: p1_modified_date
    6. OF the test
    7. WHERE ID =: p1_display_eid;
    8. END IF;
    9. exception
    10. When no_data_found then
    11. -Here, I need to redirect the URL to the other screen
    12. end;

    You can do it programmatically by using the owa_util.redirect_url method:

    BEGIN
    
      IF (:p1_display_eid) IS NOT NULL
      THEN
          SELECT modified_date
            INTO :p1_modified_date
            FROM test
          WHERE id = :p1_display_eid;
      END IF;
    
    exception
    
      when no_data_found
      then
          owa_util.redirect('');
          apex_application.stop_apex_engine();
    
    end;
    

    However I don't like the various side effects inherent in this code. It is not obvious to a developer looking at the page that executes a process will result in changing session state or the redirect to a different URL. It may involve additional database access, but I think I would prefer to implement this as a conditional branch by using a condition is no SQL, and a later calculation to set the value of the page...

  • How to set the http and SOCKS proxy

    Hello guys im using this code
    String data = URLEncoder.encode("formName", "UTF-8") + "=" + URLEncoder.encode("formName is true", "UTF-8");
    It works but if I use the http or socks proxy proxy that does not work.
    is it possible to solve this kind of problem?

    Published by: EJP on 26/07/2011-10:49: fixed your misleading title. URLEncoder is completely unrelated to this issue, as several posters have noted.

    Published by: jhovarie on August 19, 2011 23:35

    As opposed to OK?

  • Linux Server (how to record the out command has put on another file.)

    Hi all
    I have Q?
    How do to record the out command put in another file.

    Ex: #ps - ef
    This particular exit cmd I need to record another file.
    is it possible... If possible... Please let me know
    And how to record the history of orders under Linux.

    DF h > /oracle/output.log

    Oracle - name of the mount point

    Concerning
    Asif Kabir

  • I need assistance with the HTTP request procedure

    This is the message I get debug, attempting a HTTPService request as follows
    < mx:Application... initialize = "myService.send ()" >
    Import mx.rpc.events.ResultEvent;
    < mx:HHTPService id = "myService" url = "" data / myInfo.xml "result =" resultHandler (event) "/ >:"

    [SWF] C:\Documents and Settings\ArchiMaster\My Documents\Flex Projects\krsl_corp\bin-debug\krsl_corp.swf - 786 719 bytes after decompression
    [Fault faultString = "HTTP request error" RPC faultCode = "Server.Error.Request" faultDetail ="error: [IOErrorEvent type ="ioError"bubbles = false cancelable = false eventPhase = 2 text =" Error #2032: stream error. "]] ["URL: file:///C:/Documents%20and%20Settings/ArchiMaster/My%20Documents/Flex%20Projects/krsl_cor p/bin-debug/data/ilungas.xml"]. ["URL: data / ilungas.xml"]
    to mx.rpc::AbstractInvoker / http://www.adobe.com/2006/flex/mx/internal:faultHandler () [E:\dev\3.0.x\frameworks\project s\rpc\src\mx\rpc\AbstractInvoker.as:216 ]
    at mx.rpc::Responder/fault() [E:\dev\3.0.x\frameworks\projects\rpc\src\mx\rpc\Responder.as:49]
    at mx.rpc::AsyncRequest/fault() [E:\dev\3.0.x\frameworks\projects\rpc\src\mx\rpc\AsyncRequest .as:103]
    to DirectHTTPMessageResponder / errorHandler ([E:\dev\3.0.x\frameworks\projects\rpc\src\mx\mes saging\channels\DirectHTTPChannel.as:343])
    at flash.events::EventDispatcher/dispatchEventFunction()
    at flash.events::EventDispatcher/dispatchEvent()
    at flash.net::URLLoader/redirectEvent()

    What it means? In addition, I do not use the default workspace, so Flex created only the ".metadata' but not the 'configuration' file, that is why, I had to copy a block as the default workspace. So, how do you get Flex to create two files no matter the location of the workspace? I really need help. Thank you!

    Looks like the error message saying that "data / ilungas.xml ' was not found. You use url = "" data / myInfo.xml ' in your service. " They do not match.

  • Today, I have a problem with the HTTP request

    Well, this time, I try to get an image .png from a URL. To get this I do the following:

    try{   if (CoverageInfo.isOutOfCoverage()){      setError("No hay covertura suficiente de la red");        errorFlag = true; } else{     c = (HttpConnection)Connector.open(url);      is = c.openDataInputStream();     for(int j=0;j
    

    My problem is the second 'try' returns: "java.lang.illegalArgumentException". I don't really know much on HTTP conections, so I don't know that I have a lot of wrong code

    in other words, I'm moving to the java language this short code on the C++ language:

    WebRequest request = System.Net.WebRequest.Create(url);HttpWebResponse response = (HttpWebResponse)request.GetResponse();Stream datos = response.GetResponseStream();Imagen = new Bitmap(datos);pb1.Image = Imagen;datos.Close();response.Close();
    

    can someone help me?

    Thank you RexDoug and peter_strange,

    in the book "java J2ME a tope"-unfortunately or fortunately (for me), it is in Spanish - explain everything about HTTP request and how to interpret correctly the answer. Finally with the following code, I solved my problem:

    try{
        //ask if i have coverage
        if (CoverageInfo.isOutOfCoverage()){
            setError("No hay covertura suficiente de la red");
            errorFlag = true;
        }
        else{
            //create connection
            c = (HttpConnection)Connector.open(url);
            c.setRequestMethod(HttpConnection.GET);
            is = c.openInputStream();
    
            //process response
            if(c.getResponseCode()==HttpConnection.HTTP_OK){
                size = (int)c.getLength();
                if(size != -1){
                    data = new byte[size];
                    is.read(data, 0, data.length);
                    imagen = Bitmap.createBitmapFromBytes(data, 0, -1, 1);
                }
                else{
                    ByteArrayOutputStream byteArray = new ByteArrayOutputStream();
                    int stream;
                    while((stream=is.read())!=-1){
                        byteArray.write(stream);
                    }
                    data = new byte[byteArray.size()];
                    data = byteArray.toByteArray();
                    byteArray.close();
                    imagen = Bitmap.createBitmapFromBytes(data, 0, -1, 1);
                }
            }
            //close connections
            c.close();
            is.close();
        }
    }
    

    This code is similar to the example of rexdoug.

Maybe you are looking for

  • Portege 4000 Slim Battery Bay

    Hello I have a Portege 4000 with a cd/dvd drive. I found batteries that can be used in other Bay slim portable Portege. Is it possible to use a battery 2nd instead of the cd/dvd in my Portege 4000 drive? If Yes, what modelnumber battery have? Where c

  • No expedite EU870D minimap no connection & error 127

    When I start my computer using the version at Pentecost minicards Expite EU870D t-mobile chip, of the chip in the window than t-mobile novatel wireless is ready. When I try to connect I get you message "starts to connect, check and then ready once ag

  • Satellite L450D Webcam does not not after installing new free recovery

    Hello as published in the title of the thread, I have a problem with the built-in webcam in a laptop client. Two days ago, the operating system of this laptop has been damaged by a virus and had to be put back. I tried to install it with the recovery

  • Windows 7 recovery disk will not work!

    OK, so I have a laptop Compaq Presario CQ61 with windows 7 64-bit, and it crashed a few weeks ago. I was told to fix it I would need to order the recovery of best2serve discs so I did and they arrived yesterday. Although earlier, I tried to grab the

  • I am trying to conect my laptop IBM to a T.V. so I can watch video streaming as well as dvd video on TV.

    Quest as above. I've got signiel via a connector special s vido to laptop and RCA cable to the TV screen. Good pictor mobile land back on television. so far. But nothing more. Can you help me complete the process?