From mboxrd@z Thu Jan 1 00:00:00 1970 From: nee Subject: WIP gnu social package Date: Mon, 25 Sep 2017 23:14:13 +0200 Message-ID: <17b7428d-0a46-6aca-f184-b63890c94cf5@cock.li> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:39995) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dwahw-000397-9O for guix-devel@gnu.org; Mon, 25 Sep 2017 17:14:29 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dwahs-0003wk-1P for guix-devel@gnu.org; Mon, 25 Sep 2017 17:14:28 -0400 Received: from cock.li ([185.100.85.212]:41915) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1dwahr-0003uQ-LT for guix-devel@gnu.org; Mon, 25 Sep 2017 17:14:23 -0400 Content-Language: en-GB List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: guix-devel@gnu.org Hello, I'm currently trying to package gnu social for GuixSD. I made a package that builds the translations and installs gnu social into the store. I also made a service that sets up the config.php file in the /gnu/store and generates an /etc/gnu-social/$site-name/config.php link. The service also has an activation phase in which I run the installer to setup the mariadb database if it doesn't exist. Generally it's working, as it installs and you can post things. For completion it will probably take some time and I came across some general problems, so I thought I might send a WIP report. I have been developing it in my GUIX_PACKAGE_PATH and might send parts like php-fpm to master soon. WIP packages can be seen here: https://hidamari.blue/git/packages/html/gnu-social.scm.html # or clone it, this takes about a minute without any output: git clone https://hidamari.blue/git/packages/ hidamari-blue Here is an example config: http://paste.lisp.org/display/356859 Here are a bunch of issues I have with guixSD in general: - Setting up the database requires the sql root password, the new social_db_user password, and a password for the first admin user to create in gnu social. Having plaintext passwords in /etc/config.scm sounds pretty bad. I'm not sure what the solution here is. - Could we add a password store to guix? It could automatically generate passwords and pass them to services. - Should I generate a script that must be run manually and asks for password input through stdin? - Something else? - The password of the database-user ends up in the config.php which is generated by mixed-text-file. This file can be read by everyone. Can I somehow set the owner on it and remove the reading rights from other users? Here are some other open problems with the packages: - I build php with --enable-intl now, causes a new broken tests to appear. I on a quick look I couldn't figure out what was wrong, and I'm not familiar with php, so I disabled the failing tests. Setting the language in gnu social does not seem to work. Nothing happens, but the installation phase does no longer complain about the missing php module. - A bunch of plugins that are shipped with gs seem to rely on writeable cache directories in their working directory. Those can not be changed through the config file. It will take me some time to find and patch them all. - The admin area must be patched out and all configuration options must be represented by the service. - The following plugins throw warnings: Poll, OpenId, Favorite, Bookmark, DirectMessage those warnings might be related to the php/mariadb versions used with gnu social - common warnings that appear: Warning: Declaration of InviteAction::handle($args) should be compatible with Action::handle() in /gnu/store/qfzqxlfkrzri73jrphlqccsd35s0kcy3-gnu-social-1.2.0-beta4/action= s/invite.php on line 298 Warning: Cannot modify header information - headers already sent by (output started at /gnu/store/qfzqxlfkrzri73jrphlqccsd35s0kcy3-gnu-social-1.2.0-beta4/action= s/invite.php:298) in /gnu/store/qfzqxlfkrzri73jrphlqccsd35s0kcy3-gnu-social-1.2.0-beta4/lib/ac= tion.php on line 1277 The /settings/poll url completely breaks.