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

Missing Docker options after migration #1210

Closed
StefanRother-OTOBO opened this issue Aug 31, 2021 · 3 comments
Closed

Missing Docker options after migration #1210

StefanRother-OTOBO opened this issue Aug 31, 2021 · 3 comments
Assignees
Labels
bug Something isn't working as intended
Milestone

Comments

@StefanRother-OTOBO
Copy link
Contributor

Hi,

after migration to a docker system the following values are missing in Kernel/Config.pm.
So we have a Cache Problem, cause the Cache changes to FS during migration I think.

114 # ---------------------------------------------------- #
115 # setting for running OTOBO under Docker, see the POD #
116 # ---------------------------------------------------- #
117 $Self->{'LogModule'} = 'Kernel::System::Log::File';
118 $Self->{'LogModule::LogFile'} = '/opt/otobo/var/log/otobo.log';
119 $Self->{'Cache::Module'} = 'Kernel::System::Cache::Redis';
120 $Self->{'Cache::Redis'}->{'RedisFast'} = 1;
121 $Self->{'Cache::Redis'}->{'Server'} = 'redis:6379';
122 $Self->{'Cache::Redis'}->{'Server'} = 'redis:6379';
123 $Self->{'TestHTTPHostname'} = 'web:5000';
124
125 # activate Selenium tests if the the host is available
126 $Self->{'SeleniumTestsConfig'} = {
127 remote_server_addr => 'selenium-chrome',
128 check_server_addr => 1, # skip test when remote_server_addr can't be resolved via DNS
129 port => '4444',
130 browser_name => 'chrome',
131 platform => 'ANY',
132 };

Thanks,

Stefan

@bschmalhofer bschmalhofer transferred this issue from RotherOSS/otobo-docker Aug 31, 2021
@bschmalhofer bschmalhofer added this to the OTOBO 10.0.13 milestone Aug 31, 2021
@bschmalhofer bschmalhofer added the bug Something isn't working as intended label Aug 31, 2021
@bschmalhofer
Copy link
Contributor

Transferred this from the otobo-docker repository, at this seems to concern the migration from OTRS 6 to OTOBO 10.

@bschmalhofer
Copy link
Contributor

This is all fairly messy, so let's try to break it up into parts.

There are two important reasons for having the file Kernel/Config.pm.

  1. Provide some kind of bootstrapping for the most basic setting, like the installation directory and the database connection.
  2. Provide an opportunity for users to provide configuration in a text file. An example would the CustomerUserMap.

Because of 2. it makes sense to reuse the Kernel/Config.pm from the source OTRS installation.

Then there is the bootstrapping configuration, which consists of the following settings:

  • DatabaseHost
  • Database
  • DatabaseUser
  • DatabasePw
  • DatabaseDSN
  • Home

These settings are always taken from _Kernel/Config.pm, as they are not saved into the database. The values must come from the target installation, as the database and the installation directory usually changes. This is already handled in the the migration step OTOBOCopyFilesFromOTRS.pm . Albeit, this is not fool proof, as it does depend on formatting conventions in the source file.

So far, so good. But in the docker case the file Kernel/Config.pm is also used for overriding default settings from the Kernel/Config/Files/XML/*.xml files. E.g. die default logging backend is SysLog, which is not useful when running under Docker. This approach is convenient during installation. The downside is that the settings in Kernel/Config.pm override the setting in the SysConfig, and thus the SysConfig can't be used for changing these settings.

So, let's go with the most simple strategy. Inject the missing configuration after the line that sets Home.

bschmalhofer added a commit that referenced this issue Sep 28, 2021
bschmalhofer added a commit that referenced this issue Sep 28, 2021
when OTOBO is running under Docker
bschmalhofer added a commit that referenced this issue Sep 28, 2021
@bschmalhofer
Copy link
Contributor

Added the missing settings. Did a testmigration and checked Kernel/Config.pm. In the migrated installation the value for Cache::Module is now Kernel::System::Cache::Redis. PR is merged.

Looks fine, closing this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working as intended
Projects
None yet
Development

No branches or pull requests

2 participants