Template:Installation/Head: Difference between revisions
m (Correct 'Serious' box for guide selection) |
(Make it necessary to choose mode and DB manually.) |
||
Line 1: | Line 1: | ||
<div style="display:none;"> | <div style="display:none;"> | ||
{{#vardefine:DB|{{#urlget:db| | {{#vardefine:DB|{{#urlget:db|}}}} | ||
{{#vardefine:mode|{{#urlget:mode| | {{#vardefine:mode|{{#urlget:mode|}}}} | ||
{{#vardefine:mode_prefix|{{#ifeq: {{#var:mode}}|development||RAILS_ENV={{#var:mode}} <nowiki/>}}}} | {{#vardefine:mode_prefix|{{#ifeq: {{#var:mode}}|development||RAILS_ENV={{#var:mode}} <nowiki/>}}}} | ||
{{#vardefine:env_string|{{#var:mode_prefix}}}}}} | {{#vardefine:env_string|{{#var:mode_prefix}}}}}} | ||
Line 18: | Line 18: | ||
== Versions of this guide == | == Versions of this guide == | ||
{{Serious|Make sure to use the correct version of the guide, see below.}} | <!-- {{Serious|Make sure to use the correct version of the guide, see below.}} | ||
The current guide is for a '''{{#switch: {{#var:mode}}|production=production|development=development}}''' setup | The current guide is for a '''{{#switch: {{#var:mode}}|production=production|development=development}}''' setup | ||
with '''{{#switch: {{#var:DB}}|mysql=MySQL|postgres=PostgreSQL|mariadb=MariaDB}}''' as database. | with '''{{#switch: {{#var:DB}}|mysql=MySQL|postgres=PostgreSQL|mariadb=MariaDB}}''' as database. | ||
You can change them below: | You can change them below: --> | ||
Running mode: {{#ifeq: {{#var:mode}}|production|'''Production'''|[[{{FULLPAGENAME}}?db={{#var:DB}}&mode=production|Production]]}} | {{#ifeq: {{#var:mode}}|development|'''Development'''|[[{{FULLPAGENAME}}?db={{#var:DB}}&mode=development|Development]]}}<br /> | |||
{{#ifeq: {{#var:mode}}||| | |||
Database: {{#ifeq: {{#var:DB}}|mysql|'''MySQL'''|[[{{FULLPAGENAME}}?db=mysql&mode={{#var:mode}}|MySQL]]}} | {{#ifeq: {{#var:DB}}|postgres|'''PostgreSQL'''|[[{{FULLPAGENAME}}?db=postgres&mode={{#var:mode}}|PostgreSQL]]}} | {{#ifeq: {{#var:DB}}|mariadb|'''MariaDB'''|[[{{FULLPAGENAME}}?db=mariadb&mode={{#var:mode}}|MariaDB]]}} | |||
Line 32: | Line 33: | ||
== Prepare the system == | == Prepare the system == | ||
}} |
Revision as of 14:25, 27 August 2016
Introduction
This guide will outline the procedure to get you set up with a -ready installation of diaspora*.
Things to know
- The install is a bit complex, but we're here to help.
It's extremely helpful to have some experience in Linux/Unix server administration or Rails app deployment already. But don't worry, if you run into problems and need help, just visit us in our IRC channels on Freenode. - Running a common setup will get you the most help, if you need it.
Most people in the community will have some experience running diaspora* with Unicorn as the app server using Nginx as outward-facing web server. Of course, you're free to run any other app server (Thin, Passenger...) or web server (Apache), but you might find it harder to get help if you run into unexpected troubles. - diaspora* is developed utilizing latest web standards
Therefore UX is best with recent browsers, so please update your Firefox, Opera, Chrome or Safari to the newest version. We do not currently support any version of Internet Explorer, though we won't reject any contributions attempting to change that circumstance. - diaspora* strongly recommends HTTPS
as we encrypt communication amongst servers and to the client browsers. You can get a free TLS certificate from Let's Encrypt.
Unfortunately, self-signed certificates or certificates issued by CACert won't work. - We need your feedback
to constantly improve and update this guide. Have a look at How we communicate - Do not run any of the commands you find in this guide as root (except if requested).
Just use your normal user - or even better - create a separate user for diaspora* (rationale).
Before you start
You need to choose if you want a production setup or development setup. Diaspora has three development trees: master, stable and develop. The master tree always contains the current release. The stable tree is where new features and bug fixes are added before a new minor version is released. The develop tree is where new features and bug fixes are added before a new major version is released. Therefore if you want a development setup you should run from develop. But it isn't guaranteed to be in a good state, so it's not recommended to run a production setup from it.
Diaspora is written in Ruby on Rails and therefore knows different running modes. These have nothing to do with running from the master or the develop tree. Nonetheless we recommend the development mode for development setups and production mode for production setups. The difference is, apart from a slightly different default configuration, speed. The development mode reloads the code on each request, so it speeds up your development. The production mode doesn't do that, so pages load significantly faster. That's the only major difference you need to care about. To emphasize it one more time: Running a production setup in development mode gains you nothing.
Lastly you can choose between running on MySQL/MariaDB or PostgreSQL, in our experience PostgreSQL achieves a better performance.
Versions of this guide
Running mode: Production | Development