Commit graph

48 commits

Author SHA1 Message Date
Andras Timar
dddfd415ec Fix Debian dependency on dh-systemd
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I366c94b4328c97972efc276da20846c3a7c7d4a7
2021-08-16 13:58:52 +02:00
Andras Timar
d714f1bb34 deb: revert systemplate compatibility checks, they don't work well in postinstall script
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I4cad095d167e56ceadf83fc7c7ade222da36a5b1
2021-05-18 15:39:56 +02:00
Andras Timar
aa7797cb7b deb: do not display error message when user removes loolwsd package
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I8d4d05f1e99ad80ac5fff6325ef515d96d0ca764
2021-05-18 15:39:12 +02:00
Andras Timar
85bda6dc11 deb: compatibility with older systemd versions
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I3a4b168cb72ff400cd6b921f0305808eef0420d9
2021-05-17 15:50:02 +02:00
Andras Timar
3c1767b290 LOKit's installation path does not contain version number any more
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: If3ae865f1d19ccba2a13c4c31faa7aff8274d34b
2021-05-04 13:14:15 +02:00
Andras Timar
41c5cddc3d forward port packaging bits to master branch
The next version of Collabora Online will be version 2021.
Development of version 2021 will be carried on master branch
for the time being.
The corresponding core branch is distro/collabora/co-2021

Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I9c97aaac711c9e1f1e48ed25066b169ea7e26e84
2021-03-31 18:29:49 +02:00
Andras Timar
34ce7a1045 compat level 10 by default restarts service after upgrade -- this is what we want for minimal downtime
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I4302e3619a254b9437eee613c45fa860581407bf
2021-03-18 15:06:34 +01:00
Andras Timar
92f44a4695 On-disk cache was removed long ago, clean-up in packaging
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I2eeaed12af6ac8789151b95a9c2a2aa1fd72573b
2021-01-26 21:10:50 +01:00
Andras Timar
23fe1b3bc5 add CAP_CHOWN to systemd service files
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I3270cc1c435c419117cfa805a4db16ca4ef9a3ec
2021-01-06 11:39:01 +01:00
Michael Meeks
317dffb817 Optimize copy of jails to hard-linking with new capability.
In some cases we cannot do a fast bind-mount of the files we want
in our jail since we don't have cap_sys_admin for loolmount inside
eg. docker.

Thus we need to fallback to hard-linking, however various security
systems namespace parts of our tree, such that link() fails with
EXDEV even across the (apparently) same file-system.

As such we need to assemble a copy of what we want to hard-link
close to our jails. However, this needs to be owned by root / the
system to avoid having writable files shared between jails. Hence
we need cap_chown in addition to cap_fowner, to get ownership right
and then hard-link.

Change-Id: Iba0ef46ddbc1c03f3dc7177bc1ec1755624135db
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2021-01-04 15:05:36 +00:00
Andras Timar
3f81bfd987 Add /var/log (default log path) to ReadWritePaths of loolwsd.service (fixes GH #739)
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I47e8a0983fd74656739498bf02bad117e821cfbf
2020-11-20 20:19:43 +01:00
Andras Timar
4b29a54803 loolmount requires cap_sys_admin
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: Ic7df285bacc684af4167c8f2301118341e859d0f
2020-11-20 09:20:16 +01:00
Aron Budea
b59fa6b753 Sync loolwsd.service between '/' and 'debian/'
One is used in Debian-based installs, other is used in the rest.

Signed-off-by: Aron Budea <aron.budea@collabora.com>
Change-Id: If21c5d70cb8bb738931c3cd05bd4c5c732f394f7
2020-11-18 16:14:17 +01:00
Andras Timar
34bc966d68 change product name
Change-Id: Ic34d324c952364442d3f4f9f0758676ab57c8a9a
2020-10-02 14:18:28 +02:00
Andras Timar
322eaf5814 systemplate files are not writable by lool user
See also f1be65668c
systemplate files should not be writable by lool user

Change-Id: I5684248d3d4b4b0ba56f8c5ab490a6e7df0e0038
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/98069
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Tested-by: Jenkins
Reviewed-by: Andras Timar <andras.timar@collabora.com>
2020-07-05 13:28:28 +02:00
Ashod Nakashian
5c9988f2e3 wsd: faster jail setup via bind-mount
loolmount now works and supports mounting and
unmounting, plus numerous improvements,
refactoring, logging, etc..  When enabled,
binding improves the jail setup time by anywhere
from 2x to orders of magnitude (in docker, f.e.).

A new config entry mount_jail_tree controls
whether mounting is used or the old method of
linking/copying of jail contents. It is set to
true by default and falls back to linking/copying.
A test mount is done when the setting is enabled,
and if mounting fails, it's disabled to avoid noise.

Temporarily disabled for unit-tests until we can
cleanup lingering mounts after Jenkins aborts our
build job. In a future patch we will have mount/jail
cleanup as part of make.

The network/system files in /etc that need frequent
refreshing are now updated in systemplate to make
their most recent version available in the jails.
These files can change during the course of loolwsd
lifetime, and are unlikely to be updated in
systemplate after installation at all. We link to
them in the systemplate/etc directory, and if that
fails, we copy them before forking each kit
instance to have the latest.

This reworks the approach used to bind-mount the
jails and the templates such that the total is
now down to only three mounts: systemplate, lo, tmp.

As now systemplate and lotemplate are shared, they
must be mounted as readonly, this means that user/
must now be moved into tmp/user/ which is writable.

The mount-points must be recursive, because we mount
lo/ within the mount-point of systemplate (which is
the root of the jail). But because we (re)bind
recursively, and because both systemplate and
lotemplate are mounted for each jails, we need to
make them unbindable, so they wouldn't multiply the
mount-points for each jails (an explosive growth!)
Contrarywise, we don't want the mount-points to
be shared, because we don't expect to add/remove
mounts after a jail is created.

The random temp directory is now created and set
correctly, plus many logging and other improvements.

Change-Id: Iae3fda5e876cf47d2cae6669a87b5b826a8748df
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92829
Tested-by: Jenkins
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
2020-07-01 05:42:43 +02:00
Andras Timar
25bc0a1088 Proof: add loolwsd-generate-proof-key helper script
Change-Id: Ibbd99b6431b1a2992c520d3fad5f52d0770905f6
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92788
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
2020-04-23 19:36:06 +02:00
Andras Timar
684aafd0e1 Revert "Bump package version to 4.2.0-3 and update deb/rpm package files"
This reverts commit b0b2e8f5e8.
2020-01-10 12:17:43 +01:00
Andras Timar
b0b2e8f5e8 Bump package version to 4.2.0-3 and update deb/rpm package files
Change-Id: I935425f644f373acdd4bf8d073ec8be3f29313b8
2020-01-10 12:08:08 +01:00
Andras Timar
8d5d9e427f APP_NAME tweaks
Change-Id: I16016cfc575620f98c0124fdb85e39cf56e0453a
2019-11-27 12:16:07 +01:00
Andras Timar
99ed303e2f chmod -x
Change-Id: Iaacb3f7abbbb5c76cbd693b8b9918137de086c3d
2019-11-26 22:58:35 +01:00
Andras Timar
da56f1fc73 deb: trigger systemplate update after apt operations (e.g. installation of a new font, etc.)
Change-Id: Ia356249598d2f451d135985511b0fce71335a28d
2019-11-26 22:56:58 +01:00
Michael Weghorn
2a795c5ac2 Add required python3 libs to debian/control
Those are needed since commit
c1e04e4069
("scripts/unocommands.py: Switch to python3").

This makes sure the required packages are
present when building the Debian packages.

Change-Id: I345805d0776a3ea2c43345ed1f40a32f391ba055
Reviewed-on: https://gerrit.libreoffice.org/81507
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Michael Weghorn <m.weghorn@posteo.de>
2019-10-30 15:44:26 +01:00
Sven Strickroth
eaa310aa29 Use -delete command of find instead of -exec rm
The -delete parameter allows to delete several files at once without
the need to spawn a rm processes for every found file.

Note, the -delete parameter is NOT POSIX compliant, however,
it should be available on all relevant systems.

Change-Id: Icc840aecc906700cae0665a592b7e0e7e377bdcb
Signed-off-by: Sven Strickroth <email@cs-ware.de>
Reviewed-on: https://gerrit.libreoffice.org/77084
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2019-08-10 23:28:56 +02:00
Jan Holesovsky
3a03f50784 Revert "Adapt paths to new package name"
It is not a good idea to change the configuration directory, it will affect all the existing installations.

And the service is called loolwsd - so the configuration should be called that way too.

This reverts commit 9278574289.

Change-Id: I7e6eee644e21ad2dd842742585d16133ff8e36c9
Reviewed-on: https://gerrit.libreoffice.org/72730
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-22 12:06:06 +02:00
Samuel Mehrbrodt
9278574289 Adapt paths to new package name
After 1dbbc5acc7

Change-Id: I64a12fb13bc8f9371821b2d5969941bfddc2514a
Reviewed-on: https://gerrit.libreoffice.org/72728
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-22 10:27:33 +02:00
Andras Timar
f1be65668c systemplate files should not be writable by lool user
Change-Id: Ifb4fb7e5d5c1861b5e26bb6a710acb28e546c846
Reviewed-on: https://gerrit.libreoffice.org/67425
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-02-07 14:33:30 +01:00
Andras Timar
889fb7a1ce build requires m4
Change-Id: I23a102762a43890d5487ea7a6e3adac035fc3b68
2019-01-14 15:17:20 +01:00
Andras Timar
321efe3eaa Depend on nodejs instead, Debian 9 does not have npm package, and node-jake is very old
Change-Id: Ia7ceed8dd38849575a63e96c6296c70e31509eec
2018-11-30 13:35:59 +01:00
Andras Timar
d6cac1b4a2 core dependency: libXrender 2018-10-18 15:16:05 +02:00
Jan Holesovsky
57f3bae9d9 Cleanup all old files in the cache, not just png's.
Change-Id: I61c7016d0e318742d733da72d97572215ba46a36
2018-05-30 20:04:15 +02:00
Andras Timar
7c3322e7e0 do not distribute unused or internal dev tool binaries: loolmap, loolmount, loolstress
Change-Id: Ice905d08a695805f594df5731039f747ac88cf28
Reviewed-on: https://gerrit.libreoffice.org/54027
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2018-05-09 15:28:19 +02:00
Andras Timar
17ac15c838 add more deb build dependencies
Change-Id: I10396ae0034752f1821edd1953556df6f0465f5c
2018-05-04 16:56:03 +02:00
Andras Timar
5fb16d423d enable parallel make with deb package creation
Change-Id: Ia84ca8a33a27cac8f1fcc3668a97ee3857d3c0d8
2018-03-09 12:48:38 +01:00
Christian Glombek
51993b8990 Adds ENABLE_SETCAP build variable to avoid using env in build system.
Change-Id: Id38d2225238f8b3a48481a08e62cfa7544958cc9
Reviewed-on: https://gerrit.libreoffice.org/49097
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2018-02-04 22:27:09 +01:00
Andras Timar
a2e25cc7d3 Add PAM support
Possibilities are endless. With a simple /etc/pam.d/loolwsd config below,
the user which runs loolwsd ('lool' in production environment) can login
to admin console with normal linux password.

    auth       required     pam_unix.so
    account    required     pam_unix.so

Change-Id: I354a7e9b4705e8fe346d17d6b6041d1406198b37
Reviewed-on: https://gerrit.libreoffice.org/48307
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2018-01-23 11:03:45 +01:00
Andras Timar
fdec71ad69 build requires /usr/include/linux/seccomp.h
Change-Id: I8277c4af56ac08f09328d3de368deb41f92c6864
2017-06-28 13:19:31 +02:00
Andras Timar
f55d3583be tdf#108753 postinstall script uses setcap, package should depend on libcap2-bin
Change-Id: I60ed36ad83d31925055ff5529da89c5c93f84403
2017-06-26 11:43:23 +02:00
Andras Timar
87b009c59c --enable-silent-rules for package building
Change-Id: I81ad7624b447b6c5f60e1f6e37e2b93896abe792
2017-05-30 13:34:39 +02:00
Andras Timar
2de986cdcc typo: loowsd -> loolwsd
Change-Id: Ia9febfbceae101f24c41ef8921b7cf41f02dfce3
Reviewed-on: https://gerrit.libreoffice.org/37187
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2017-05-03 10:20:26 +02:00
Andras Timar
f8ae6243dd non-world-readable loolwsd.xml in packages
Change-Id: Ibe91699f8d126dd34c1041fcfaaf471974387e47
Reviewed-on: https://gerrit.libreoffice.org/37102
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2017-04-29 22:44:13 +02:00
Andras Timar
ec2836d48f loolwsd postinst script uses fc-cache, depends on fontconfig
Change-Id: I6eb58d57cad06337fa97c91be4b14365b0d5bbb3
2017-04-28 10:35:31 +02:00
Andras Timar
04c9ea3176 Missing loolwsd.service.
Change-Id: I0fe48717dea734482d3d06ea91f7c5e594081851
2017-04-07 16:43:32 +02:00
Andras Timar
94a810daa0 Run fc-cache after installation in order to improve startup time of LOKit
Change-Id: Ide3ceb5b5dccfce6ea9e155b5dbf2e49bf24fe88
2017-04-04 12:12:22 +02:00
Andras Timar
11fc3a0d02 package debian/ files and make them generic
Change-Id: Ia060b7d83c659db0354a5a1438b12bebaee45e03
2017-03-20 23:29:16 +01:00
Andras Timar
b17d64a854 switch to 5.3
Change-Id: I21cf56f8d061453c4ff3f609ea81a5604e12b78c
2017-03-18 21:56:19 +01:00
Samuel Mehrbrodt
1f2d04a5e4 Online, not on-line
Change-Id: I93a8322dceca7c1ed95449c6aeb4ae854b982957
Reviewed-on: https://gerrit.libreoffice.org/33886
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2017-02-03 13:47:30 +00:00
Michael Meeks
cca657c8f2 Apply the pre-branch rename script to re-organize the source. 2016-11-25 09:58:48 +00:00