Hi friends.

have been implementing a cluster system using HAProxy with the scheme
something like:

............................................................................................→
(10.0.1.53) OwnCloud1
Internet→(IP Public) Firewall (Forward) → (10.0.1.51) Haproxy
............................................................................................→
(10.0.1.54) OwnCloud2

When the configuration of apache server has the DocumentRoot in
/var/www/html/ then I can log in using the address "
https://ip_address/owncloud";, but when I use DocumentRoot
/var/www/html/owncloud and try with the address "https://ip_address/"; then
I receive a 503 response. I've attached my configuration files.

Please, What is wrong? I need to use owncloud with something like
https://ip_address/ without any other directory.

Best regards,
Pepo.
<VirtualHost *:80>
    ServerAdmin webmaster@localhost

    DocumentRoot /var/www/html/
    # If use DocumentRoot /var/www/html/owncloud it fails

    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined
    <Directory /var/www/html/owncloud>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride All
        Require all granted
    </Directory>
</VirtualHost>
# vim: syntax=apache ts=4 sw=4 sts=4 sr noet

global
        log /dev/log    local0
        log /dev/log    local1 notice
        chroot /var/lib/haproxy
        stats socket /run/haproxy/admin.sock mode 660 level admin
        stats timeout 30s
        user haproxy
        group haproxy
        daemon

        # Default SSL material locations
        ca-base /etc/ssl/certs
        crt-base /etc/ssl/private

        # Default ciphers to use on SSL-enabled listening sockets.
        # For more information, see ciphers(1SSL). This list is from:
        #  https://hynek.me/articles/hardening-your-web-servers-ssl-ciphers/
        ssl-default-bind-ciphers 
ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:ECDH+AES128:DH+AES:ECDH+3DES:DH+3DES:RSA+AESGCM:RSA+AES:RSA+3DES:!aNULL:!MD5:!DSS
        ssl-default-bind-options no-sslv3
        tune.ssl.default-dh-param 2048

defaults
        mode                    http
        log                     global
        option                  httplog
        option                  dontlognull
        option                  http-server-close
        option  forwardfor      except 127.0.0.0/8
        option                  redispatch
        retries                 3

        timeout http-request    10s
        timeout queue           1m
        timeout connect         10s
        timeout client          1m
        timeout server          10m
        timeout http-keep-alive 10s
        timeout check           10s

        maxconn                 50000
        errorfile       400     /etc/haproxy/errors/400.http
        errorfile       403     /etc/haproxy/errors/403.http
        errorfile       408     /etc/haproxy/errors/408.http
        errorfile       500     /etc/haproxy/errors/500.http
        errorfile       502     /etc/haproxy/errors/502.http
        errorfile       503     /etc/haproxy/errors/503.http
        errorfile       504     /etc/haproxy/errors/504.http

listen stats :8118
        mode http
        stats enable
        stats hide-version
        stats uri /stats
        stats realm Haproxy\ Statistics
        stats auth haproxy:redhat               # Credentials for HAProxy 
Statistic report page.

frontend LB
        bind *:80
        reqadd X-Forwarded-Proto:\ http
        default_backend LB

frontend LBS
        bind *:443 ssl crt /etc/ssl/private/owncloudsite.pem
        reqadd X-Forwarded-Proto:\ https
        rspadd Strict-Transport-Security:\ max-age=31536000;\ 
includeSubDomains;\ preload
        default_backend LB

backend LB *:80
        redirect scheme https if !{ ssl_fc }
        mode    http
        balance source
        option  httpchk
        option  httpclose
        option  forwardfor
        cookie  LB insert
        server  cloud1 10.0.1.53:80 cookie cloud1 check
        server  cloud2 10.0.1.54:80 cookie cloud2 check

_______________________________________________
User mailing list
[email protected]
http://mailman.owncloud.org/mailman/listinfo/user

Reply via email to