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

Commit ff351790 authored by Akhil's avatar Akhil 🙂
Browse files
parents fc7ab850 9b34b845
Loading
Loading
Loading
Loading
+21 −23
Original line number Diff line number Diff line
FROM nextcloud:28.0.9-fpm AS nextcloud
FROM nextcloud:29.0.12-fpm AS nextcloud
ARG BASE_DIR="/usr/src/nextcloud"
ARG TMP_PATCH_DIR="/tmp/build_patches"
ARG THEME_HELPER_JOB_ID="1004002"
ARG NOTES_VERSION="4.10.1"
ARG THEME_HELPER_JOB_ID="1168069"
ARG NOTES_VERSION="4.11.0"
ARG CONTACTS_JOB_ID="881946"
ARG CALENDAR_JOB_ID="991372"
ARG EMAIL_RECOVERY_JOB_ID="1004020"
ARG EA_JOB_ID="1004029"
ARG LAUNCHER_JOB_ID="991418"
ARG GOOGLE_INTEGRATION_VERSION="2.2.0"
ARG DASHBOARD_JOB_ID="1004045"
ARG EMAIL_RECOVERY_JOB_ID="1168177"
ARG EA_JOB_ID="1168157"
ARG LAUNCHER_JOB_ID="1168135"
ARG GOOGLE_INTEGRATION_VERSION="3.2.0"
ARG DASHBOARD_JOB_ID="1168115"
ARG SNAPPY_VERSION="2.37.2"
ARG SNAPPY_THEME_VERSION="4.0.1"
ARG USER_MIGRATION_JOB_ID="991454"
ARG MEMORIES_VERSION="7.3.1"
ARG DROP_ACCOUNT_VERSION="2.5.0"
ARG USER_MIGRATION_JOB_ID="1168093"
ARG MEMORIES_VERSION="7.5.2"
ARG DROP_ACCOUNT_VERSION="2.7.1"

RUN sed -i 's/28,0,9,1/28,0,9,5/' ${BASE_DIR}/version.php
RUN sed -i 's/29,0,12,2/29,0,12,5/' ${BASE_DIR}/version.php
COPY custom_entrypoint.sh /
RUN chmod +x /custom_entrypoint.sh
RUN mkdir -p /var/www/skeleton/Documents && mkdir -p /var/www/skeleton/Images
@@ -92,6 +92,9 @@ RUN curl -fsSL -o user_migration.zip \
# Fix snappymail icon
RUN sed -i 's/logo-white-64x64.png/app.svg/' ${BASE_DIR}/custom_apps/snappymail/appinfo/info.xml

# Hide personal settings of snappymail
RUN sed -i "s/'additional'/null/" ${BASE_DIR}/custom_apps/snappymail/lib/Settings/PersonalSettings.php

# Snappy theme
RUN curl -fsSL -o Murena-snappymail-theme.tar.gz \
  "https://gitlab.e.foundation/e/infra/ecloud/nextcloud-apps/snappymail-theme/-/archive/${SNAPPY_THEME_VERSION}/snappymail-theme-${SNAPPY_THEME_VERSION}.tar.gz" && \
@@ -120,7 +123,8 @@ RUN apt-get -y remove unzip
RUN sed -i "s/\$systemConfig->setValue('theme', '');/\$systemConfig->setValue('theme', 'eCloud');/g" ${BASE_DIR}/lib/base.php

# Disable editor feature of media viewer
RUN sed -i 's/canEdit(){var e,t;return!this.isMobile/canEdit(){var e,t;return!this.isMobile\&\&false/' ${BASE_DIR}/apps/viewer/js/viewer-main.js
RUN sed -i 's/canEdit(){return!this.isMobile&&L()/canEdit(){return!this.isMobile&&false&&L()/' ${BASE_DIR}/apps/viewer/js/viewer-main.mjs


ENTRYPOINT ["/custom_entrypoint.sh"]
CMD ["php-fpm"]
@@ -138,7 +142,7 @@ COPY patches/ ${TMP_PATCH_DIR}/
RUN cd ${BASE_DIR} && patch -p0 < ${TMP_PATCH_DIR}/002-login-without-domain.patch
RUN cd ${BASE_DIR} && patch -p0 < ${TMP_PATCH_DIR}/006-recovery-email-changes.patch
RUN patch -u ${BASE_DIR}/apps/settings/lib/Settings/Personal/ServerDevNotice.php -i ${TMP_PATCH_DIR}/007-remove-dev-notice.patch
RUN cd ${BASE_DIR} && patch -p0 < ${TMP_PATCH_DIR}/009-help-links.patch
RUN cd ${BASE_DIR} && patch -p1 < ${TMP_PATCH_DIR}/009-help-links.patch
RUN patch -u ${BASE_DIR}/lib/private/Updater.php -i ${TMP_PATCH_DIR}/010-disable-app-store-upgrade.patch
RUN cd ${BASE_DIR} && patch -p0 < ${TMP_PATCH_DIR}/011-privacy-settings.patch
RUN patch -u ${BASE_DIR}/lib/private/Authentication/Token/PublicKeyTokenProvider.php -i ${TMP_PATCH_DIR}/013-revert-token-password-update.patch
@@ -153,8 +157,6 @@ RUN patch -u ${BASE_DIR}/lib/private/L10N/Factory.php -i ${TMP_PATCH_DIR}/032-se
# UserConfigChangedEvent Ref: https://github.com/nextcloud/server/pull/42039
RUN cd ${BASE_DIR} && patch -p1 < ${TMP_PATCH_DIR}/036-user-config-change-event.patch

# fixed Mailer.php error which is fixed in upstream,so we need to remove this in Nextcloud 29 upgrade
RUN patch -u ${BASE_DIR}/lib/private/Mail/Mailer.php -i ${TMP_PATCH_DIR}/037-mailer-template-fix.patch
RUN rm -rf ${TMP_PATCH_DIR}

# Custom theme
@@ -211,7 +213,7 @@ From selfhost as ecloud
ARG BASE_DIR="/usr/src/nextcloud"
ARG TMP_PATCH_DIR="/tmp/build_patches"
ARG THEME_VERSION="28.0.2"
ARG LDAP_WRITE_SUPPORT_VERSION="1.10.0"
ARG LDAP_WRITE_SUPPORT_VERSION="1.11.0"
ARG IS_SELFHOST=false

RUN curl -fsSL -o ldap_write_support.tar.gz \
@@ -233,8 +235,6 @@ RUN patch -u ${BASE_DIR}/apps/dav/lib/HookManager.php -i ${TMP_PATCH_DIR}/028-de
RUN patch -u ${BASE_DIR}/apps/provisioning_api/lib/Controller/UsersController.php -i ${TMP_PATCH_DIR}/029-restrict-user-to-change-primary-email.patch
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
#fixed regression in generic event type for nextcloud 28.0.9
RUN patch -u ${BASE_DIR}/apps/dav/lib/AppInfo/Application.php -i  ${TMP_PATCH_DIR}/038-generic-event-fix.patch

RUN rm -rf ${TMP_PATCH_DIR}

@@ -246,9 +246,7 @@ RUN sed -i 's/$this->getAvatarImage($user)/null/' ${BASE_DIR}/apps/dav/lib/CardD
# RUN cd ${BASE_DIR}/dist && sed -i 's/resetPassword:!1/resetPassword:!1||Z.showResetPassword==="1"/' core-login.js

# add attr about how many notifications to notif icon
RUN sed -i 's/attrs:{id:"notifications",/attrs:{id:"notifications","data-has-notifications":0!==t.notifications.length,/' ${BASE_DIR}/apps/notifications/js/notifications-node_modules_moment_locale_sync_recursive_-src_NotificationsApp_vue-data_image_svg_xml_base64-ab95a3.js
# Add data-object-type to notification
RUN sed -i 's/"data-id":t.notificationId,/"data-id":t.notificationId,"data-object-type":t.objectType,/' ${BASE_DIR}/apps/notifications/js/notifications-node_modules_moment_locale_sync_recursive_-src_NotificationsApp_vue-data_image_svg_xml_base64-ab95a3.js
RUN sed -i 's/attrs:{id:"notifications",/attrs:{id:"notifications","data-has-notifications":0!==t.notifications.length,/' ${BASE_DIR}/apps/notifications/js/notifications-src_NotificationsApp_vue.js

# Rename Memories to Gallery
RUN sed -i 's/<name>Memories<\/name>/<name>Gallery<\/name>/g' ${BASE_DIR}/custom_apps/memories/appinfo/info.xml
@@ -308,7 +306,7 @@ RUN sed -i "s/return in_array(\$user->getBackendClassName(), \['Database', 'Gues
RUN sed -i ':a;N;$!ba;s/t("NcActionButton",{on:{click:e.onToggleSharing},scopedSlots:e._u(\[{key:"icon",fn:function(){return\[t("ShareVariantIcon",{attrs:{size:20}})\]},proxy:!0}\])},\[e._v("\\n\\t\\t\\t"+e._s(e.t("notes","Share"))+"\\n\\t\\t")\]),e._v(" "),/''/g' ${BASE_DIR}/custom_apps/notes/js/notes-main.js

# Add id to delete account settings section and hide it by default
Run sed -i 's/"NcSettingsSection",{attrs:{/"NcSettingsSection",{attrs:{id:"delete-account-settings-section",style:"visibility:hidden;",/' ${BASE_DIR}/custom_apps/drop_account/js/drop_account-personal-settings.js
RUN sed -i 's/"NcSettingsSection",{attrs:{/"NcSettingsSection",{attrs:{id:"delete-account-settings-section",style:"visibility:hidden;",/' ${BASE_DIR}/custom_apps/drop_account/js/drop_account-personal-settings.mjs

# Fix of https://github.com/nextcloud/server/commit/e727a3b00bd9b574279d25c006a0bc6b8fa4eec3 for availability setting
RUN sed -i 's/n.data/await n.text()/' ${BASE_DIR}/dist/dav-settings-personal-availability.js
 No newline at end of file
+15 −17
Original line number Diff line number Diff line
@@ -12,25 +12,23 @@ this filtering works in conjunction with the autocomplete feature disabled in ne


diff --git lib/private/Collaboration/Collaborators/UserPlugin.php lib/private/Collaboration/Collaborators/UserPlugin-new.php
--- lib/private/Collaboration/Collaborators/UserPlugin.php	2022-11-23 17:19:20.220495300 +0530
+++ lib/private/Collaboration/Collaborators/UserPlugin-new.php	2022-11-23 17:19:05.690495300 +0530
@@ -186,9 +186,9 @@
--- lib/private/Collaboration/Collaborators/UserPlugin.php	2025-02-13 19:30:40
+++ lib/private/Collaboration/Collaborators/UserPlugin-new.php	2025-03-07 12:48:50
@@ -175,8 +175,8 @@
 			if (
 				$this->shareeEnumerationFullMatch &&
 				$lowerSearch !== '' && (strtolower($uid) === $lowerSearch ||
-				strtolower($userDisplayName) === $lowerSearch ||
-				($this->shareeEnumerationFullMatchIgnoreSecondDisplayName && trim(strtolower(preg_replace('/ \(.*\)$/', '', $userDisplayName))) === $lowerSearch) ||
-				($this->shareeEnumerationFullMatchEmail && strtolower($userEmail ?? '') === $lowerSearch))
+				// strtolower($userDisplayName) === $lowerSearch ||
+				// ($this->shareeEnumerationFullMatchIgnoreSecondDisplayName && trim(strtolower(preg_replace('/ \(.*\)$/', '', $userDisplayName))) === $lowerSearch) ||
+				($this->shareeEnumerationFullMatchEmail && strtolower($userEmail) === $lowerSearch))
 				($this->shareeEnumerationFullMatchEmail && strtolower($userEmail ?? '') === $lowerSearch))
 			) {
 				if (strtolower($uid) === $lowerSearch) {
 					$foundUserById = true;

diff --git lib/private/Collaboration/Collaborators/MailPlugin.php lib/private/Collaboration/Collaborators/MailPlugin-new.php
--- lib/private/Collaboration/Collaborators/MailPlugin.php	2023-02-01 21:43:07.661060529 +0530
+++ lib/private/Collaboration/Collaborators/MailPlugin-new.php	2023-02-01 21:51:00.382603635 +0530
--- lib/private/Collaboration/Collaborators/MailPlugin.php	2025-02-13 19:30:40
+++ lib/private/Collaboration/Collaborators/MailPlugin-new.php	2025-03-07 12:55:25
@@ -39,6 +39,7 @@
 use OCP\IUserSession;
 use OCP\Mail\IMailer;
@@ -39,17 +37,18 @@ diff --git lib/private/Collaboration/Collaborators/MailPlugin.php lib/private/Co
 
 class MailPlugin implements ISearchPlugin {
 	protected bool $shareWithGroupOnly;
@@ -61,7 +62,9 @@
@@ -61,8 +62,10 @@
 		private KnownUserService $knownUserService,
 		private IUserSession $userSession,
 		private IMailer $mailer,
+		private IUserManager $userManager,
 		private mixed $shareWithGroupOnlyExcludeGroupsList = [],
 	) {
+		$this->userManager = $userManager;
 		$this->shareeEnumeration = $this->config->getAppValue('core', 'shareapi_allow_share_dialog_user_enumeration', 'yes') === 'yes';
 		$this->shareWithGroupOnly = $this->config->getAppValue('core', 'shareapi_only_share_with_group_members', 'no') === 'yes';
 		$this->shareeEnumerationInGroupOnly = $this->shareeEnumeration && $this->config->getAppValue('core', 'shareapi_restrict_user_enumeration_to_group', 'no') === 'yes';
@@ -207,27 +210,61 @@
@@ -216,27 +219,61 @@
 						if ($exactEmailMatch) {
 							$searchResult->markExactIdMatch($emailType);
 						}
@@ -131,4 +130,3 @@ diff --git lib/private/Collaboration/Collaborators/MailPlugin.php lib/private/Co
 					}
 				}
 			}
+51 −41
Original line number Diff line number Diff line
From: Akhil <akhil@e.email>
Date: Thu, 10 Aug 2021 17:30:00 +0530
From: Ronak <ronak.patel@e.email>
Date: Fri, 07 March 2025 17:30:00 +0530
Subject: [PATCH] Changes help links to point to the correct links

This patch adds changes to the "Settings" app's help template, controller and stylesheet to make sure the correct
This patch updated/adds changes to the "Settings" app's help template, controller and stylesheet to make sure the correct
help links are shown

--- ./apps/settings/lib/Controller/HelpController.php	2024-07-25 16:11:57 +0530
+++ ./apps/settings/lib/Controller/HelpController-new.php	2024-07-25 16:12:51 +0530
@@ -114,6 +114,7 @@
--- ./apps/settings/lib/Controller/HelpController.php	2025-03-07 11:04:18
+++ ./apps/settings/lib/Controller/HelpController-new.php	2025-03-07 11:04:21
@@ -123,6 +123,7 @@
 			'urlAdminDocs' => $urlAdminDocs,
 			'mode' => $mode,
 			'pageTitle' => $pageTitle,
+			'ncVersion' => \OCP\Util::getVersion()[0],
 			'knowledgebaseEmbedded' => $knowledgebaseEmbedded,
 		]);
 		$policy = new ContentSecurityPolicy()
--- ./apps/settings/templates/help.php	2024-07-25 16:17:46 +0530
+++ ./apps/settings/templates/help-new.php	2024-07-25 17:13:16 +0530
@@ -5,72 +5,49 @@
 			'legalNoticeUrl' => $legalNoticeUrl,
 			'privacyUrl' => $privacyUrl,
\ No newline at end of file
--- ./apps/settings/templates/help.php	2025-03-13 21:19:20
+++ ./apps/settings/templates/help-new.php	2025-03-26 13:04:36
@@ -5,85 +5,48 @@
 	<div id="app-navigation" role="navigation" tabindex="0">
 		<ul>
 			<li>
@@ -30,13 +31,12 @@ help links are shown
+				<a class="icon-user"
+					href="https://docs.nextcloud.com/server/<?php print_unescaped($_['ncVersion']); ?>/user_manual/en/" target="_blank" rel="noreferrer noopener">
 					<span class="help-list__text">
-						<?php p($l->t('User documentation')); ?>
-						<?php p($l->t('Account documentation')); ?>
+						<?php p('Nextcloud ' . $_['ncVersion'] . ' ' . $l->t('User documentation')); ?> ↗
 					</span>
 				</a>
 			</li>
-		<?php if ($_['admin']) { ?>
+		
 			<li>
-				<a class="help-list__link icon-user-admin <?php if ($_['mode'] === 'admin') {
-					p('active');
@@ -44,38 +44,32 @@ help links are shown
-					print_unescaped('aria-current="page"');
-				} ?>
-					href="<?php print_unescaped($_['urlAdminDocs']); ?>">
-					<span class="help-list__text">
-						<?php p($l->t('Administrator documentation')); ?>
-					</span>
+				<a href="https://doc.e.foundation/support-topics/e-cloud-e-email-account" class="icon-category-office" target="_blank" rel="noreferrer noopener">
+						<span class="help-list__text">
 					<span class="help-list__text">
-						<?php p($l->t('Administration documentation')); ?>
+						<?php p('/e/' . ' ' . $l->t('Documentation'));  ?>
+						</span>
 					</span>
 				</a>
 			</li>
-		<?php } ?>
+	
 
-
 			<li>
-				<a href="https://docs.nextcloud.com" class="help-list__link icon-category-office" target="_blank" rel="noreferrer noopener">
-					<span class="help-list__text">
+				<a href="https://community.e.foundation" class="icon-comment" target="_blank" rel="noreferrer noopener">
 					<span class="help-list__text">
-						<?php p($l->t('Documentation')); ?> ↗
-					</span>
+				<a href="https://community.e.foundation" class="icon-comment" target="_blank" rel="noreferrer noopener">
+						<span class="help-list__text">
+								<?php p($l->t('Forum')); ?> ↗
+						</span>
 				</a>
 			</li>
-				</a>
-			</li>
-			<li>
-				<a href="https://help.nextcloud.com" class="help-list__link icon-comment" target="_blank" rel="noreferrer noopener">
-					<span class="help-list__text">
-						<?php p($l->t('Forum')); ?> ↗
-					</span>
-				</a>
-			</li>
 						<?php p($l->t('Forum')); ?> ↗
 					</span>
 				</a>
 			</li>
 	</div>
 
-
-	<div id="app-content" class="help-includes">
-		<iframe src="<?php print_unescaped($_['url']); ?>" class="help-iframe" tabindex="0">
-		</iframe>
@@ -85,7 +79,7 @@ help links are shown
 		<div class="help-wrapper">
 			<div class="help-content">
 				<h2 class="help-content__heading">
-					<?php p($l->t('Nextcloud help resources')); ?>
-					<?php p($l->t('Nextcloud help & privacy resources')); ?>
+					<?php p($l->t('Murena Workspace help resources')); ?>
 				</h2>
 				<div class="help-content__body">
@@ -108,14 +102,29 @@ help links are shown
+				<a href="https://community.e.foundation" class="button" target="_blank" rel="noreferrer noopener">
 					<?php p($l->t('Forum')); ?> ↗
 				</a>
-				<?php if ($_['legalNoticeUrl']) { ?>
-					<a href="<?php print_unescaped($_['legalNoticeUrl']); ?>" class="button" target="_blank" rel="noreferrer noopener">
-						<?php p($l->t('Legal notice')); ?> ↗
-					</a>
-				<?php } ?>
-				<?php if ($_['privacyUrl']) { ?>
-					<a href="<?php print_unescaped($_['privacyUrl']); ?>" class="button" target="_blank" rel="noreferrer noopener">
-						<?php p($l->t('Privacy policy')); ?> ↗
-					</a>
-				<?php } ?>
 			</div>
 		</div>
 	</div>
-<?php endif; ?>
+<?php endif; ?>
\ No newline at end of file
--- ./apps/settings/css/help.css    2021-08-20 14:16:57.951439620 +0530
+++ ./apps/settings/css/help-new.css        2021-08-20 17:02:43.549016337 +0530
@@ -10,3 +10,12 @@
        border: 0;
        overflow: auto;
 }
+
@@ -50,4 +50,12 @@
 
 .help-content__body > .button {
 	margin: 20px;
+}
+#content #app-navigation {
+       transform: none;   
+       width: max-content;
@@ -123,4 +132,5 @@ help links are shown
+
+#app-navigation:not(.vue) > ul > li > a {
+       padding: 0 12px 0 44px;
+}
 }
+7 −7
Original line number Diff line number Diff line
--- ./lib/private/Template/JSResourceLocator.php	2024-08-29 22:10:30.588659044 +0530
+++ ./lib/private/Template/JSResourceLocator-new.php	2024-08-29 23:55:00.239753244 +0530
@@ -62,6 +62,7 @@
 				// Handle symlinks
 				$appRoot = realpath($appRoot);
@@ -67,6 +67,7 @@
 		} catch (AppPathNotFoundException $e) {
 			// ignore
 		}
+		$appDirName = basename($appRoot);
 			// Get the app webroot
 			$appWebRoot = dirname($this->appManager->getAppWebPath($app));
 		} catch (AppPathNotFoundException $e) {
 
 		if (str_contains($script, '/l10n/')) {
 			// For language files we try to load them all, so themes can overwrite
@@ -77,7 +78,7 @@
 			$found += $this->appendScriptIfExist($this->serverroot, $script);
 			$found += $this->appendScriptIfExist($this->serverroot, $theme_dir.$script);
+0 −46
Original line number Diff line number Diff line
From: Avinash <avinash.gusain.ext@murena.com>
Date: Thu, 29 Aug 2024 15:50:00 +0530
Subject: [PATCH] This actually fixes error introduces in 28.0.9  Mailer.php .Already fixed on Stable 28,29 and 30. Not needed in next upgrade.

--- lib/private/Mail/Mailer.php	2024-08-29 15:55:02
+++ lib/private/Mail/Mailer-new.php	2024-08-29 15:56:18
@@ -130,18 +130,6 @@
 	 * @since 12.0.0
 	 */
 	public function createEMailTemplate(string $emailId, array $data = []): IEMailTemplate {
-		$class = $this->config->getSystemValueString('mail_template_class', '');
-
-		if ($class !== '' && class_exists($class) && is_a($class, EMailTemplate::class, true)) {
-			return new $class(
-				$this->defaults,
-				$this->urlGenerator,
-				$this->l10nFactory,
-				$emailId,
-				$data
-			);
-		}
-
 		$logoDimensions = $this->config->getAppValue('theming', 'logoDimensions', self::DEFAULT_DIMENSIONS);
 		if (str_contains($logoDimensions, 'x')) {
 			[$width, $height] = explode('x', $logoDimensions);
@@ -165,6 +153,19 @@
 			}
 		} else {
 			$logoWidth = $logoHeight = null;
+		}
+
+		$class = $this->config->getSystemValueString('mail_template_class', '');
+		if ($class !== '' && class_exists($class) && is_a($class, EMailTemplate::class, true)) {
+			return new $class(
+				$this->defaults,
+				$this->urlGenerator,
+				$this->l10nFactory,
+				$logoWidth,
+				$logoHeight,
+				$emailId,
+				$data
+			);
 		}
 
 		return new EMailTemplate(
 
Loading