import ports/productivity/radicale2, ok jasper@ - data formats changed
and upgrading from radicale 1.x requires exporting from the older version, so it makes sense to carry the two in parallel for a time. --- The Radicale Project is a complete CalDAV calendar server solution, capable of making multiple calendars available to local and remote users, with optional authentication policies. Calendars can be viewed and edited by a calendar client such as Mozilla Lightning Calendar or Evolution. The Radicale Project aims to be a light solution, easy to use, easy to install, easy to configure. As a consequence, it requires few software dependencies and is pre-configured to work out-of-the-box. ---
This commit is contained in:
parent
d48ab67c6d
commit
3e38ef19d4
37
productivity/radicale2/Makefile
Normal file
37
productivity/radicale2/Makefile
Normal file
@ -0,0 +1,37 @@
|
||||
# $OpenBSD: Makefile,v 1.1.1.1 2018/09/11 08:55:27 sthen Exp $
|
||||
|
||||
COMMENT = simple CalDAV calendar server
|
||||
|
||||
MODPY_EGG_VERSION = 2.1.10
|
||||
DISTNAME = Radicale-${MODPY_EGG_VERSION}
|
||||
PKGNAME = ${DISTNAME:L}
|
||||
CATEGORIES = productivity net
|
||||
|
||||
HOMEPAGE = https://radicale.org/
|
||||
|
||||
# GPLv3+
|
||||
PERMIT_PACKAGE_CDROM = Yes
|
||||
|
||||
MODULES = lang/python
|
||||
MODPY_PI = Yes
|
||||
MODPY_SETUPTOOLS = Yes
|
||||
MODPY_VERSION = ${MODPY_DEFAULT_VERSION_3}
|
||||
|
||||
RUN_DEPENDS = devel/py-dateutil${MODPY_FLAVOR}>=2.7.3 \
|
||||
security/py-passlib${MODPY_FLAVOR} \
|
||||
textproc/py-vobject${MODPY_FLAVOR}
|
||||
|
||||
NO_TEST = Yes
|
||||
SUBST_VARS += VARBASE
|
||||
|
||||
pre-configure:
|
||||
@${SUBST_CMD} ${WRKSRC}/radicale/config.py
|
||||
|
||||
post-install:
|
||||
${INSTALL_DATA_DIR} ${PREFIX}/share/{doc,examples}/radicale
|
||||
${INSTALL_DATA} ${WRKSRC}/{COPYING,*.md} ${PREFIX}/share/doc/radicale/
|
||||
${SUBST_DATA} ${WRKSRC}/config ${PREFIX}/share/examples/radicale/config
|
||||
${INSTALL_DATA} ${WRKSRC}/{logging,rights} ${PREFIX}/share/examples/radicale/
|
||||
touch ${PREFIX}/share/examples/radicale/log
|
||||
|
||||
.include <bsd.port.mk>
|
2
productivity/radicale2/distinfo
Normal file
2
productivity/radicale2/distinfo
Normal file
@ -0,0 +1,2 @@
|
||||
SHA256 (Radicale-2.1.10.tar.gz) = 1cYLV93CM/zkJkMHEKPFIcf/1aDwWwLS1M5vZjEZSDI=
|
||||
SIZE (Radicale-2.1.10.tar.gz) = 77790
|
53
productivity/radicale2/patches/patch-config
Normal file
53
productivity/radicale2/patches/patch-config
Normal file
@ -0,0 +1,53 @@
|
||||
$OpenBSD: patch-config,v 1.1.1.1 2018/09/11 08:55:27 sthen Exp $
|
||||
Index: config
|
||||
--- config.orig
|
||||
+++ config
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
# Config file for Radicale - A simple calendar server
|
||||
#
|
||||
-# Place it into /etc/radicale/config (global)
|
||||
+# Place it into ${SYSCONFDIR}/radicale/config (global)
|
||||
# or ~/.config/radicale/config (user)
|
||||
#
|
||||
# The current values are the default ones
|
||||
@@ -36,10 +36,10 @@
|
||||
#ssl = False
|
||||
|
||||
# SSL certificate path
|
||||
-#certificate = /etc/ssl/radicale.cert.pem
|
||||
+#certificate = ${SYSCONFDIR}/radicale/server.crt
|
||||
|
||||
# SSL private key
|
||||
-#key = /etc/ssl/radicale.key.pem
|
||||
+#key = ${SYSCONFDIR}/radicale/private/server.key
|
||||
|
||||
# CA certificate for validating clients. This can be used to secure
|
||||
# TCP traffic between Radicale and a reverse proxy
|
||||
@@ -74,7 +74,7 @@
|
||||
#type = none
|
||||
|
||||
# Htpasswd filename
|
||||
-#htpasswd_filename = /etc/radicale/users
|
||||
+#htpasswd_filename = ${SYSCONFDIR}/radicale/users
|
||||
|
||||
# Htpasswd encryption method
|
||||
# Value: plain | sha1 | ssha | crypt | bcrypt | md5
|
||||
@@ -93,7 +93,7 @@
|
||||
#type = owner_only
|
||||
|
||||
# File for rights management from_file
|
||||
-#file = /etc/radicale/rights
|
||||
+#file = ${SYSCONFDIR}/radicale/rights
|
||||
|
||||
|
||||
[storage]
|
||||
@@ -103,7 +103,7 @@
|
||||
#type = multifilesystem
|
||||
|
||||
# Folder for storing local collections, created if not present
|
||||
-#filesystem_folder = /var/lib/radicale/collections
|
||||
+#filesystem_folder = ${VARBASE}/db/radicale/collections
|
||||
|
||||
# Lock the storage. Never start multiple instances of Radicale or edit the
|
||||
# storage externally while Radicale is running if disabled.
|
46
productivity/radicale2/patches/patch-radicale_config_py
Normal file
46
productivity/radicale2/patches/patch-radicale_config_py
Normal file
@ -0,0 +1,46 @@
|
||||
$OpenBSD: patch-radicale_config_py,v 1.1.1.1 2018/09/11 08:55:27 sthen Exp $
|
||||
Index: radicale/config.py
|
||||
--- radicale/config.py.orig
|
||||
+++ radicale/config.py
|
||||
@@ -87,12 +87,12 @@ INITIAL_CONFIG = OrderedDict([
|
||||
"opposite": ["-S", "--no-ssl"],
|
||||
"type": bool}),
|
||||
("certificate", {
|
||||
- "value": "/etc/ssl/radicale.cert.pem",
|
||||
+ "value": "${SYSCONFDIR}/radicale/server.crt",
|
||||
"help": "set certificate file",
|
||||
"aliases": ["-c", "--certificate"],
|
||||
"type": str}),
|
||||
("key", {
|
||||
- "value": "/etc/ssl/radicale.key.pem",
|
||||
+ "value": "${SYSCONFDIR}/radicale/private/server.key",
|
||||
"help": "set private key file",
|
||||
"aliases": ["-k", "--key"],
|
||||
"type": str}),
|
||||
@@ -133,7 +133,7 @@ INITIAL_CONFIG = OrderedDict([
|
||||
"type": str,
|
||||
"internal": auth.INTERNAL_TYPES}),
|
||||
("htpasswd_filename", {
|
||||
- "value": "/etc/radicale/users",
|
||||
+ "value": "${SYSCONFDIR}/radicale/users",
|
||||
"help": "htpasswd filename",
|
||||
"type": str}),
|
||||
("htpasswd_encryption", {
|
||||
@@ -151,7 +151,7 @@ INITIAL_CONFIG = OrderedDict([
|
||||
"type": str,
|
||||
"internal": rights.INTERNAL_TYPES}),
|
||||
("file", {
|
||||
- "value": "/etc/radicale/rights",
|
||||
+ "value": "${SYSCONFDIR}/radicale/rights",
|
||||
"help": "file for rights management from_file",
|
||||
"type": str})])),
|
||||
("storage", OrderedDict([
|
||||
@@ -162,7 +162,7 @@ INITIAL_CONFIG = OrderedDict([
|
||||
"internal": storage.INTERNAL_TYPES}),
|
||||
("filesystem_folder", {
|
||||
"value": os.path.expanduser(
|
||||
- "/var/lib/radicale/collections"),
|
||||
+ "${VARBASE}/db/radicale/collections"),
|
||||
"help": "path where collections are stored",
|
||||
"type": str}),
|
||||
("max_sync_token_age", {
|
9
productivity/radicale2/pkg/DESCR
Normal file
9
productivity/radicale2/pkg/DESCR
Normal file
@ -0,0 +1,9 @@
|
||||
The Radicale Project is a complete CalDAV calendar server solution,
|
||||
capable of making multiple calendars available to local and remote
|
||||
users, with optional authentication policies. Calendars can be
|
||||
viewed and edited by a calendar client such as
|
||||
Mozilla Lightning Calendar or Evolution.
|
||||
|
||||
The Radicale Project aims to be a light solution, easy to use, easy
|
||||
to install, easy to configure. As a consequence, it requires few
|
||||
software dependencies and is pre-configured to work out-of-the-box.
|
64
productivity/radicale2/pkg/PLIST
Normal file
64
productivity/radicale2/pkg/PLIST
Normal file
@ -0,0 +1,64 @@
|
||||
@comment $OpenBSD: PLIST,v 1.1.1.1 2018/09/11 08:55:27 sthen Exp $
|
||||
@newgroup _radicale:672
|
||||
@newuser _radicale:672:_radicale:daemon:radicale user:/nonexistent:/sbin/nologin
|
||||
@rcscript ${RCDIR}/radicale
|
||||
bin/radicale
|
||||
lib/python${MODPY_VERSION}/
|
||||
lib/python${MODPY_VERSION}/site-packages/
|
||||
lib/python${MODPY_VERSION}/site-packages/Radicale-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/
|
||||
lib/python${MODPY_VERSION}/site-packages/Radicale-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/PKG-INFO
|
||||
lib/python${MODPY_VERSION}/site-packages/Radicale-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/SOURCES.txt
|
||||
lib/python${MODPY_VERSION}/site-packages/Radicale-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/dependency_links.txt
|
||||
lib/python${MODPY_VERSION}/site-packages/Radicale-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/entry_points.txt
|
||||
lib/python${MODPY_VERSION}/site-packages/Radicale-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/requires.txt
|
||||
lib/python${MODPY_VERSION}/site-packages/Radicale-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/top_level.txt
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/__init__.py
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/__main__.py
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/${MODPY_PYCACHE}/
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/${MODPY_PYCACHE}__init__.${MODPY_PYC_MAGIC_TAG}pyc
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/${MODPY_PYCACHE}__main__.${MODPY_PYC_MAGIC_TAG}pyc
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/${MODPY_PYCACHE}auth.${MODPY_PYC_MAGIC_TAG}pyc
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/${MODPY_PYCACHE}config.${MODPY_PYC_MAGIC_TAG}pyc
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/${MODPY_PYCACHE}log.${MODPY_PYC_MAGIC_TAG}pyc
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/${MODPY_PYCACHE}rights.${MODPY_PYC_MAGIC_TAG}pyc
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/${MODPY_PYCACHE}storage.${MODPY_PYC_MAGIC_TAG}pyc
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/${MODPY_PYCACHE}web.${MODPY_PYC_MAGIC_TAG}pyc
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/${MODPY_PYCACHE}xmlutils.${MODPY_PYC_MAGIC_TAG}pyc
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/auth.py
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/config.py
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/log.py
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/rights.py
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/storage.py
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/web/
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/web.py
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/web/css/
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/web/css/icon.png
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/web/css/main.css
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/web/fn.js
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/web/index.html
|
||||
lib/python${MODPY_VERSION}/site-packages/radicale/xmlutils.py
|
||||
share/doc/pkg-readmes/${PKGSTEM}
|
||||
share/doc/radicale/
|
||||
share/doc/radicale/COPYING
|
||||
share/doc/radicale/NEWS.md
|
||||
share/doc/radicale/README.md
|
||||
share/examples/radicale/
|
||||
share/examples/radicale/config
|
||||
@sample ${SYSCONFDIR}/radicale/
|
||||
@sample ${SYSCONFDIR}/radicale/config
|
||||
share/examples/radicale/log
|
||||
@mode 640
|
||||
@owner _radicale
|
||||
@group _radicale
|
||||
@sample ${VARBASE}/log/radicale
|
||||
@mode 700
|
||||
@sample ${VARBASE}/db/radicale/
|
||||
@sample ${SYSCONFDIR}/radicale/private/
|
||||
@mode
|
||||
@owner
|
||||
@group
|
||||
share/examples/radicale/logging
|
||||
@sample ${SYSCONFDIR}/radicale/logging
|
||||
share/examples/radicale/rights
|
||||
@sample ${SYSCONFDIR}/radicale/rights
|
50
productivity/radicale2/pkg/README
Normal file
50
productivity/radicale2/pkg/README
Normal file
@ -0,0 +1,50 @@
|
||||
$OpenBSD: README,v 1.1.1.1 2018/09/11 08:55:27 sthen Exp $
|
||||
|
||||
+-----------------------------------------------------------------------
|
||||
| Running ${PKGSTEM} on OpenBSD
|
||||
+-----------------------------------------------------------------------
|
||||
|
||||
Radicale will run out of the box but with NO SECURITY.
|
||||
|
||||
There are two things you should do to enable security:
|
||||
enable passwords and enable encryption.
|
||||
|
||||
Authentication
|
||||
==============
|
||||
To enable simple passwords, edit ${SYSCONFDIR}/radicale/config and change
|
||||
"type = None" (i.e. passwords are not requested or checked) to
|
||||
"type = htpasswd".
|
||||
|
||||
User password(s) may be created with htpasswd(1); e.g.
|
||||
"htpasswd ${SYSCONFDIR}/radicale/users username". This uses bcrypt
|
||||
which matches Radicale's default.
|
||||
|
||||
By default calendars may only be accessed by their owner. To adjust
|
||||
the rights for calendars please refer to the
|
||||
${SYSCONFDIR}/radicale/rights file and the upstream documentation on
|
||||
"Rights Management".
|
||||
|
||||
For further authentication options, consult Radicale's documentation.
|
||||
Previous users of Radicale 1.x with more complex authentication setup
|
||||
should be aware that only none/htpasswd are provided as standard;
|
||||
plugins are required for others.
|
||||
|
||||
Encryption
|
||||
==========
|
||||
To enable encryption with the internal web server, change "ssl = False"
|
||||
to "ssl = True" in ${SYSCONFDIR}/radicale/config, and install a certificate
|
||||
and key in the files named in "certificate" and "key". (They need to be
|
||||
readable by the _radicale user, so the common location in /etc/ssl/private
|
||||
won't work). Alternatively run HTTP on localhost and proxy from alternative
|
||||
web server software.
|
||||
|
||||
Upgrading from Radicale 1 to 2
|
||||
==============================
|
||||
Storage must be exported from Radicale 1.x before upgrading. This README
|
||||
file is supplied with Radicale 2, so if you are reading it on an installed
|
||||
system, start by uninstalling and reinstalling radicale 1.x, then export:
|
||||
|
||||
# doas -u _radicale ${PREFIX}/bin/radicale --export-storage ${VARBASE}/db/radicale/collections
|
||||
|
||||
Then install radicale 2.x which can use the exported storage directly.
|
||||
For more information, refer to https://radicale.org/1to2/
|
13
productivity/radicale2/pkg/radicale.rc
Normal file
13
productivity/radicale2/pkg/radicale.rc
Normal file
@ -0,0 +1,13 @@
|
||||
#!/bin/ksh
|
||||
#
|
||||
# $OpenBSD: radicale.rc,v 1.1.1.1 2018/09/11 08:55:27 sthen Exp $
|
||||
|
||||
daemon="${TRUEPREFIX}/bin/radicale -d"
|
||||
daemon_user="_radicale"
|
||||
|
||||
. /etc/rc.d/rc.subr
|
||||
|
||||
pexp="${MODPY_BIN} ${daemon}${daemon_flags:+ ${daemon_flags}}"
|
||||
rc_reload=NO
|
||||
|
||||
rc_cmd $1
|
Loading…
x
Reference in New Issue
Block a user