Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

variable plugin-urls #10

Open
crpb opened this issue Oct 13, 2023 · 0 comments
Open

variable plugin-urls #10

crpb opened this issue Oct 13, 2023 · 0 comments

Comments

@crpb
Copy link

crpb commented Oct 13, 2023

Ticket#81902
i think it would be beneficial to test for config-overrides in /etc/grommunio-admin-common/config.json and apply them for any(not just archive like shown) plugin-url's to not run in any problems with multiple hosts or just different domainnames for some reason.
i mainly had the idea as i already have nextcloud-instances running and didn't want to install that on the mailserver.

cat /etc/grommunio-web/config-archive.php
<?php

define('PLUGIN_ARCHIVE_USER_DEFAULT_ENABLE', false);

try {
 $adminconfig = file_get_contents('/etc/grommunio-admin-common/config.json');
 $adminjson = json_decode($adminconfig, true);
}
catch (Exception $e) {
 echo "blah";
}
if ( isset( $adminjson['archiveWebAddress'] ) ) {
 define('PLUGIN_ARCHIVE_URL', $adminjson['archiveWebAddress']);
}
else
{
 define('PLUGIN_ARCHIVE_URL', 'https://' . $_SERVER['HTTP_HOST'] . '/archive/');
}

define('PLUGIN_ARCHIVE_AUTOSTART', false);

🙈 🙉 🙊

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant