Commit Graph
6535 Commits
Author SHA1 Message Date
fliu 758c8791f1 email: Address some code review comments
- __init__.py: Changed email server description
- audit module: Added module docstring
- email_server action:
  - Used argparse
  - Replaced "wrapper functions" with a getattr based lookup method
2021-08-17 19:42:48 -07:00
fliu 81c9632f5a email: dovecot: Support user lookup by UID number
Dovecot refuses to open the root user's mail box
Need (!(uidNumber=0)) to correctly return status code
2021-08-17 19:42:45 -07:00
fliu f20929c23f email: Fix enabling SMTPS; check return value
- master.cf: Enable SMTPS
- lock.Mutex: check the return value of lock.acquire
- Write debug logs
2021-08-17 19:42:42 -07:00
fliu 10c3a667b6 email: Code quality fixes
- flake8: Delete unused imports
- lock.Mutex: Set file mode (rw-rw----) and ownership (plinth:plinth)
2021-08-17 19:42:39 -07:00
fliu ba179a860e email: Set up local delivery (no spam filtering)
Hosts file:

192.168.56.101 host1.test.example virtualbox
10.42.0.101    host2.test.example freedombox

Container setup (run commands in container)

1. Install the email server module
2. Create a FreedomBox account for `fred`
3.
$ sudo postconf myhostname=host2.test.example
$ echo "contactfred: fred" | sudo tee -a /etc/aliases
$ sudo newaliases
$ sudo systemctl reload postfix

Test IMAP (run on host1.test.example)

$ swaks --to=contactfred@host2.test.example --from=spam@host1.test.example
$ mutt -f imaps://fred@host2.test.example

Test mail submission (run in container):

$ swaks --to=spam@host1.test.example --from=contactfred@host2.test.example \
        --server host2.test.example:587 --tlso --auth-user=fred
2021-08-17 19:42:36 -07:00
fliu fdc6f23908 email: Implement email_server ipc set_sasl and set_submission
- Rewrote action script to eliminate stdin communication
- Changed return type of audit.*.get()
  - An audit can return multiple lines of diagnostics
- Move recommended endpoint URLs into function docstrings
2021-08-17 19:42:32 -07:00
fliu cde0b47064 email: Enable LDAP by calling postconf in a thread-safe way
- Implemented `email_server ipc postconf_set_many_v1`
- Implemented `lock.Mutex` (fcntl.lockf and threading.Lock based mutex)
  - FIXME: Lock file permissions
- Implemented `postconf` (thread-safe postconf operations)
- Started using service orientation
2021-08-17 19:42:29 -07:00
fliu aaa6342f93 email: Basic app to manage an email server
- Install postfix and manage the service
- Import ugettext
- Dummy forms and views
- <module>.version (integer) is required

[sunil: Disable the app until remaining issues are worked out]
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
2021-08-17 19:42:26 -07:00
Sunil Mohan Adapa 673ed475b7 doc/dev: Drop seemingly irrelevant automodule reference
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
2021-08-17 19:42:23 -07:00
fliu 585433d427 doc/dev: Using mocking instead of importing external modules
[sunil: Expand the full list of modules]
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: Sunil Mohan Adapa <sunil@medhas.org>
2021-08-17 19:42:20 -07:00
fliu 3def7706db diagnostics: Allow underscores (_) in app names
Reviewed-by: Sunil Mohan Adapa <sunil@medhas.org>
2021-08-17 19:42:16 -07:00
Andrij Mizyk 92352a1a23 Translated using Weblate (Ukrainian)
Currently translated at 60.0% (874 of 1456 strings)
2021-08-17 23:29:25 +02:00
James Valleroy c85adf82ed Release v21.7 to unstable
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
v21.7
2021-08-16 19:35:19 -04:00
James Valleroy 7159e2f735 doc: Fetch latest manual
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2021-08-16 19:18:25 -04:00
James Valleroy 62dbad5694 Update translation strings
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2021-08-16 18:44:59 -04:00
James Valleroy 81391ed820 ttrss: Allow upgrade to version 21
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2021-08-16 15:56:23 -04:00
James Valleroy b0592e7cd5 vagrant: Update box name
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2021-08-15 21:12:44 -04:00
Andrij Mizyk 14b6778922 Translated using Weblate (Ukrainian)
Currently translated at 57.1% (832 of 1456 strings)
2021-08-10 21:32:17 +02:00
Allan Nordhøy 0735b28baf Translated using Weblate (Norwegian Bokmål)
Currently translated at 81.6% (1189 of 1456 strings)
2021-07-30 10:35:27 +02:00
bruh e08daae9cd Translated using Weblate (Vietnamese)
Currently translated at 23.6% (345 of 1456 strings)
2021-07-28 10:34:17 +02:00
Andrij Mizyk 658545d5c7 Translated using Weblate (Ukrainian)
Currently translated at 57.0% (831 of 1456 strings)
2021-07-24 20:34:25 +02:00
Johannes Keyser 4a12a66120 Translated using Weblate (German)
Currently translated at 100.0% (1456 of 1456 strings)
2021-07-24 20:34:24 +02:00
Andrij Mizyk 964fc887ad Translated using Weblate (Ukrainian)
Currently translated at 57.0% (831 of 1456 strings)
2021-07-20 00:32:17 +02:00
Andrij Mizyk fbcddc7d75 Translated using Weblate (Ukrainian)
Currently translated at 55.3% (806 of 1456 strings)
2021-07-18 22:19:19 +02:00
Andrij Mizyk 4e7aec5a6c Translated using Weblate (Ukrainian)
Currently translated at 55.2% (805 of 1456 strings)
2021-07-17 17:32:06 +02:00
Andrij Mizyk 02039b44e3 Translated using Weblate (Ukrainian)
Currently translated at 54.8% (799 of 1456 strings)
2021-07-16 15:06:44 +02:00
James Valleroy e5c94db620 action_utils: Don't print when unholding freedombox package
Some actions that use this function are expected to output
JSON. Any output from apt-mark can interfere with this.

Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2021-07-15 20:15:56 -04:00
James Valleroy 39d411be5b upgrades: Check for held freedombox package daily
Guard against removing a hold while the package manager is busy.

Test:
1. Place hold on freedombox package.
2. Wait 3 minutes in development mode.
   - Package is held.
3. Touch /var/lib/freedombox/package-held.
4. Wait 3 minutes in development mode.
   - Package is not held.
   - Flag is removed.

Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2021-07-15 20:15:47 -04:00
James Valleroy 912d9ec9e0 upgrades: Check for held freedombox package in manual update
This is to recover from a situation where the package is held, and
then plinth process is interrupted so it cannot release the hold.

We check for and recover from this situation when installing new apps,
and when running dist upgrade. This provides another way to recover
from the problem, by running manual update.

Tests:

- (normal) No hold on freedombox package, and flag is not set. Run
  manual update. Afterwards, there is no hold, and flag is not set.

- (admin preference) Place hold on freedombox package, but flag is not
set. Run manual update. Afterwards, there is still a hold, but flag is
not set.

- (recovery) Place hold on freedombox package, but flag is
set. Run manual update. Afterwards, there is no hold, and flag is not
set.

Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2021-07-15 20:15:38 -04:00
James Valleroy 856a83c890 action_utils: Use flag to indicate freedombox package has been held
In case the plinth process is interrupted, the "finally" block that is
meant to unhold the package may not be executed, and the package will
stay held. The flag is used to indicate this situation, so it can be
resolved the next time apt_hold_freedombox is used.

Tests:

- (normal) No hold on freedombox package, and flag is not set. Install
  any app. Afterwards, there is no hold, and flag is not set.

- (admin preference) Place hold on freedombox package, but flag is not
  set. Install any app. Afterwards, there is still a hold, but flag is
  not set.

- (recovery) Place hold on freedombox package, but flag is
  set. Install any app. Afterwards, there is no hold, and flag is not
  set.

Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2021-07-15 20:15:27 -04:00
James Valleroy 5412bd75d7 action_utils: Separate function to hold freedombox package
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2021-07-15 20:15:15 -04:00
Andrij Mizyk 64129f9148 Translated using Weblate (Ukrainian)
Currently translated at 49.1% (716 of 1456 strings)
2021-07-15 20:20:17 +02:00
Andrij Mizyk 8c69e11a94 Translated using Weblate (Ukrainian)
Currently translated at 47.8% (697 of 1456 strings)
2021-07-15 11:08:39 +02:00
Andrij Mizyk 1a632644b7 Translated using Weblate (Ukrainian)
Currently translated at 11.9% (174 of 1456 strings)
2021-07-14 20:18:37 +02:00
Andrij Mizyk 88a2a482b2 Translated using Weblate (Ukrainian)
Currently translated at 6.2% (91 of 1456 strings)
2021-07-13 11:34:56 +02:00
James Valleroy d00fc72126 debian: Ensure fuse gets replaced by fuse3
Apply patch from Andreas Beckmann <anbe@debian.org> for #990758.

Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2021-07-07 14:56:33 -04:00
bruh 4cfabdd78f Translated using Weblate (Vietnamese)
Currently translated at 17.3% (252 of 1456 strings)
2021-07-05 18:33:42 +02:00
Reza Almanda d6896c149e Translated using Weblate (Indonesian)
Currently translated at 65.3% (951 of 1456 strings)
2021-06-24 02:42:55 +02:00
James Valleroy d13d59ab42 ci: Disable autopkgtest
Autopkgtest is flaky due to debconf locked error when installing
freedombox package. See #2077 for details.

Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
Reviewed-by: Joseph Nuthalapati <njoseph@riseup.net>
2021-06-19 09:53:03 +05:30
whenwesober baa64002e9 Translated using Weblate (Indonesian)
Currently translated at 61.5% (896 of 1456 strings)
2021-06-17 19:33:34 +02:00
Oymate af6fea0daf Translated using Weblate (Bengali)
Currently translated at 3.2% (48 of 1456 strings)
2021-06-16 09:33:21 +02:00
Tiago Zaniquelli a02b0baad1 tests: functional: storage: skip test List disks
Skip the test Scenario: List disks when inside a container

Reviewed-by: Joseph Nuthalapati <njoseph@riseup.net>
2021-06-14 00:12:27 +05:30
池边树下 dabaf53994 Translated using Weblate (Chinese (Simplified))
Currently translated at 47.4% (691 of 1456 strings)
2021-06-12 04:32:55 +02:00
Besnik Bleta 40c7266444 Translated using Weblate (Albanian)
Currently translated at 88.3% (1287 of 1456 strings)
2021-06-07 14:34:06 +02:00
Reza Almanda b5bf6388f7 Translated using Weblate (Indonesian)
Currently translated at 61.5% (896 of 1456 strings)
2021-06-03 07:33:33 +02:00
Jacque Fresco a156b90311 Translated using Weblate (Indonesian)
Currently translated at 61.5% (896 of 1456 strings)
2021-06-03 07:33:32 +02:00
Allan Nordhøy 2487d7cfae Translated using Weblate (Norwegian Bokmål)
Currently translated at 81.7% (1190 of 1456 strings)
2021-06-03 07:33:32 +02:00
James Valleroy 1aa1c343f0 Release v21.6 to experimental
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
v21.6
2021-05-31 19:02:04 -04:00
James Valleroy 1ba3892750 doc: Fetch latest manual
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2021-05-31 19:00:14 -04:00
James Valleroy fd26757282 locale: Update translation strings
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2021-05-31 18:16:15 -04:00