Installing www/radicale 0.8.1 from ports, configured with HTTP and with LDAP in jail environment results in the following error; ===> Registering installation for py27-radicale-0.8_1 [webmail] Installing py27-radicale-0.8_1... ===> Creating users and/or groups. Using existing group 'radicale'. Using existing user 'radicale'. install: mkdir share: Read-only file system pkg-static: POST-INSTALL script failed The only read-only mounted file systems on host are /usr/jails/basejail on /usr/jails/webmail/basejail (nullfs, local, read-only) /usr/local/etc/ssl on /usr/jails/webmail/usr/local/etc/ssl (nullfs, local, read-only) The jail's mount is mounted read-write: pool0/jails/webmail on /usr/jails/webmail (zfs, local, noatime, nfsv4acls) ezjail-admin was used creating the jail called "webmail".
How do you expect adding users on a readonly filesystem? the radicale package needs to create a user to it needs to access the filesystem.
(In reply to Baptiste Daroussin from comment #1) The entire file system is not mounted read-only as shown at pool0/jails/webmail on /usr/jails/webmail (zfs, local, noatime, nfsv4acls) Other ports that registers new users/groups are able to install.
(In reply to patrik from comment #2) besides, the adding of the user is not the problem, but rather creating a directory as seen in "install: mkdir share: Read-only file system"
Created attachment 153700 [details] Potential patch for issue # # py-radicale-0.8_1 # Install from public pkg repo, note the failure and /usr/local/share/radicale not being created # root@test-jail:/usr/ports/www/radicale # pkg install www/radicale Updating FreeBSD repository catalogue... FreeBSD repository is up-to-date. All repositories are up-to-date. The following 1 packages will be affected (of 0 checked): New packages to be INSTALLED: py27-radicale: 0.8_1 The process will require 326 KiB more space. 59 KiB to be downloaded. Proceed with this action? [y/N]: y [test-jail] Fetching py27-radicale-0.8_1.txz: 100% 59 KiB 60.1kB/s 00:01 Checking integrity... done (0 conflicting) [test-jail] [1/1] Installing py27-radicale-0.8_1... ===> Creating users and/or groups. Using existing group 'radicale'. Using existing user 'radicale'. [test-jail] [1/1] Extracting py27-radicale-0.8_1: 100% install: mkdir share: Read-only file system pkg: POST-INSTALL script failed root@test-jail:/usr/ports/www/radicale # ll /usr/local/share/ total 37 drwxr-xr-x 2 root wheel 3 Mar 2 21:39 aclocal/ drwxr-xr-x 4 root wheel 4 Mar 2 21:39 apache24/ drwxr-xr-x 3 root wheel 3 Mar 2 21:39 apr/ drwxr-xr-x 8 root wheel 8 Mar 2 23:43 doc/ drwxr-xr-x 4 root wheel 4 Mar 3 00:05 examples/ drwxr-xr-x 2 root wheel 3 Mar 2 21:37 gettext/ drwxr-xr-x 40 root wheel 40 Mar 3 00:16 licenses/ drwxr-xr-x 44 root wheel 45 Mar 2 21:37 locale/ drwxr-xr-x 3 root wheel 3 Mar 2 21:39 php/ drwxr-xr-x 3 root wheel 3 Mar 2 21:08 zsh/ # # py-radicale-0.8_2 # Install of patched version, use @dir keyword and remove @dirrm and @dirrmtry keywords, remove errant tab for portlint and use @sample keywords. # root@test-jail:/usr/local/etc # pkg install www/radicale Updating myrepo repository catalogue... [test-jail] Fetching meta.txz: 100% 260 B 0.3kB/s 00:01 [test-jail] Fetching packagesite.txz: 100% 136 KiB 139.7kB/s 00:01 Processing entries: 100% myrepo repository update completed. 502 packages processed Checking integrity... done (0 conflicting) The following 1 packages will be affected (of 0 checked): New packages to be INSTALLED: py27-radicale: 0.8_2 The process will require 326 KiB more space. Proceed with this action? [y/N]: y [test-jail] [1/1] Installing py27-radicale-0.8_2... ===> Creating users and/or groups. Using existing group 'radicale'. Using existing user 'radicale'. [test-jail] [1/1] Extracting py27-radicale-0.8_2: 100% root@test-jail:/usr/local/etc # ll radicale/ total 24 -rw-r--r-- 1 root wheel 3702 Mar 3 00:28 config -rw-r--r-- 1 root wheel 3702 Mar 3 00:28 config.sample -rw-r--r-- 1 root wheel 1034 Mar 3 00:28 logging -rw-r--r-- 1 root wheel 1034 Mar 3 00:28 logging.sample root@test-jail:/usr/local/etc # ll /usr/local/share/ total 37 drwxr-xr-x 2 root wheel 3 Mar 2 21:39 aclocal/ drwxr-xr-x 4 root wheel 4 Mar 2 21:39 apache24/ drwxr-xr-x 3 root wheel 3 Mar 2 21:39 apr/ drwxr-xr-x 8 root wheel 8 Mar 2 23:43 doc/ drwxr-xr-x 4 root wheel 4 Mar 3 00:05 examples/ drwxr-xr-x 2 root wheel 3 Mar 2 21:37 gettext/ drwxr-xr-x 40 root wheel 40 Mar 3 00:30 licenses/ drwxr-xr-x 44 root wheel 45 Mar 2 21:37 locale/ drwxr-xr-x 3 root wheel 3 Mar 2 21:39 php/ drwxr-xr-x 2 radicale radicale 2 Mar 3 00:28 radicale/ drwxr-xr-x 3 root wheel 3 Mar 2 21:08 zsh/
Created attachment 153701 [details] Poudriere bulk -t log for py27-radicale
Regarding the attached patch, the port currently uses this in its pkg-plist @exec /usr/bin/install -d -o radicale %%DATADIR%% This doesn't seem to cause an error when installed on a normal host but it does not result in the /usr/local/share/radicale directory that the port is using as its local config directory being created. In a jail (ezjail for me) the error seen by the PR opener can be seen with the same result of the config directory not being available. Patch for maintainer review resolves that by using the @dir keyword, removes the @dirrm and @dirrmtry as they are considered deprecated, uses the @sample keyword for config files, and removes an errant tab for portlint.
(In reply to jason.unovitch from comment #6) Thanks, the patch resolves the problem with creating the required directory.
Thanks for the report and patch. It looks good so far.
A commit references this bug: Author: feld Date: Thu Mar 5 13:39:51 UTC 2015 New revision: 380491 URL: https://svnweb.freebsd.org/changeset/ports/380491 Log: Fix issue with creating DATADIR Modernize: @dir, @sample PR: 198210 Changes: head/www/radicale/Makefile head/www/radicale/pkg-plist