If you would like to use F*EX, but you have only one IP and you can't/don't want to use different port there is a solution!

The Morten Minde Neergaard method almost work. In my case I've prepared file (let's say fex.conf) in /etc/httpd/conf.d/:

<VirtualHost 2.3.4.5:80>
    ServerName fex.mydomain.org
    ProxyPass / http://127.0.0.1:88/
    ProxyPreserveHost On
</VirtualHost>

and setup F*EX (/etc/xinetd.d/fex):

service fex
{
        [...]
        bind                    = 127.0.0.1
        port                    = 81
        [...]
}

note I've changed also the port F*EX listen on.

The only thing I had to change in F*EX source code was one line added in lib/fex.pp file:

--- fex.pp-2014-11-01   2013-07-27 01:41:43.000000000 +0200
+++ fex.pp      2014-11-01 00:22:19.384463319 +0100
@@ -137,6 +137,8 @@
     }
   }

+  $port=80;
+
   # use same protocal as uploader for download
   if ($ENV{PROTO} eq 'https' and $port == 443 or $port == 80) {
     $durl = "$ENV{PROTO}://$host/fop";

to fix links to files sent by F*EX to point to port 80 instead of 88. Without this little change links looks like this:

http://fex.mydomain.org:81/fop/NUQLEo5c/testfile.txt

I don't know if there is other method not to sent F*EX port to clients or maybe there are some changes in newest version. I've tested it on, quite old, 20130805 release.

Ten kto umie pisze kod, ten kto nie umie pisze książki..., albo blog.

Pon Wt Śr Czw Pt So N
          1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
eZ Publish™ copyright © 1999-2025 eZ Systems AS