Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 421ed398 authored by Akhil's avatar Akhil 🙂
Browse files
parents db3e2e9b 5aa797dc
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -64,6 +64,8 @@ RUN curl -sL ${GOOGLE_INTEGRATION_URL} | tar xzf - -C ${BASE_DIR}/custom_apps
RUN rm -rf ${BASE_DIR}/themes/Murena/* && \
    curl -sL ${SNAPPY_THEME_VERSION} | tar xzf - -C ${BASE_DIR}/themes/Murena/

#Workaround to fix line break when answering an email on firefox 
RUN sed -i 's/this.oEditor?.focus()/(this.oEditor?.focus(),navigator.userAgent.includes("Firefox")\&\&(window.getSelection().modify("move","forward","character"),window.getSelection().modify("move","backward","character")))/' ${BASE_DIR}/custom_apps/snappymail/app/snappymail/v/*/static/js/min/app.min.js

# Remove unzip when unzipping is done
RUN apt-get -y remove unzip
@@ -176,6 +178,7 @@ RUN patch -u ${BASE_DIR}/apps/provisioning_api/lib/Controller/UsersController.ph
RUN patch -u ${BASE_DIR}/lib/private/Security/VerificationToken/VerificationToken.php -i ${TMP_PATCH_DIR}/033-verification-token-private.patch
RUN patch -u ${BASE_DIR}/lib/private/AppFramework/Middleware/Security/CORSMiddleware.php -i ${TMP_PATCH_DIR}/034-oidc-bearer-token-auth.patch
#RUN patch -u ${BASE_DIR}/custom_apps/snappymail/app/snappymail/v/2.38.2+murena-20251112/app/libraries/RainLoop/Actions/Contacts.php -i ${TMP_PATCH_DIR}/037-snappymail-contact.patch
RUN cd ${BASE_DIR} && patch -p0 < ${TMP_PATCH_DIR}/038-appdata-folder-based-on-config.patch
RUN rm -rf ${TMP_PATCH_DIR}


+1 −1
Original line number Diff line number Diff line
@@ -12,7 +12,7 @@ diff --git ContactsMenuController.php ContactsMenuController-new.php
 	#[FrontpageRoute(verb: 'POST', url: '/contactsmenu/contacts')]
 	public function index(?string $filter = null): array {
-		return $this->manager->getEntries($this->userSession->getUser(), $filter);
+		return [];
+		return ['contactsEnabled' => \OC::$server->getAppManager()->isEnabledForUser('contacts', $this->userSession->getUser()), 'contacts' => []];
 	}
 
 	/**
+46 −0
Original line number Diff line number Diff line
From: Fahim <fahim.chowdury.ext@murena.com>
Date: Thu, 05 Mar 2026 16:26:00 +0600
Subject: [PATCH] Enable appdata folder location can be set up dynamatically

We want to setup appdata folder dynamatically using config. This is specially needed for objectStore setup, so appdata files can be locally accessable, which minimize loadtime. The `appdatadirectory` new config value is introduced by this patch.

--- lib/private/Files/SetupManager.php	2026-03-05 16:26:59.175816848 +0600
+++ lib/private/Files/SetupManager-new.php	2026-03-05 16:26:46.271803100 +0600
@@ -429,10 +429,26 @@
 		foreach ($rootMounts as $rootMountProvider) {
 			$this->mountManager->addMount($rootMountProvider);
 		}
-
+		$this->setupAppData();
 		$this->eventLogger->end('fs:setup:root');
 	}

+	private function setupAppData(): void {
+		if ($appdatadirectory = $this->config->getSystemValue('appdatadirectory', null)) {
+			$instanceId = $this->config->getSystemValue('instanceid', null);
+			if ($instanceId === null) {
+				throw new \RuntimeException('no instance id!');
+			}
+			$folderName = 'appdata_' . $instanceId;
+			$arguments = [
+				'datadir' => $appdatadirectory,
+			];
+			$storage = new \OC\Files\Storage\Local($arguments);
+			$mount = new \OC\Files\Mount\MountPoint($storage, $folderName, $arguments);
+			$this->mountManager->addMount($mount);
+		}
+	}
+
 	/**
 	 * Get the user to setup for a path or `null` if the root needs to be setup
 	 *
--- lib/private/SystemConfig.php	2026-03-05 16:30:25.597831789 +0600
+++ lib/private/SystemConfig-new.php	2026-03-05 16:30:12.022966268 +0600
@@ -20,6 +20,7 @@
 	protected const DEFAULT_SENSITIVE_VALUES = [
 		'instanceid' => true,
 		'datadirectory' => true,
+		'appdatadirectory' => true,
 		'dbname' => true,
 		'dbhost' => true,
 		'dbpassword' => true,