Flyspray: Difference between revisions

From Alpine Linux
(Created page with "{{Draft}} =Installing Flyspray= {{Cmd|apk add flyspray}} =Database support= Flyspray supports only MySQL and PostgreSQL. Here we cover MySQL installation, but the steps ar...")
 
(replace /etc/init.d with rc-service)
 
(4 intermediate revisions by 3 users not shown)
Line 1: Line 1:
{{TOC right}}
{{Draft}}
{{Draft}}


Line 38: Line 39:
Now, you should enable PHP/FastCGI support modifying Lighttpd configuration.
Now, you should enable PHP/FastCGI support modifying Lighttpd configuration.


You can find it in /etc/lighttpd.
You can find it in {{path|/etc/lighttpd}}.


{{Cmd|vi /etc/lighttpd/lighttpd.conf}}
{{Cmd|vi /etc/lighttpd/lighttpd.conf}}
Line 46: Line 47:
   ...
   ...


{{Cmd|/etc/init.d/lighttpd start}}
{{Cmd|rc-service lighttpd start}}


If your server does not run, you can find information in /var/log/lighttpd. If that does not provide a clue you can also run Lighttpd in foreground. It should display some more debug information.
If your server does not run, you can find information in {{path|/var/log/lighttpd}}. If that does not provide a clue you can also run Lighttpd in foreground. It should display some more debug information.


{{Cmd|/etc/init.d/lighttpd stop
{{Cmd|rc-service lighttpd stop
lighttpd -f /etc/lighttpd/lighttpd.conf -D}}
lighttpd -f /etc/lighttpd/lighttpd.conf -D}}


Line 56: Line 57:
=Flyspray configuration=
=Flyspray configuration=


Now that everything is ready, you need to make Flyspray visible to the webserver. For doing that, create a symlink from /usr/share/webapps/flyspray (that is the default location where flyspray is installed) to /var/www/localhost/htdocs.
Now that everything is ready, you need to make Flyspray visible to the webserver.  
For doing that, create a symlink from {{path|/usr/share/webapps/flyspray}} (that is the default location where flyspray is installed) to {{path|/var/www/localhost/htdocs}}.
This is the document root directory of lighttpd server. If you use another webserver, check what is the document root and put the symlink there.
This is the document root directory of lighttpd server. If you use another webserver, check what is the document root and put the symlink there.


Line 63: Line 65:
Flyspray needs permission to write on flyspray.conf.php that is in the root directory.
Flyspray needs permission to write on flyspray.conf.php that is in the root directory.


{{Cmd|touch /usr/share/webapps/flyspray/flyspray.conf && chmod 775 /usr/share/webapps/flyspray/flyspray.conf.php  
{{Cmd|touch /usr/share/webapps/flyspray/flyspray.conf  
chgrp www-data /usr/share/webapps/flyspray/flyspray.conf}}
chmod 775 /usr/share/webapps/flyspray/flyspray.conf.php  
chgrp www-data /usr/share/webapps/flyspray/flyspray.conf.php}}


That's all.
That's all.


Open your browser to http://$FLYSPRAY_SERVER/flyspray and follow the instruction.
Open your browser to <nowiki>http://$FLYSPRAY_SERVER/flyspray</nowiki> and follow the instruction.
 
 
[[category:Programming]]

Latest revision as of 10:21, 17 November 2023

This material is work-in-progress ...

Do not follow instructions here until this notice is removed.
(Last edited by Sertonix on 17 Nov 2023.)

Installing Flyspray

apk add flyspray

Database support

Flyspray supports only MySQL and PostgreSQL. Here we cover MySQL installation, but the steps are basically the same with PostgreSQL.

Install Database support

apk add flyspray-mysqli

Notice that even though flyspray-mysql package is available, if you install it Flyspray will report that the function library is deprecated, that is quite annoying.

Is better to use mysqli package.

Now before we continue we need to create the database.

create database flyspray; create user 'flyspraydbuser'@'localhost' identified by 'my_password'; grant all privileges on flyspray.* to 'flyspraydbuser'@'localhost';

If you need mysql client, you can install it like this:

apk add mysql-client

You can of course also use a tool like phpmyadmin to create the database and setup the user.


Setup Lighttpd

Now our database is ready, we need to install and configure Lighttpd, with PHP support.

apk add lighttpd

Now, you should enable PHP/FastCGI support modifying Lighttpd configuration.

You can find it in /etc/lighttpd.

vi /etc/lighttpd/lighttpd.conf

 ... 
 include "mod_fastcgi.conf"
 ...

rc-service lighttpd start

If your server does not run, you can find information in /var/log/lighttpd. If that does not provide a clue you can also run Lighttpd in foreground. It should display some more debug information.

rc-service lighttpd stop lighttpd -f /etc/lighttpd/lighttpd.conf -D


Flyspray configuration

Now that everything is ready, you need to make Flyspray visible to the webserver. For doing that, create a symlink from /usr/share/webapps/flyspray (that is the default location where flyspray is installed) to /var/www/localhost/htdocs. This is the document root directory of lighttpd server. If you use another webserver, check what is the document root and put the symlink there.

ln -s /usr/share/webapps/flyspray /var/www/localhost/htdocs/flyspray

Flyspray needs permission to write on flyspray.conf.php that is in the root directory.

touch /usr/share/webapps/flyspray/flyspray.conf chmod 775 /usr/share/webapps/flyspray/flyspray.conf.php chgrp www-data /usr/share/webapps/flyspray/flyspray.conf.php

That's all.

Open your browser to http://$FLYSPRAY_SERVER/flyspray and follow the instruction.