Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have succeeded in installing Diaspora* on my subdomain diaspora.mattaydin.com. I have VPS running CentOS 5.7 with Plesk installed.

By means of an vhost.conf and vhost_ssl.conf file I, (with the help of another gentleman) have managed to reverse proxy the app.

vhost.conf:

ServerName diaspora.mattaydin.com
ServerAlias *.diaspora.mattaydin.com

<Directory /home/diaspora/diaspora/public>
Options -Includes -ExecCGI
</Directory>
DocumentRoot /home/diaspora/diaspora/public

RedirectPermanent / https://diaspora.mattaydin.com

vhost_ssl.conf

ServerName diaspora.mattaydin.com
DocumentRoot /home/diaspora/diaspora/public

RewriteEngine On

RewriteCond %{DOCUMENT_ROOT}/%{REQUEST_FILENAME} !-f
RewriteRule ^/(.*)$ balancer://upstream%{REQUEST_URI} [P,QSA,L]

<Proxy balancer://upstream>
BalancerMember http://127.0.0.1:3000/
</Proxy>

ProxyRequests Off
ProxyVia On  
ProxyPreserveHost On
RequestHeader set X_FORWARDED_PROTO https

<Proxy *>
Order allow,deny
Allow from all
</Proxy>

<Directory /home/diaspora/diaspora/public>
Options -Includes -ExecCGI
Allow from all
AllowOverride all
Options +Indexes
</Directory>

DocumentRoot /home/diaspora/diaspora/public

Basically it's working. However, the only thing that's not working are the assets. The do not get loaded not the server, as seen on diaspora.mattaydin.com

The error messages I get in the access_ssl.log are a lot of: 11/Dec/2012:19:04:05 +0100] "GET /robots.txt HTTP/1.1" 404 2811 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_2) AppleWebKit/536.26.17 (KHTML, like Gecko) Version/6.0.2 Safari/536.26.17"

The error messages I get from diaspora's log file is:

Started GET "//assets/branding/logo_large.png" for 77.250.99.193 at 2012-12-11 20:13:11 +0100

ActionController::RoutingError (No route matches [GET] "/assets/branding/logo_large.png"): lib/rack/chrome_frame.rb:39:in call' lib/unicorn_killer.rb:35:incall'

Hope you guys can help me out. If you need anything else please let me know

Thanks in advance,

Matt

UPDATE: Ok, I updated the vhost_ssl.conf file with some help of another gent.

Here it is:

ServerName diaspora.mattaydin.com
DocumentRoot /home/diaspora/diaspora/public
#AliasMatch ^(uploads|assets)/(.*)$ /home/diaspora/diaspora/public/$1/$2

ProxyPass /assets !
ProxyPass /uploads !
ProxyPass / balancer://upstream

<Proxy balancer://upstream>
BalancerMember http://127.0.0.1:3000/
</Proxy>

ProxyRequests Off
ProxyVia On  
ProxyPreserveHost On
RequestHeader set X_FORWARDED_PROTO https

<Proxy *>
Order allow,deny
Allow from all
</Proxy>

<Directory /home/diaspora/diaspora/public>
Options -Includes -ExecCGI
Order allow,deny
Allow from all
AllowOverride all
Options +Indexes
</Directory>

Now the error messages in error.log say:

[Tue Dec 11 22:26:23 2012] [error] [client 77.250.99.193] (13)Permission denied: access to /assets/icons/pen_write.png denied, referer: https://diaspora.mattaydin.com/

And a lot more of the same messages.

Hope it helps solving the issue. Thanks!

share|improve this question
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.