Ghost NGINX und SSL

Ich hatte mit meinem Setup das Problem, dass man beim Aufruf in einer ‘Redirect Loop’ hängen blieb, sobald ich SSL enabled habe. Folgende Info hat geholfen: Bug: Setting url: to https in config.js causes a redirect loop #2796 von jcones On Nginx I added proxy_set_header X-Forwarded-Proto https; to my site configuration Und es stimmt! So sieht nun der Redirect Teil der NGINX Config aus: location ^~ /blog { proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto https; proxy_set_header Host $http_host; proxy_set_header X-NginX-Proxy true; proxy_pass http://127.0.0.1:2368; proxy_redirect off; } Die config.js muss folgendermassen aussehen: ...

February 18, 2016 · 1 min · pixelchrome

Installation und Konfiguration von Ghost unter FreeBSD und NGINX

Ich benutze auf meinem Server FreeBSD und als Bogging-Software Ghost. Hier ein paar Infos wie man das ans laufen bekommt. Mittlerweile geht das recht schmerzfrei :-) Installieren von Node.js und NPM $ sudo portmaster www/node010 www/npm $ node -v v0.10.40 $ npm -v 2.14.7 Erstellen des Users $ sudo adduser Username: ghost Full name: Ghost Blog User Uid (Leave empty for default): Login group [ghost]: www Login group is www. Invite ghost into other groups? []: Login class [default]: Shell (sh csh tcsh bash rbash zsh rzsh git-shell nologin) [sh]: Home directory [/home/ghost]: /usr/local/www/ghost Home directory permissions (Leave empty for default): Use password-based authentication? [yes]: no Lock out the account after creation? [no]: no Username : ghost Password : <disabled> Full Name : Ghost Blog User Uid : 1002 Class : Groups : www Home : /usr/local/www/ghost Home Mode : Shell : /bin/sh Locked : no OK? (yes/no): y adduser: INFO: Successfully added (ghost) to the user database. Add another user? (yes/no): no Goodbye! Erstellen des Unterverzeichnisses und entpacken $ su - ghost $ pwd /usr/local/www/ghost $ mkdir blog $ cd blog $ unzip /tmp/ghost-0.6.2.zip Installieren $ CXX=c++ npm install sqlite3 --sqlite=/usr/local $ npm install --production --sqlite=/usr/local Anpassen der config.js Datei Ich habe den URL und die Maileinstellungen angepasst ...

February 18, 2016 · 2 min · pixelchrome

NGINX und das SSL Labs A+ Rating

SSL Labs Test Ich habe heute festgestellt das mein Webserver nur ein ‘A’ beim SSL Labs Test bekommen hat. Das musste natürlich auf ein A+ verbessert werden. NGINX Anpassung Keine große Sache. Was fehlte war die HTTP Strict Transport Security (HSTS) Unterstützung. Das sind die zusätzlichen Optionen die gesetzt werden müssen. ## HSTS add_header Strict-Transport-Security max-age=31536000; add_header X-Frame-Options DENY; Und siehe da. Der Webserver bekam das erhoffte ‘A+’ Inconsistent Server Configuration Doch es kam auch eine Warnung. ‘Warning: Inconsistent server configuration’. Der Grund hierfür war leicht ersichtlich. Auf IPv6-Adresse war der Server nicht zu erreichen! ...

September 30, 2015 · 1 min · pixelchrome